Граф коммитов

334 Коммитов

Автор SHA1 Сообщение Дата
Peter Van der Beken 80ecd8538f Fix for bug 763643 (Implement static operations and attributes for WebIDL). r=bz.
--HG--
extra : rebase_source : d9dd5450af5d2b1f3e7e3a738ec2efdc7f7053da
2012-10-19 09:34:28 +02:00
Peter Van der Beken 2412de3249 Fix for bug 785277 (Implement PutForwards in the new DOM bindings). r=bz.
--HG--
extra : rebase_source : 5153ebab17a9637946d0f0c322997c0c3d118190
2012-08-13 14:20:49 +02:00
Boris Zbarsky b129ae95fc Bug 804725. Use the right type name for interface arguments for binding example codegen. r=jst 2012-10-24 16:10:49 -04:00
Boris Zbarsky fbeee7dfd0 Bug 793267. Add support for [Unforgeable] in WebIDL. r=peterv
Unforgeable attributes are defined directly on the object, not on the
prototype.  So we keep them in a separate spec array and define them
during object creation as needed.

This means that we have to pass that separate spec array to the Xray
helpers, unfortunately, which somewhat complicates those.
2012-10-24 16:10:49 -04:00
Boris Zbarsky 2a8465582e Bug 798187 part 1. Add support for dictionary return values. r=peterv 2012-10-22 13:08:52 -04:00
Boris Zbarsky 6fc1e2797b Bug 802636. Add a test that makes sure that codegen and example generation agree with each other. r=jst 2012-10-17 21:17:16 -04:00
Boris Zbarsky 0d788a841d Bug 796983 part 1. Switch nullable primitives to using a const Nullable. r=jst 2012-10-17 17:01:55 -04:00
Trevor Saunders 85dfb659cf Bug 742191 - Part d: Throw TypeErrors for Paris binding exceptions; r=bz 2012-10-16 14:06:10 -04:00
Boris Zbarsky e743742df1 Bug 792890. Fix JS-wrapping of callback interfaces to just return the underlying JS object. r=peterv
There are several changes here:

1) When wrapping a callback interface object for JS, just extract the
   underlying JSObject from inside it and hand that object out.

2) Flag callback interface descriptors as "not concrete" (only matters
   for cases when they have constants on the interface object) and not
   wrappercached (will catch bugs if someone tries to treat them as a
   Gecko object).

3) Fix a preexisting bug in sequence wrapping where we'd try to
   JS_DefineElement twice if we were wrapping a null value for a
   sequence of nullable interface objects.
