Boris Zbarsky
7c6c40e506
Bug 1366032. Align IDL record to C++ conversion with the spec when Symbol-named properties are involved. r=qdot
2017-05-24 08:50:30 -04:00
Boris Zbarsky
682fe478ec
Bug 1237503. Add support for [Cached] and [StoreInSlot] things on DOM proxies. r=qdot
...
The only difference between proxies and non-proxies is that proxies only support
up to MAX_FIXED_SLOTS slots all told (reserved plus private slot). SpiderMonkey
already has static asserts to make sure we don't ask for too many reserved slots
on a proxy.
2017-05-19 09:24:30 -04:00
Boris Zbarsky
0c1348b3ef
Bug 1189822 part 4. Fix finalization for DOM overridebuildins proxies to not clear the expando if it's for a different reflector. r=peterv, sfink
...
This is something that should have happened in bug 1352430 but was missed there.
2017-05-17 00:52:53 -04:00
Boris Zbarsky
9f3244d605
Bug 1189822 part 3. Stop using EnsureExpandoObject in codegen code when we just want to preserver the wrapper for a DOM proxy. r=peterv
2017-05-17 00:52:53 -04:00
Boris Zbarsky
742751837a
Bug 1363874. Disallow [Cached] and [StoreInSlot] on static attributes for now. r=qdot
2017-05-12 11:15:12 -04:00
btian
145c7af3f9
Bug 1338059 - Part 1: Generate cycle collection related code for WebIDL type Promise, r=bz
...
MozReview-Commit-ID: 1wQFBCur0Uy
--HG--
extra : rebase_source : 055cbc34525cbf8d67f143f56528ff6165a61786
2017-05-05 10:12:40 +08:00
Boris Zbarsky
45a20c4074
Bug 1358596. Restore check for sanity of slot indices on DOM objects that got lost. r=qdot
2017-05-02 01:55:47 -04:00
Jan de Mooij
8ddc231e13
Bug 1360523 - Define number of reserved slots explicitly for each proxy js::Class. r=bz
2017-04-29 14:41:49 +02:00
Jan de Mooij
f480e9ecdf
Bug 1237504 - Refactor proxy slot layout to allow proxies to have more than 2 slots. r=bz,jonco
...
The patch makes the following proxy changes:
* The number of slots in ProxyValueArray is now dynamic and depends on the number of reserved slots we get from the Class.
* "Extra slots" was renamed to "Reserved slots" to make this clearer.
* All proxy Classes now have 2 reserved slots, but it should be easy to change that for proxy Classes that need more than 2 slots.
* Proxies now store a pointer to these slots and this means GetReservedSlot and SetReservedSlot can be used on proxies as well. We no longer need GetReservedOrProxyPrivateSlot and SetReservedOrProxyPrivateSlot.
And some changes to make DOM Proxies work with this:
* We now store the C++ object in the first reserved slot (DOM_OBJECT_SLOT) instead of in the proxy's private slot. This is pretty nice because it matches what we do for non-proxy DOM objects.
* We now store the expando in the proxy's private slot so I removed GetDOMProxyExpandoSlot and changed the IC code to get the expando from the private slot instead.
2017-04-28 14:12:28 +02:00
Jon Coppeard
eb3c9870bf
Bug 1352430 - Add barrier to wrapper cache to clear dying objects that have not yet been finalized r=bz r=sfink
...
* * *
Code review followup
--HG--
extra : rebase_source : 10c1fd603c2dd1ac2ff5770ae9aec2e9131681ce
2017-04-26 11:18:39 +01:00
John Dai
b32e4c240b
Bug 1309147 - Part 3: Implement the support for CEReactions in Codegen. r=bz
...
MozReview-Commit-ID: F1mxKzlru9s
--HG--
extra : rebase_source : a5e52ef2f3168028dec2c3186e857941953ad517
extra : histedit_source : 2336479daf177cb7ca55ee517c8317852bed09ef
2017-03-08 17:11:48 +08:00
John Dai
a9bed711dc
Bug 1309147 - Part 2: Add the name of 'this' value's JSObject* for codegen to generate CEReaction code. r=bz
...
MozReview-Commit-ID: BZwO7I4uh2
--HG--
extra : rebase_source : 1258bad2a723bdd1a0b3c52342ada3faa9b7a7a5
extra : histedit_source : d87a1c3876c37d61bd93690c85a86bd5333aa5e3
2017-03-08 17:09:59 +08:00
Andrew McCreight
fe0bcc3a40
Bug 1338272 - Require that the return value of MaybeSetPendingException is used. r=bz
...
Most of the time, the return value of this method should be checked,
because behavior should depend on whether or not an exception is
thrown. However, if it is called immediately after a throw it doesn't
need to be checked because it will always return true. bz said there
is no public API that lets you assume there is an exception because it
would be "too easy to misuse".
MozReview-Commit-ID: CqyicBbcNjW
--HG--
extra : rebase_source : a5b74ba88a927a90d491ceb8f0b750a67f62b0f4
2017-02-14 16:17:02 -08:00
Olli Pettay
d7c9e40c86
Bug 1352746 - Rename ProbablyShortLivingObject to ProbablyShortLivingWrapper in webidl, r=qDot
...
--HG--
extra : rebase_source : 41c2aae34d1140881078aeb336e974394425b9c3
2017-04-11 00:01:29 +03:00
Boris Zbarsky
af7a6137cc
Bug 1291397. Work around clang bug that they didn't actually manage to ship a fix for which causes it to give spurious warnings it shouldn't be giving, which are then fatal due to -Werror. r=dholbert
...
MozReview-Commit-ID: GbMEvoxGpH1
2017-03-31 17:09:48 -04:00
Michael Layzell
e66a0f7027
Bug 1331434 - Part 5: Mark some Throw calls in /dom/bindings as having custom cleanup, r=baku
...
MozReview-Commit-ID: CooKyfkMlWq
2017-03-07 19:06:48 -05:00
Jon Coppeard
82cbd987a2
Bug 1338623 - Add a slower but more exact gray marking check for checking correctness r=sfink r=mccr8
2017-03-02 10:22:47 +00:00
David Major
ec8b79d7fd
Bug 1339275: Define JSPropertySpec values in a way that's easier for Visual Studio to initialize. r=Waldo
...
MozReview-Commit-ID: BMCunTjUapN
2017-02-22 10:11:54 +13:00
Boris Zbarsky
a449ccb8fa
Bug 1333045. Update Location object properties to current spec. r=qdot
...
Specifically, three changes:
1) valueOf should be non-enumerable.
2) valueOf should be === to Object.prototype.valueOf.
3) There should be no toJSON.
The tests come directly from https://github.com/w3c/web-platform-tests/pull/4623
so not much need to review them.
2017-02-15 00:01:48 -05:00
Boris Zbarsky
18a2013469
Bug 1330699 part 13. Implement the spec provision for handling repeated keys in records by updating the existing value. r=qdot
2017-02-15 00:01:41 -05:00
Boris Zbarsky
063d0caa78
Bug 1330699 part 12. Actually change the key type of a record, and its corresponding conversion behavior, depending on what the IDL says. r=qdot
2017-02-15 00:01:39 -05:00
Boris Zbarsky
90896220ac
Bug 1330699 part 11. Add ConvertJSValueTo*String functions that just take a value and hand out a string, without extra complications. r=qdot
2017-02-15 00:01:37 -05:00
Boris Zbarsky
1471a0e8e3
Bug 1330699 part 10. Rename the MozMap C++ type to "record" and give it a template parameter for the key type. r=qdot
...
Also renames all the test functions to mention "Record" instead of "MozMap".
--HG--
rename : dom/bindings/MozMap.h => dom/bindings/Record.h
2017-02-15 00:01:35 -05:00
Boris Zbarsky
46964f231f
Bug 1330699 part 9. Rename "MozMap" to "record" in our IDL parser and IDL files. r=qdot
...
The key type is unused so far.
--HG--
rename : dom/bindings/parser/tests/test_mozmap.py => dom/bindings/parser/tests/test_record.py
2017-02-15 00:00:17 -05:00
Boris Zbarsky
dd02756287
Bug 1330699 part 7. Change JS to MozMap conversion to more closely follow the record<> spec. r=qdot
...
The spec says to get all the property keys, then check each one for
enumerability before doing the Get(). Our current code, before this change,
asks for all the _enumerable_ keys instead, which is observably different when
proxies are involved.
2017-02-15 00:00:06 -05:00
Boris Zbarsky
42aec147f1
Bug 1330699 part 3. Fix up some minor issues with default value handling in codegen. r=qdot
2017-02-15 00:00:01 -05:00
Boris Zbarsky
538d57c3f6
Bug 1330699 part 2. Change the MozMap API and data storage to more what we want record<> to look like. r=qdot,smaug
2017-02-15 00:00:00 -05:00
Andi-Bogdan Postelnicu
b877576a5c
Bug 1335000 - return type& for copy assignment operator. r=peterv
...
MozReview-Commit-ID: 7kHt2l30ZP6
--HG--
extra : rebase_source : 3ef1cb0583238d9508153f4ddbbd402930f70706
2017-02-01 17:54:49 +02:00
Boris Zbarsky
e1a9c1904b
Bug 1338417. Make @@iterator properties on DOM prototypes not enumerable, to match IDL spec. r=qdot
2017-02-10 23:06:14 -05:00
Boris Zbarsky
077e1ba24c
Bug 1333556. Assert that an ErrorResult passed to a WebIDL callback as an outparam is not already-failed. r=peterv
2017-02-06 17:00:47 -05:00
Boris Zbarsky
da79ef55fe
Bug 1335368 part 8. Stop using IsCallerChrome in UnwrapArgImpl. r=bholley
2017-02-01 15:43:37 -05:00
Boris Zbarsky
99d6a6c7d9
Bug 1335368 part 6. Add a SystemCallerGuarantee class that we use for [ChromeOnly, NeedsCallerType] cases. r=bholley
2017-02-01 15:43:36 -05:00
Brian Hackett
8033ed29a8
Bug 1324002 - Mark atoms separately in each zone, r=jonco,mccr8,peterv.
...
--HG--
extra : rebase_source : 53cf4fa94f122a991c2adbd7bae3714de4391bb4
2017-01-30 06:31:47 -07:00
Boris Zbarsky
39d50c2647
Bug 1332713 part 4. Make Promise-returning getters return a rejected Promise on exception instead of throwing. r=qdot
2017-01-27 18:53:37 -05:00
Kris Maglione
729b7a2019
Bug 1273251: Part 3 - Allow CallbackObject to contain a null callable. r=peterv
...
MozReview-Commit-ID: FCXVHouhG3I
--HG--
extra : rebase_source : f3e9325559d40bcb4017ec2505f435275d4fea7f
2016-11-14 21:25:37 -08:00
Boris Zbarsky
1cf89e40b6
Bug 1330536 part 5. Correctly mark fallibility/movability/etc in jitinfo for cases that can OOM but are otherwise infallible. r=smaug
2017-01-17 23:52:13 -05:00
Boris Zbarsky
69cf877f8c
Bug 1330536 part 4. Pass OOMReporter from bindings in cases that can OOM but are otherwise infallible. r=smaug
2017-01-17 23:52:13 -05:00
Boris Zbarsky
c05f2fe396
Bug 1330698. Support string default values for unions containing USVString. r=qdot
2017-01-13 10:41:12 -05:00
Xidorn Quan
a8e64a94e1
Bug 1298756 - Use uint8_t/uint16_t as underlying type for enums from webidl. r=bz
...
MozReview-Commit-ID: 3uS9s5ZrPFd
--HG--
extra : rebase_source : ff64b4468ee99ba08fd8638298a27711b7fb6393
2017-01-12 12:23:37 +11:00
Boris Zbarsky
bfa711e9c3
Bug 1326522. Fix the include situation for unions containing primitives by making UnionTypes/UnionConversions header stuff look more like CGHeaders. r=peterv
2017-01-10 14:46:30 -05:00
Olli Pettay
0364dbc792
Bug 1326507, remove NS_IMPL_CYCLE_COLLECTION_TRAVERSE_SCRIPT_OBJECTS, r=mccr8
...
--HG--
extra : rebase_source : 3ae1207308de120b7299b13ecaa95dd1612b3459
2017-01-03 21:47:55 +02:00
Boris Zbarsky
3f8b6befb3
Bug 1326105 part 5. Move the getting of the incumbent global to the finish-slow-js codepath too, since it's not needed if no one will ever call our callback. r=smaug
2016-12-29 13:19:26 -08:00
Boris Zbarsky
249298d20c
Bug 1326105 part 4. Remove the now-unused JSContext argument of the protected CallbackObject constructor. r=smaug
2016-12-29 13:19:26 -08:00
Boris Zbarsky
e5f32d3609
Bug 1326105 part 2. Rename CallbackObject::HoldJSObjectsIfMoreThanOneOwner to a more generic name and hand it a JSContext to use. r=smaug
2016-12-29 13:19:26 -08:00
Boris Zbarsky
6c78cc893a
Bug 1323721 part 11. Make isInterface and isGeckoInterface test false for the isPromise() case. r=qdot
2016-12-19 15:38:44 -08:00
Boris Zbarsky
d954b293d1
Bug 1323721 part 10. Move Promise arg-type computation for callbacks out of the isGeckoInterface section. r=qdot
2016-12-19 15:38:43 -08:00
Boris Zbarsky
f0b430a1bb
Bug 1323721 part 9. Move Promise JS-to-native conversion out of the isGeckoInterface section. r=qdot
2016-12-19 15:38:43 -08:00
Boris Zbarsky
193bf9cd4c
Bug 1323721 part 8. Remove the codegen hacks for calling Promise methods and constructors now that we don't do that anymore. r=till
2016-12-19 15:38:43 -08:00
Boris Zbarsky
865e7c42eb
Bug 1323721 part 5. Move Promise native-to-JS conversion out of the isGeckoInterface section. r=qdot
2016-12-19 15:38:43 -08:00
Boris Zbarsky
d68defe92d
Bug 1324044. Add fingerprinting resistance in GetSupportedNames in nsMimeTypeArray and nsPluginArray. r=qdot
2016-12-17 00:25:52 -05:00