Commit Graph

48 Commits

Author SHA1 Message Date
Ehsan Akhgari
869f171923 Bug 785459 follow-up: use the python 2.5 syntax 2012-08-24 16:47:45 -04:00
Ehsan Akhgari
0ab97da3c8 Bug 785472 - The Web IDL parser should not allow inheriting from an interface that is only forward declared; r=khuey 2012-08-24 15:23:21 -04:00
Ehsan Akhgari
b1634fb871 Backout changeset 1142882b6c0b (bug 785472) because it breaks the build 2012-08-24 16:22:42 -04:00
Ehsan Akhgari
28893c29cf Bug 785472 - The Web IDL parser should not allow inheriting from an interface that is only forward declared; r=khuey 2012-08-24 15:23:21 -04:00
Ehsan Akhgari
aad48fec30 Bug 785459 - Enable the WebIDL parser to be used stand-alone for syntax checking; r=khuey 2012-08-24 14:51:45 -04:00
Peter Van der Beken
82dbb096f7 Fix for bug 742195 (Implement the extended attributes for null and undefined handling on strings in Paris bindings). r=bz. 2012-07-12 15:55:30 +02:00
Peter Van der Beken
13f425b97c 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
Boris Zbarsky
f9ac7c28ba Bug 771636 part 2. Implement default values for WebIDL enums. r=peterv 2012-07-31 00:22:23 -04:00
Boris Zbarsky
5186d5c397 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
1aab881a5b 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
a64bcb8bb8 Bug 777415. Disallow GetterInfallible/SetterInfallible annotations where they don't make sense. r=khuey 2012-07-27 00:09:10 -04:00
Boris Zbarsky
3268be0569 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
8e925299c6 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
8a2ea81bc5 Backout 9deb8edb5070 (bug 773519), ea5a243a60f1 & 0cad1e553bea (bug 768537) for compilation failures 2012-07-17 17:48:11 +01:00
Boris Zbarsky
56133baee1 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
Boris Zbarsky
43d3bd71ac Bug 757164. Move infallibility annotations into webidl. r=peterv
In this new setup, there are three new extended attributes: Infallible,
GetterInfallible, SetterInfallible.  The first one applies to both methods and
attributes, while the last two apply only to attributes.  Each one can be
either set with no value specified (in which case it applies both on main
thread and in workers) or can be set to MainThread or Workers to limit where it
applies.