2012-10-10 15:57:57 -04:00
Boris Zbarsky 7f28e933c6 Bug 792137. [TreatNonCallableAsNull] lives on the callback type now. r=peterv 2012-10-10 15:53:02 -04:00
Kyle Huey 5e093ffe72 Bug 793025: Convert FileReaderSync to WebIDL bindings. r=bz 2012-09-20 19:47:47 -07:00
Boris Zbarsky 90c9f1e64d Bug 790975. Support sequences as dictionary members in WebIDL. r=peterv 2012-09-18 23:24:27 -04:00
Peter Van der Beken f3ef69a188 Fix for bug 768684 (Fix sequence<any> return type in WebIDL). r=bz.
--HG--
extra : rebase_source : acbd2ce77f62146e9bd7fc285a8042073ed95722
2012-06-13 17:15:05 +02:00
Boris Zbarsky 0334fe32b0 Bug 790273. Add support for [LenientThis] in WebIDL. r=peterv 2012-09-12 17:24:58 +01:00
Boris Zbarsky b97e3a8dcd Bug 787554. Don't prefix WebIDL getters names with a Get if they look like simple member access on the C++ side. r=peterv 2012-09-11 20:08:24 +01:00
Boris Zbarsky 795db28096 Bug 788369. Allow passing strings to the XHR constructor, since CoffeeScript seems to want to do it. r=peterv 2012-09-07 11:07:12 -04:00
Boris Zbarsky 57c2a362b2 Bug 742144. Implement support for typedefs in WebIDL. r=khuey 2012-09-06 10:23:51 -04:00
Ms2ger 797a567f66 Bug 763367 - Add support for [EnforceRange] and [Clamp]; r=bz 2012-09-06 09:25:03 +02:00
Boris Zbarsky 1bd799df56 Bug 778150 part 3. Default attributes to infallible. Allow annotation of fallible attributes in WebIDL. r=peterv
The valid annotations are [Throws], [GetterThrows], and [SetterThrows], which can all either take no value or
be set to MainThread or Workers if the throwing behavior is only happening on main thread or in workers
2012-09-05 09:21:33 -04:00
Boris Zbarsky 7a3efb15c4 Bug 778150 part 2. Default methods to infallible. Allow annotation of fallible methods in WebIDL using [Throws]. r=peterv
[Throws] can either take no value, or can take MainThread or Workers if the
throwing behavior is only happening on main thread or in workers.
2012-09-05 09:21:33 -04:00
Boris Zbarsky bca38b3571 Bug 778150 part 1. Remove the vestigial ability to specify infallibility stuff in the conf file. r=peterv 2012-09-05 09:21:33 -04:00
Boris Zbarsky 7919784ad2 Bug 767930. Add support for typed array return values (as just JSObject*) in WebIDL bindings. r=peterv 2012-08-28 13:10:09 -04:00
Peter Van der Beken ee9eae3141 Fix for bug 768692 (Move DOM list binding generation to the new DOM binding codegen). r=bzbarsky.
--HG--
extra : rebase_source : 651a0fac4c9a87ef1c0a9cd91588c6421fd050c4
2012-05-22 15:46:20 +02:00
Peter Van der Beken c28c5972cd Fix for bug 775543 (Passing a Worker object to console.log() results in a crash). r=bz.
--HG--
extra : rebase_source : 60ee731af1e77c21f466026a04c71eeb96b1ff7d
2012-08-22 18:16:14 -07:00
Ms2ger 5e52eae02f Bug 773326 - Add test for previously inverted thread check in getJSToNativeConversionTemplate::onFailure; r=peterv 2012-08-04 09:43:57 +02:00
Mike Hommey 70d7c821af Bug 774032 bonus - Use @DEPTH@ and @relativesrcdir@ in Makefile.in. r=ted 2012-08-04 20:26:44 +02:00
Ed Morley f4181983a1 Revert inbound to 3d5d1daa2505 to stop OS X M5 failures (backout not clean/could have been a bad merge) on a CLOSED TREE 2012-08-04 18:05:15 +01:00
Ms2ger c2ff8f2e47 Bug 773326 - Add test for previously inverted thread check in getJSToNativeConversionTemplate::onFailure; r=peterv 2012-08-04 09:43:57 +02:00
William Chen 103cc37839 Bug 779573 - Fix generated code for empty string as default dictionary member in WebIDL. r=khuey 2012-08-01 14:34:36 -04:00
Boris Zbarsky 0940d0902f Bug 775852 followup: skip the test when WebGL is not around. No review. 2012-07-31 10:24:01 -04:00
Boris Zbarsky 423774779f Bug 771636 part 3. Implement default values for WebIDL strings. r=peterv 2012-07-31 00:22:23 -04:00
Boris Zbarsky 1b273923c5 Bug 771636 part 2. Implement default values for WebIDL enums. r=peterv 2012-07-31 00:22:23 -04:00
Boris Zbarsky d988f0953a Bug 771636 part 1. Rearrange default-value handling so we actually set C++ values directly instead of round-tripping through jsval. r=peterv 2012-07-31 00:22:22 -04:00
Boris Zbarsky ac47d48b17 Bug 777438. Make sure our C++ declarations are in the right order when a dictionary has a dictionary member. r=khuey 2012-07-27 00:09:10 -04:00
Boris Zbarsky 4a5cf6f5f8 Bug 775844. Make sure to examine constructor signatures when looking for union types. r=peterv 2012-07-27 00:09:10 -04:00
Boris Zbarsky cf68660a3b Bug 775852. Actually follow the WebIDL spec for creating JS representations of sequences. r=khuey 2012-07-27 00:09:09 -04:00
Boris Zbarsky 7170b6f706 Bug 777627. Make sure we can't accidentally turn off mochitests for a directory by reordering the Makefile.in. r=khuey 2012-07-26 12:38:03 -04:00
Jason Orendorff 1e1b73d49c Bug 725907 - for-of improvements, part 3: Implement .iterator() for arraylike DOM objects. r=bzbarsky. 2012-07-03 16:34:56 -05:00
Boris Zbarsky ddb1f3e7a5 Fix dom binding test makefile to actually work right. r=khuey, no bug 2012-07-19 14:48:59 -04:00
Boris Zbarsky 8024ef90c6 Bug 764456 part 5. Actually look at hasConcreteDescendant in hasInterfacePrototypeObject() so that we can avoid codegen for [NoInterfaceObject] interfaces hat are only implemented via "implements". r=peterv 2012-07-19 14:48:58 -04:00
Boris Zbarsky 061fe4e429 Bug 764456 part 4. Make sure consequential interface used as arguments are non-castable. r=peterv 2012-07-19 14:48:58 -04:00
Boris Zbarsky 9e76164a7f Bug 764456 part 2. Add some tests for callback interfaces. r=peterv 2012-07-19 14:48:58 -04:00
Boris Zbarsky 3951284caf Bug 768537 part 2. Allow dictionaries to be initialized with null or undefined, and treat them as dictionaries in which everything has its default value. r=peterv 2012-07-17 12:18:53 -04:00
Boris Zbarsky dbdbca200f Bug 768537 part 1. Update parser support for dictionaries to spec changes. r=jlebar
There are several parts here:

1)  Enforce the requirement that dictionary arguments not followed by a required argument are optional.
2)  Make dictionaries no longer be distinguishable from nullable types.
3)  Disallow dictionaries or unions containing dictionaries inside a nullable type.
4)  Force optional dictionaries to have a default value of null so that codegen doesn't have to worry about dealing with
    optional arguments that have no default value in the IDL but need to be treated as if they were null.
2012-07-17 12:18:53 -04:00
Ed Morley c9624f0f7a Backout 9deb8edb5070 (bug 773519), ea5a243a60f1 & 0cad1e553bea (bug 768537) for compilation failures 2012-07-17 17:48:11 +01:00
Boris Zbarsky 25b0c7ad78 Bug 768537 part 2. Allow dictionaries to be initialized with null or undefined, and treat them as dictionaries in which everything has its default value. r=peterv 2012-07-17 12:18:53 -04:00
Boris Zbarsky 2642932cab Bug 768537 part 1. Update parser support for dictionaries to spec changes. r=jlebar
There are several parts here:

1)  Enforce the requirement that dictionary arguments not followed by a required argument are optional.
2)  Make dictionaries no longer be distinguishable from nullable types.
3)  Disallow dictionaries or unions containing dictionaries inside a nullable type.
4)  Force optional dictionaries to have a default value of null so that codegen doesn't have to worry about dealing with
    optional arguments that have no default value in the IDL but need to be treated as if they were null.
2012-07-17 12:18:53 -04:00
Nathan Froyd bfff055672 Bug 370750 - consolidate mochitest files installation; r=glandium
With assistance on the patch from Ms2ger, Waldo, and Mossop.
2012-07-03 16:49:02 -04:00
Ehsan Akhgari 214d3ffb87 Backout changeset 4313740f1adc (bug 725907 part 3) under the suspicion of breaking Linux32 mochitest-chrome without framepointers 2012-07-04 19:25:56 -04:00
Jason Orendorff 545f40f1f8 Bug 725907 - for-of improvements, part 3: Implement .iterator() for arraylike DOM objects. r=bzbarsky.
--HG--
extra : rebase_source : 0820d3654318f217b8836a086234736d3aba3819
2012-07-03 16:34:56 -05:00
Siddharth Agarwal 4bee903659 Bug 770189 - dom/bindings/parser/runtests.py invocations need to be un-native-commandified. r=khuey 2012-07-03 02:02:42 +05:30
Boris Zbarsky 1055e80fc0 Bug 766796 followup to deal with lack of WebGL on Mac OS 10.5. No review. 2012-06-26 01:09:31 -04:00
Boris Zbarsky ea5efabae6 Bug 766796. Make IDL conversions to 64-bit ints treat NaN and Infinity as 0 instead of whatever the compiler decides to do in that undefined-behavior case. r=peterv 2012-06-25 23:37:47 -04:00
Peter Van der Beken 356f838036 Fix for bug 756258 (Support union types in new DOM bindings). r=bz.
--HG--
extra : rebase_source : 5352801a4eb5085f73a5b6e78aa238c5c9d44179
2012-05-18 23:25:47 +02:00
Boris Zbarsky 49e2a9624f Bug 742213. isDistinguishableFrom should correctly check whether two interfaces can be implemented on the same object. r=jlebar 2012-06-22 16:18:50 -04:00
Boris Zbarsky 990e87b0fb Add a test for enum inside dictionary. No bug, no review. 2012-06-21 12:29:11 -04:00
Ms2ger 8448d8d0e6 Bug 765704 - Don't throw when setting XHR.responseType to an invalid value; r=bz 2012-06-21 09:11:07 +02:00
Boris Zbarsky 03bc840cdd Bug 763911. Add support for interface members of dictionaries. r=khuey 2012-06-19 12:09:37 -04:00
Boris Zbarsky 41725e7de3 Bug 750297 part 1. Add support for objects that do not have a wrapper cache in WebIDL bindings. r=peterv 2012-06-15 16:25:50 -04:00
Boris Zbarsky cf8f8a0d31 Bug 742153 part 4. Allow strings inside sequences and dictionaries. r=peterv 2012-06-12 10:22:05 -04:00
Boris Zbarsky 6c6503abf1 Bug 742153 part 3. Implement codegen for dictionary arguments. r=peterv
Another implementation option would be to put all the dictionaries in a single
file and have a static global set of ids which works across all dictionaries
and is initialized once at startup or so.  That would also handle cross-file
dictionary inheritance better.

