4 def WebIDLTest(parser
, harness
):
9 undefined undefinedMember;
15 except WebIDL
.WebIDLError
:
18 harness
.ok(threw
, "undefined must not be used as the type of a dictionary member")
20 parser
= parser
.reset()
27 (undefined or double) undefinedMemberOfUnionInDict;
32 except WebIDL
.WebIDLError
:
37 "undefined must not be used as the type of a dictionary member, "
38 "whether directly or in a union",
41 parser
= parser
.reset()
48 double bar(undefined foo);
53 except WebIDL
.WebIDLError
:
58 "undefined must not be used as the type of an argument in any "
59 "circumstance (so not as the argument of a regular operation)",
62 parser
= parser
.reset()
69 getter double(undefined name);
74 except WebIDL
.WebIDLError
:
79 "undefined must not be used as the type of an argument in any "
80 "circumstance (so not as the argument of a getter)",
83 parser
= parser
.reset()
90 setter undefined(DOMString name, undefined value);
95 except WebIDL
.WebIDLError
:
100 "undefined must not be used as the type of an argument in any "
101 "circumstance (so not as the argument of a setter)",
104 parser
= parser
.reset()
111 deleter undefined (undefined name);
116 except WebIDL
.WebIDLError
:
121 "undefined must not be used as the type of an argument in any "
122 "circumstance (so not as the argument of a deleter)",
125 parser
= parser
.reset()
132 constructor (undefined foo);
137 except WebIDL
.WebIDLError
:
142 "undefined must not be used as the type of an argument in any "
143 "circumstance (so not as the argument of a constructor)",
146 parser
= parser
.reset()
152 callback Callback = undefined (undefined foo);
156 except WebIDL
.WebIDLError
:
161 "undefined must not be used as the type of an argument in any "
162 "circumstance (so not as the argument of a callback)",
165 parser
= parser
.reset()
172 async iterable(undefined name);
177 except WebIDL
.WebIDLError
:
182 "undefined must not be used as the type of an argument in any "
183 "circumstance (so not as the argument of an async iterable "
187 parser
= parser
.reset()
194 static double bar(undefined foo);
199 except WebIDL
.WebIDLError
:
204 "undefined must not be used as the type of an argument in any "
205 "circumstance (so not as the argument of a static operation)",
208 parser
= parser
.reset()
215 const undefined FOO = undefined;
220 except WebIDL
.WebIDLError
:
225 "undefined is not a valid type for a constant",
228 parser
= parser
.reset()
235 const any FOO = undefined;
240 except WebIDL
.WebIDLError
:
245 "undefined is not a valid value for a constant",