If Infallible is set on an attribute, then GetterInfallible and
SetterInfallible will be ignored.  So if you want to specify, for example, an
attribute that's infallible on the main thread and has an infallible getter in
workers, the right way to do that is [GetterInfallible,
SetterInfallible=MainThread].
2012-07-13 19:29:14 -04:00
Boris Zbarsky
425f8c73e4 Bug 767352. Keep track of a method's overloads in a list of IDLMethodOverload objects. r=jlebar 2012-07-06 12:21:24 -04:00
Boris Zbarsky
7d734037c4 Bug 768190. Don't allow [TreatNullAs] or [TreatUndefinedAs] on dictionary members. r=jlebar 2012-06-30 01:53:32 -04:00
Boris Zbarsky
7f6400efa5 Bug 767546. Make the WebIDLError constructor take a list of locations. r=jlebar 2012-06-30 01:53:28 -04:00
Boris Zbarsky
6ced091cef Bug 768085. Speed up WebIDL tests and make them more usable by pickling the datastructures Yacc produces for the grammar and shutting up the logging it does in the debug mode we force it into. r=khuey 2012-06-25 23:35:42 -04:00
Peter Van der Beken
7efab19797 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
Peter Van der Beken
1e00518240 Fix for bug 765467 (Fix special operations in the WebIDL parser). r=khuey.
--HG--
extra : rebase_source : 4186629224c5e822473de1931604970106c721a6
2012-05-22 12:02:21 +02:00
Boris Zbarsky
db7164a75c Bug 766853 followup to address review comment. No review other than the other review. 2012-06-22 16:21:44 -04:00
Boris Zbarsky
c1cd32f316 Bug 766853. The two sides of an implements statement must both be non-callback interfaces. r=jlebar 2012-06-22 16:18:51 -04:00
Boris Zbarsky
bb2335a09e Bug 766844. Non-callback interfaces must not inherit from callback interfaces. r=jlebar 2012-06-22 16:18:51 -04:00
Boris Zbarsky
3e7e99e0c5 Bug 742152. Move distinguishing index determination and verification of type-identity of preceding arguments out of codegen and into the WebIDL parser. r=jlebar 2012-06-22 16:18:50 -04:00
Boris Zbarsky
c5731be201 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
7da04fee8b Bug 764456 part 1. Flag consequential interfaces in the WebIDL data model. r=khuey 2012-06-22 16:18:50 -04:00
Boris Zbarsky
d991f38a07 Bug 763724. Detect cycles in the interface inheritance and implementation graph. r=jlebar 2012-06-21 12:29:11 -04:00
Boris Zbarsky
22dc1c73f5 Bug 764698. Fix isDistinguishableFrom for dictionaries to work right. r=peterv 2012-06-21 12:29:11 -04:00
Boris Zbarsky
1a57def9ed Bug 763911. Add support for interface members of dictionaries. r=khuey 2012-06-19 12:09:37 -04:00
Boris Zbarsky
5e2f09ce01 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
cc973eeeb9 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
Boris Zbarsky
b38a6f1231 Bug 742153 part 1. Add support for dictionaries in the WebIDL parser. r=khuey 2012-06-12 10:22:05 -04:00
Boris Zbarsky
9921d8eb44 Bug 761772. Add support for 'implements' in WebIDL. r=khuey 2012-06-11 18:21:35 -04:00
Boris Zbarsky
c124f95e06 Bug 761882. Run the WebIDL parser tests during make check. r=khuey 2012-06-08 17:41:16 -04:00
Boris Zbarsky
bdb4852e6b Bug 742151. Fix the error reporting in the WebIDL parser to list correct line numbers. r=khuey
There are two changes here.  One is to pass tracking=True to our parser.  This makes it properly track positions
of all productions, not just of lexer tokens.  The second is to properly count up our newlines in the lex data,
since the lexer seems to report the line number of the start of the lex data, which is always 1 in our case.
2012-06-04 21:30:03 -04:00
Boris Zbarsky
3fe02376e3 Bug 760749. Make interface type constructor args work in WebIDL bindings. r=khuey 2012-06-04 21:30:00 -04:00
Boris Zbarsky
78bc29d95f Bug 750264. Give IDLType an operator!= so that codegen actually works correctly. r=khuey 2012-05-25 01:07:30 -04:00
Kyle Huey
dccb34092f Update webidl-parser snapshot to pick up bug 742145. 2012-05-24 21:41:33 -07:00
Gervase Markham
ca171eec44 Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
Boris Zbarsky
f9c55c7598 Bug 748267 part 3. Codegen for sequence return values. r=peterv
The big block in getRetvalDeclarationForType is just direct cut/paste from CGCallGenerator plus the addition of the sequence case.  The IDL parser changes were OKed by khuey; they're needed so that we don't have to worry about the ordering of sequence with conversions for strings and primitives.
2012-05-15 14:23:29 -04:00
Kyle Huey
f008076292 Update the WebIDL Parser to pick up Bug 753459. r=bz 2012-05-09 11:49:56 -07:00
Kyle Huey
e69d4afe08 Sync webidl-parser to m-c to pick up Bug 742141. r=me a=me 2012-05-01 23:23:45 -04:00
Boris Zbarsky
427126be53 Bug 743820. Update to the changes to WebIDL that made interfaces with indexed properties distinguishable from array and sequence. r=khuey
There are two parts to this change:
1)  Sequences and arrays are now distinguishable from all non-callback interfaces.
2)  To handle that change, overload resolution first tries to convert to the exact
    interface, and only if that fails tries to convert things with indexed properties
    to sequences or arrays.
2012-04-13 13:52:21 -04:00
Kyle Huey
4c09299fd0 Bug 741125: Update WebIDL parser. 2012-04-12 15:14:10 -07:00
Boris Zbarsky
0744334b26 Bug 742167. Give extendedAttribute() a better name. r=khuey 2012-04-10 12:40:12 -04:00
Peter Van der Beken
c2e642fbcc 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