One problem that remains is the fake descriptor business.  At the moment this
does not allow interface types inside dictionaries.  We could probably work
around this by either refactoring code to make it possible to get the declType
independently of the actual conversion template (whether because it lives in a
separate function or because the conversion template generator knows to just
return an empty string when the fake descriptor provirder is passed) or by
figuring out a way to pass an actual descriptor provider to dictionary codegen.
2012-06-12 10:22:05 -04:00
Ed Morley 4c9a59e40a Merge last PGO-green changeset of mozilla-inbound to mozilla-central 2012-06-12 10:36:42 +01:00
Kyle Huey c8d931afa8 Bug 763573: Don't export PrimitiveConversions.h. r=bz 2012-06-11 13:04:34 -07:00
Ryan VanderMeulen 5f2a19ee6e Revert c39d36167b99 due to a horribly munged backout. 2012-06-10 19:44:50 -04:00
Ryan VanderMeulen 6d6c4efbab Backout the bug 754202 backout due to orange. 2012-06-10 19:37:47 -04:00
Boris Zbarsky 898e465bbb Bug 761772. Add support for 'implements' in WebIDL. r=khuey 2012-06-11 18:21:35 -04:00
Boris Zbarsky 3f47caaa36 Bug 761882. Run the WebIDL parser tests during make check. r=khuey 2012-06-08 17:41:16 -04:00
Boris Zbarsky bcf9d165ae Bug 760749. Make interface type constructor args work in WebIDL bindings. r=khuey 2012-06-04 21:30:00 -04:00
Boris Zbarsky aeb3270914 Add a simple codegen test for constructors. No review, no bug, DONTBUILD 2012-06-01 21:26:20 -04:00
Boris Zbarsky ac1bfb338d Bug 748266. Switch the WebGL canvas context to new DOM bindings. r=peterv 2012-05-31 14:16:48 -04:00
Boris Zbarsky 464164e820 Backed out changeset f96e0f078b49 (bug 748266) because the test suite is bogus and we're failing a crashtest too. 2012-05-31 16:20:49 -04:00
Boris Zbarsky 6af95f383e Bug 748266. Switch the WebGL canvas context to new DOM bindings. r=peterv 2012-05-31 14:16:48 -04:00
Peter Van der Beken 1b4c59974f Fix for bug 759278 (Support binarynames for attributes too in new DOM bindings). r=bz.
--HG--
extra : rebase_source : 352a4d33db77dd80915700db335799bb8c19ac72
2012-05-18 23:25:47 +02:00
Boris Zbarsky 45d8d74893 Add more tests for sequence and typed array codegen. No bug, no review. 2012-05-29 23:45:18 -04:00
Boris Zbarsky 702a4a496f Bug 743906 part 2. Use Optional<> for optional arguments that don't have default values. r=peterv 2012-05-29 23:45:18 -04:00
Boris Zbarsky d27336d5d7 Bug 743906 part 1. Improve test coverage for various interface arguments. r=peterv 2012-05-29 23:45:18 -04:00
Boris Zbarsky f99c90e58c Bug 755636 part 2. Add some tests (not exhaustive!) for sequence codegen and fix the bugs they uncover. r=peterv 2012-05-25 01:08:26 -04:00
Boris Zbarsky ab0daaf505 Bug 755080 part 3. Exercise castable interface types a bit. r=peterv 2012-05-23 12:44:48 -04:00
Boris Zbarsky b0ae5d38f1 Bug 755080 part 2. Exercise integer types a bit. r=peterv 2012-05-23 12:44:48 -04:00
Boris Zbarsky 1c6835bea3 Bug 755080 part 1. Add infrastructure for binding codegen tests. r=khuey,peterv 2012-05-23 12:44:48 -04:00
Peter Van der Beken 53f19cddef Fix for bug 742156 (Stringifying EventTarget throws): implement a toString method for interface objects. r=bz.
--HG--
extra : rebase_source : cd692b5231e4d183e0bbd368965e704ede54661f
2012-05-02 15:28:17 +02:00
Peter Van der Beken 174872c252 Fix for bug 744772 (Trace the DOM interface object array). r=bz.
--HG--
extra : rebase_source : c9f27bed0eab0e6db03295050176ef986cf0b59b
2012-05-02 14:49:43 +02:00
Boris Zbarsky 5b65f56e64 Bug 748983. Fix the instanceof behavior for new bindings in situations where we don't need a custom hasInstance hook. r=peterv 2012-05-03 00:35:38 -04:00
Peter Van der Beken ed510d3506 Fix for bug 740069 (Generate JS bindings in C++ with a python script for DOM objects on the main thread and in workers. Infrastructure and new bindings for XMLHttpRequest). Patch by bent/bz/bholley/jst/khuey/peterv, r=bent/bz/bholley/jlebar/khuey/peterv/sicking/smaug.
--HG--
rename : js/xpconnect/tests/mochitest/test_bug462428.html => dom/bindings/test/test_lookupGetter.html
2012-03-30 21:42:20 -07:00