Changeset 197060 in webkit
- Timestamp:
- Feb 24, 2016, 6:39:19 PM (11 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 46 edited
-
ChangeLog (modified) (1 diff)
-
Modules/fetch/FetchHeaders.idl (modified) (1 diff)
-
Modules/indexeddb/IDBObjectStore.idl (modified) (1 diff)
-
Modules/mediasource/DOMURLMediaSource.idl (modified) (1 diff)
-
Modules/mediastream/DOMURLMediaStream.idl (modified) (1 diff)
-
Modules/websockets/WebSocket.idl (modified) (1 diff)
-
bindings/scripts/CodeGeneratorJS.pm (modified) (1 diff)
-
bindings/scripts/IDLAttributes.txt (modified) (1 diff)
-
bindings/scripts/IDLParser.pm (modified) (3 diffs)
-
bindings/scripts/test/GObject/WebKitDOMTestObj.cpp (modified) (2 diffs)
-
bindings/scripts/test/GObject/WebKitDOMTestObj.h (modified) (2 diffs)
-
bindings/scripts/test/JS/JSTestObj.cpp (modified) (10 diffs)
-
bindings/scripts/test/JS/JSTestObj.h (modified) (3 diffs)
-
bindings/scripts/test/ObjC/DOMTestObj.h (modified) (2 diffs)
-
bindings/scripts/test/ObjC/DOMTestObj.mm (modified) (2 diffs)
-
bindings/scripts/test/TestObj.idl (modified) (2 diffs)
-
css/CSSCharsetRule.idl (modified) (1 diff)
-
css/CSSImportRule.idl (modified) (1 diff)
-
css/CSSKeyframesRule.idl (modified) (1 diff)
-
css/CSSPageRule.idl (modified) (1 diff)
-
css/CSSRule.idl (modified) (1 diff)
-
css/CSSStyleDeclaration.idl (modified) (2 diffs)
-
css/CSSStyleRule.idl (modified) (1 diff)
-
css/CSSValue.idl (modified) (2 diffs)
-
css/MediaList.idl (modified) (1 diff)
-
css/StyleSheet.idl (modified) (1 diff)
-
dom/Attr.idl (modified) (1 diff)
-
dom/CharacterData.idl (modified) (1 diff)
-
dom/DOMStringList.idl (modified) (1 diff)
-
dom/Document.idl (modified) (3 diffs)
-
dom/DocumentType.idl (modified) (1 diff)
-
dom/Element.idl (modified) (2 diffs)
-
dom/Entity.idl (modified) (1 diff)
-
dom/MutationRecord.idl (modified) (1 diff)
-
dom/Node.idl (modified) (3 diffs)
-
dom/ProcessingInstruction.idl (modified) (1 diff)
-
html/DOMSettableTokenList.idl (modified) (1 diff)
-
html/DOMTokenList.idl (modified) (1 diff)
-
html/DOMURL.idl (modified) (1 diff)
-
html/canvas/WebGLDebugShaders.idl (modified) (1 diff)
-
html/canvas/WebGLRenderingContextBase.idl (modified) (1 diff)
-
page/DOMWindow.idl (modified) (1 diff)
-
storage/Storage.idl (modified) (1 diff)
-
storage/StorageEvent.idl (modified) (1 diff)
-
xml/XMLHttpRequest.idl (modified) (1 diff)
-
xml/XPathNSResolver.idl (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r197058 r197060 1 2016-02-24 Chris Dumez <cdumez@apple.com> 2 3 Drop [TreatReturnedNullStringAs=Null] WebKit-specific IDL attribute 4 https://bugs.webkit.org/show_bug.cgi?id=154659 5 6 Reviewed by Sam Weinig. 7 8 Drop [TreatReturnedNullStringAs=Null] WebKit-specific IDL attribute and 9 use nullable DOMString types instead: 10 http://heycam.github.io/webidl/#idl-nullable-type 11 12 This is the standard way of doing things. We already had support 13 in the bindings generator for nullable DOMString attributes so 14 we now just leverage this support. However, our IDL parser did 15 not correctly parse nullable DOMString return values for operations. 16 This patch fixes this. 17 18 This patch also drops [TreatNullAs=NullString] and 19 [TreatUndefinedAs=NullString] for writable DOMString attributes that 20 are now marked as nullable because they are implied. 21 22 * Modules/fetch/FetchHeaders.idl: 23 * Modules/indexeddb/IDBObjectStore.idl: 24 * Modules/mediasource/DOMURLMediaSource.idl: 25 * Modules/mediastream/DOMURLMediaStream.idl: 26 * Modules/websockets/WebSocket.idl: 27 * bindings/scripts/CodeGeneratorJS.pm: 28 (NativeToJSValue): Deleted. 29 * bindings/scripts/IDLAttributes.txt: 30 * bindings/scripts/IDLParser.pm: 31 (parseAttributeOrOperationRest): 32 (parseOperationOrIterator): 33 (parseSpecialOperation): 34 * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp: 35 (webkit_dom_test_obj_nullable_string_method): 36 (webkit_dom_test_obj_nullable_string_special_method): 37 (webkit_dom_test_obj_conditional_method3): Deleted. 38 (webkit_dom_test_obj_convert1): Deleted. 39 * bindings/scripts/test/GObject/WebKitDOMTestObj.h: 40 * bindings/scripts/test/JS/JSTestObj.cpp: 41 (WebCore::JSTestObj::getOwnPropertySlot): 42 (WebCore::JSTestObj::getOwnPropertySlotByIndex): 43 (WebCore::JSTestObj::getOwnPropertyNames): 44 (WebCore::jsTestObjPrototypeFunctionNullableStringMethod): 45 (WebCore::jsTestObjConstructorFunctionNullableStringStaticMethod): 46 (WebCore::jsTestObjPrototypeFunctionNullableStringSpecialMethod): 47 (WebCore::jsTestObjPrototypeFunctionMethodWithAndWithoutNullableSequence): Deleted. 48 (WebCore::jsTestObjPrototypeFunctionMethodWithAndWithoutNullableSequence2): Deleted. 49 * bindings/scripts/test/JS/JSTestObj.h: 50 * bindings/scripts/test/ObjC/DOMTestObj.h: 51 * bindings/scripts/test/ObjC/DOMTestObj.mm: 52 (-[DOMTestObj nullableStringMethod]): 53 (-[DOMTestObj nullableStringStaticMethod]): 54 (-[DOMTestObj nullableStringSpecialMethod:]): 55 (-[DOMTestObj overloadedMethod1:]): Deleted. 56 (-[DOMTestObj getSVGDocument]): Deleted. 57 * bindings/scripts/test/TestObj.idl: 58 * css/CSSCharsetRule.idl: 59 * css/CSSImportRule.idl: 60 * css/CSSKeyframesRule.idl: 61 * css/CSSPageRule.idl: 62 * css/CSSRule.idl: 63 * css/CSSStyleDeclaration.idl: 64 * css/CSSStyleRule.idl: 65 * css/CSSValue.idl: 66 * css/MediaList.idl: 67 * css/StyleSheet.idl: 68 * dom/Attr.idl: 69 * dom/CharacterData.idl: 70 * dom/DOMStringList.idl: 71 * dom/Document.idl: 72 * dom/DocumentType.idl: 73 * dom/Element.idl: 74 * dom/Entity.idl: 75 * dom/MutationRecord.idl: 76 * dom/Node.idl: 77 * dom/ProcessingInstruction.idl: 78 * html/DOMSettableTokenList.idl: 79 * html/DOMTokenList.idl: 80 * html/DOMURL.idl: 81 * html/canvas/WebGLDebugShaders.idl: 82 * html/canvas/WebGLRenderingContextBase.idl: 83 * page/DOMWindow.idl: 84 * storage/Storage.idl: 85 * storage/StorageEvent.idl: 86 * xml/XMLHttpRequest.idl: 87 * xml/XPathNSResolver.idl: 88 1 89 2016-02-24 Nikos Andronikos <nikos.andronikos-webkit@cisra.canon.com.au> 2 90 -
trunk/Source/WebCore/Modules/fetch/FetchHeaders.idl
r197026 r197060 37 37 [RaisesException] void append(DOMString name, DOMString value); 38 38 [RaisesException, ImplementedAs=remove] void delete(DOMString name); 39 [RaisesException , TreatReturnedNullStringAs=Null] DOMStringget(DOMString name);39 [RaisesException] DOMString? get(DOMString name); 40 40 [RaisesException] boolean has(DOMString name); 41 41 [RaisesException] void set(DOMString name, DOMString value); -
trunk/Source/WebCore/Modules/indexeddb/IDBObjectStore.idl
r196482 r197060 31 31 GenerateIsReachable=Impl, 32 32 ] interface IDBObjectStore { 33 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringname;33 readonly attribute DOMString? name; 34 34 [ImplementedAs=keyPathAny] readonly attribute IDBAny keyPath; 35 35 readonly attribute DOMStringList indexNames; -
trunk/Source/WebCore/Modules/mediasource/DOMURLMediaSource.idl
r158288 r197060 32 32 ] 33 33 partial interface DOMURL { 34 [CallWith=ScriptExecutionContext ,TreatReturnedNullStringAs=Null] static DOMStringcreateObjectURL(MediaSource? source);34 [CallWith=ScriptExecutionContext] static DOMString? createObjectURL(MediaSource? source); 35 35 }; -
trunk/Source/WebCore/Modules/mediastream/DOMURLMediaStream.idl
r157054 r197060 32 32 ] 33 33 partial interface DOMURL { 34 [CallWith=ScriptExecutionContext ,TreatReturnedNullStringAs=Null] static DOMStringcreateObjectURL(MediaStream? stream);34 [CallWith=ScriptExecutionContext] static DOMString? createObjectURL(MediaStream? stream); 35 35 }; -
trunk/Source/WebCore/Modules/websockets/WebSocket.idl
r196568 r197060 58 58 attribute EventHandler onclose; 59 59 60 [TreatReturnedNullStringAs=Undefined] readonly attribute DOMStringprotocol;61 [TreatReturnedNullStringAs=Undefined] readonly attribute DOMStringextensions;60 readonly attribute DOMString? protocol; 61 readonly attribute DOMString? extensions; 62 62 63 63 attribute DOMString binaryType; -
trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
r197028 r197060 4263 4263 my $conv = $signature->extendedAttributes->{"TreatReturnedNullStringAs"}; 4264 4264 if (defined $conv) { 4265 return "jsStringOrNull(state, $value)" if $conv eq "Null";4266 4265 return "jsStringOrUndefined(state, $value)" if $conv eq "Undefined"; 4267 4266 -
trunk/Source/WebCore/bindings/scripts/IDLAttributes.txt
r196568 r197060 122 122 TreatNullAs=NullString 123 123 TreatReturnedNaNDateAs=Null|NaN 124 TreatReturnedNullStringAs= Null|Undefined124 TreatReturnedNullStringAs=Undefined 125 125 TreatUndefinedAs=NullString 126 126 TypedArray=* -
trunk/Source/WebCore/bindings/scripts/IDLParser.pm
r196900 r197060 1126 1126 my $interface = $self->parseOperationRest($extendedAttributeList); 1127 1127 if (defined ($interface)) { 1128 $interface->signature->type($returnType); 1128 if (typeHasNullableSuffix($returnType)) { 1129 $interface->signature->isNullable(1); 1130 } else { 1131 $interface->signature->isNullable(0); 1132 } 1133 $interface->signature->type(typeRemoveNullableSuffix($returnType)); 1129 1134 } 1130 1135 return $interface; … … 1224 1229 if ($next->type() == IdentifierToken || $next->value() eq "(") { 1225 1230 my $operation = $self->parseOperationRest($extendedAttributeList); 1226 $operation->signature->type($returnType); 1231 if (typeHasNullableSuffix($returnType)) { 1232 $operation->signature->isNullable(1); 1233 } else { 1234 $operation->signature->isNullable(0); 1235 } 1236 $operation->signature->type(typeRemoveNullableSuffix($returnType)); 1237 1227 1238 return $operation; 1228 1239 } … … 1243 1254 my $interface = $self->parseOperationRest($extendedAttributeList); 1244 1255 if (defined ($interface)) { 1245 $interface->signature->type($returnType); 1246 $interface->signature->specials(\@specials); 1256 if (typeHasNullableSuffix($returnType)) { 1257 $interface->signature->isNullable(1); 1258 } else { 1259 $interface->signature->isNullable(0); 1260 } 1261 $interface->signature->type(typeRemoveNullableSuffix($returnType)); 1262 1263 $interface->signature->specials(\@specials); 1247 1264 } 1248 1265 return $interface; -
trunk/Source/WebCore/bindings/scripts/test/GObject/WebKitDOMTestObj.cpp
r196894 r197060 1253 1253 } 1254 1254 1255 gchar* webkit_dom_test_obj_nullable_string_method(WebKitDOMTestObj* self) 1256 { 1257 WebCore::JSMainThreadNullState state; 1258 g_return_val_if_fail(WEBKIT_DOM_IS_TEST_OBJ(self), 0); 1259 WebCore::TestObj* item = WebKit::core(self); 1260 gchar* result = convertToUTF8String(item->nullableStringMethod()); 1261 return result; 1262 } 1263 1264 gchar* webkit_dom_test_obj_nullable_string_special_method(WebKitDOMTestObj* self, gulong index) 1265 { 1266 WebCore::JSMainThreadNullState state; 1267 g_return_val_if_fail(WEBKIT_DOM_IS_TEST_OBJ(self), 0); 1268 WebCore::TestObj* item = WebKit::core(self); 1269 gchar* result = convertToUTF8String(item->nullableStringSpecialMethod(index)); 1270 return result; 1271 } 1272 1255 1273 void webkit_dom_test_obj_method_with_enum_arg(WebKitDOMTestObj* self, WebKitDOMTestEnumType* enumArg) 1256 1274 { … … 1548 1566 WebCore::TestNode* convertedValue = WebKit::core(value); 1549 1567 item->convert1(convertedValue); 1550 }1551 1552 void webkit_dom_test_obj_convert2(WebKitDOMTestObj* self, WebKitDOMTestNode* value)1553 {1554 WebCore::JSMainThreadNullState state;1555 g_return_if_fail(WEBKIT_DOM_IS_TEST_OBJ(self));1556 g_return_if_fail(WEBKIT_DOM_IS_TEST_NODE(value));1557 WebCore::TestObj* item = WebKit::core(self);1558 WebCore::TestNode* convertedValue = WebKit::core(value);1559 item->convert2(convertedValue);1560 1568 } 1561 1569 -
trunk/Source/WebCore/bindings/scripts/test/GObject/WebKitDOMTestObj.h
r196894 r197060 248 248 249 249 /** 250 * webkit_dom_test_obj_nullable_string_method: 251 * @self: A #WebKitDOMTestObj 252 * 253 * Returns: A #gchar 254 * 255 * Stability: Unstable 256 **/ 257 WEBKIT_API gchar* 258 webkit_dom_test_obj_nullable_string_method(WebKitDOMTestObj* self); 259 260 /** 261 * webkit_dom_test_obj_nullable_string_special_method: 262 * @self: A #WebKitDOMTestObj 263 * @index: A #gulong 264 * 265 * Returns: A #gchar 266 * 267 * Stability: Unstable 268 **/ 269 WEBKIT_API gchar* 270 webkit_dom_test_obj_nullable_string_special_method(WebKitDOMTestObj* self, gulong index); 271 272 /** 250 273 * webkit_dom_test_obj_method_with_enum_arg: 251 274 * @self: A #WebKitDOMTestObj … … 525 548 WEBKIT_API void 526 549 webkit_dom_test_obj_convert1(WebKitDOMTestObj* self, WebKitDOMTestNode* value); 527 528 /**529 * webkit_dom_test_obj_convert2:530 * @self: A #WebKitDOMTestObj531 * @value: A #WebKitDOMTestNode532 *533 * Stability: Unstable534 **/535 WEBKIT_API void536 webkit_dom_test_obj_convert2(WebKitDOMTestObj* self, WebKitDOMTestNode* value);537 550 538 551 /** -
trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp
r196900 r197060 64 64 #include <runtime/JSArray.h> 65 65 #include <runtime/JSString.h> 66 #include <runtime/PropertyNameArray.h> 66 67 #include <runtime/Symbol.h> 67 68 #include <wtf/GetPtr.h> … … 100 101 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionObjMethodWithArgs(JSC::ExecState*); 101 102 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjInstanceFunctionUnforgeableMethod(JSC::ExecState*); 103 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionNullableStringMethod(JSC::ExecState*); 104 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjConstructorFunctionNullableStringStaticMethod(JSC::ExecState*); 105 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionNullableStringSpecialMethod(JSC::ExecState*); 102 106 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionMethodWithSequenceArg(JSC::ExecState*); 103 107 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionMethodReturningSequence(JSC::ExecState*); … … 164 168 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionGetSVGDocument(JSC::ExecState*); 165 169 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionConvert1(JSC::ExecState*); 166 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionConvert2(JSC::ExecState*);167 170 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionConvert4(JSC::ExecState*); 168 171 JSC::EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionConvert5(JSC::ExecState*); … … 444 447 { "TestSubObj", DontDelete | ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestObjConstructorTestSubObj), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } }, 445 448 { "staticReadOnlySymbolAttr", DontDelete | ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestObjConstructorStaticReadOnlySymbolAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } }, 449 { "nullableStringStaticMethod", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjConstructorFunctionNullableStringStaticMethod), (intptr_t) (0) } }, 446 450 { "staticMethodWithCallbackAndOptionalArg", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjConstructorFunctionStaticMethodWithCallbackAndOptionalArg), (intptr_t) (0) } }, 447 451 { "staticMethodWithCallbackArg", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjConstructorFunctionStaticMethodWithCallbackArg), (intptr_t) (1) } }, … … 612 616 { "objMethod", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionObjMethod), (intptr_t) (0) } }, 613 617 { "objMethodWithArgs", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionObjMethodWithArgs), (intptr_t) (3) } }, 618 { "nullableStringMethod", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionNullableStringMethod), (intptr_t) (0) } }, 619 { "nullableStringSpecialMethod", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionNullableStringSpecialMethod), (intptr_t) (1) } }, 614 620 { "methodWithSequenceArg", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionMethodWithSequenceArg), (intptr_t) (1) } }, 615 621 { "methodReturningSequence", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionMethodReturningSequence), (intptr_t) (1) } }, … … 685 691 { "getSVGDocument", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionGetSVGDocument), (intptr_t) (0) } }, 686 692 { "convert1", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionConvert1), (intptr_t) (1) } }, 687 { "convert2", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionConvert2), (intptr_t) (1) } },688 693 { "convert4", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionConvert4), (intptr_t) (1) } }, 689 694 { "convert5", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjPrototypeFunctionConvert5), (intptr_t) (1) } }, … … 763 768 auto* thisObject = jsCast<JSTestObj*>(object); 764 769 ASSERT_GC_OBJECT_INHERITS(thisObject, info()); 770 Optional<uint32_t> optionalIndex = parseIndex(propertyName); 771 if (optionalIndex) { 772 unsigned index = optionalIndex.value(); 773 unsigned attributes = DontDelete | ReadOnly; 774 slot.setValue(thisObject, attributes, jsStringOrUndefined(state, thisObject->wrapped().item(index))); 775 return true; 776 } 765 777 if (getStaticPropertySlot<JSTestObj, Base>(state, JSTestObjTable, thisObject, propertyName, slot)) 766 778 return true; 767 779 return false; 780 } 781 782 bool JSTestObj::getOwnPropertySlotByIndex(JSObject* object, ExecState* state, unsigned index, PropertySlot& slot) 783 { 784 auto* thisObject = jsCast<JSTestObj*>(object); 785 ASSERT_GC_OBJECT_INHERITS(thisObject, info()); 786 if (index <= MAX_ARRAY_INDEX) { 787 unsigned attributes = DontDelete | ReadOnly; 788 slot.setValue(thisObject, attributes, jsStringOrUndefined(state, thisObject->wrapped().item(index))); 789 return true; 790 } 791 return Base::getOwnPropertySlotByIndex(thisObject, state, index, slot); 768 792 } 769 793 … … 3076 3100 3077 3101 3102 void JSTestObj::getOwnPropertyNames(JSObject* object, ExecState* state, PropertyNameArray& propertyNames, EnumerationMode mode) 3103 { 3104 auto* thisObject = jsCast<JSTestObj*>(object); 3105 ASSERT_GC_OBJECT_INHERITS(thisObject, info()); 3106 for (unsigned i = 0, count = thisObject->wrapped().length(); i < count; ++i) 3107 propertyNames.add(Identifier::from(state, i)); 3108 Base::getOwnPropertyNames(thisObject, state, propertyNames, mode); 3109 } 3110 3078 3111 JSValue JSTestObj::getConstructor(VM& vm, const JSGlobalObject* globalObject) 3079 3112 { … … 3265 3298 auto& impl = castedThis->wrapped(); 3266 3299 JSValue result = jsNumber(impl.unforgeableMethod()); 3300 return JSValue::encode(result); 3301 } 3302 3303 EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionNullableStringMethod(ExecState* state) 3304 { 3305 JSValue thisValue = state->thisValue(); 3306 auto castedThis = jsDynamicCast<JSTestObj*>(thisValue); 3307 if (UNLIKELY(!castedThis)) 3308 return throwThisTypeError(*state, "TestObj", "nullableStringMethod"); 3309 ASSERT_GC_OBJECT_INHERITS(castedThis, JSTestObj::info()); 3310 auto& impl = castedThis->wrapped(); 3311 JSValue result = jsStringOrNull(state, impl.nullableStringMethod()); 3312 return JSValue::encode(result); 3313 } 3314 3315 EncodedJSValue JSC_HOST_CALL jsTestObjConstructorFunctionNullableStringStaticMethod(ExecState* state) 3316 { 3317 JSValue result = jsStringOrNull(state, TestObj::nullableStringStaticMethod()); 3318 return JSValue::encode(result); 3319 } 3320 3321 EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionNullableStringSpecialMethod(ExecState* state) 3322 { 3323 JSValue thisValue = state->thisValue(); 3324 auto castedThis = jsDynamicCast<JSTestObj*>(thisValue); 3325 if (UNLIKELY(!castedThis)) 3326 return throwThisTypeError(*state, "TestObj", "nullableStringSpecialMethod"); 3327 ASSERT_GC_OBJECT_INHERITS(castedThis, JSTestObj::info()); 3328 auto& impl = castedThis->wrapped(); 3329 if (UNLIKELY(state->argumentCount() < 1)) 3330 return throwVMError(state, createNotEnoughArgumentsError(state)); 3331 unsigned index = toUInt32(state, state->argument(0), NormalConversion); 3332 if (UNLIKELY(state->hadException())) 3333 return JSValue::encode(jsUndefined()); 3334 JSValue result = jsStringOrNull(state, impl.nullableStringSpecialMethod(index)); 3267 3335 return JSValue::encode(result); 3268 3336 } … … 4559 4627 } 4560 4628 4561 EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionConvert2(ExecState* state)4562 {4563 JSValue thisValue = state->thisValue();4564 auto castedThis = jsDynamicCast<JSTestObj*>(thisValue);4565 if (UNLIKELY(!castedThis))4566 return throwThisTypeError(*state, "TestObj", "convert2");4567 ASSERT_GC_OBJECT_INHERITS(castedThis, JSTestObj::info());4568 auto& impl = castedThis->wrapped();4569 if (UNLIKELY(state->argumentCount() < 1))4570 return throwVMError(state, createNotEnoughArgumentsError(state));4571 TestNode* value = JSTestNode::toWrapped(state->argument(0));4572 if (UNLIKELY(state->hadException()))4573 return JSValue::encode(jsUndefined());4574 impl.convert2(value);4575 return JSValue::encode(jsUndefined());4576 }4577 4578 4629 EncodedJSValue JSC_HOST_CALL jsTestObjPrototypeFunctionConvert4(ExecState* state) 4579 4630 { -
trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h
r197028 r197060 44 44 static TestObj* toWrapped(JSC::JSValue); 45 45 static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&); 46 static bool getOwnPropertySlotByIndex(JSC::JSObject*, JSC::ExecState*, unsigned propertyName, JSC::PropertySlot&); 46 47 static void destroy(JSC::JSCell*); 47 48 … … 53 54 } 54 55 56 static void getOwnPropertyNames(JSC::JSObject*, JSC::ExecState*, JSC::PropertyNameArray&, JSC::EnumerationMode = JSC::EnumerationMode()); 55 57 static JSC::JSValue getConstructor(JSC::VM&, const JSC::JSGlobalObject*); 56 58 mutable JSC::WriteBarrier<JSC::Unknown> m_cachedAttribute1; … … 68 70 static JSC::JSValue classMethod2(JSC::ExecState&); 69 71 public: 70 static const unsigned StructureFlags = JSC:: OverridesGetOwnPropertySlot| Base::StructureFlags;72 static const unsigned StructureFlags = JSC::InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero | JSC::OverridesGetOwnPropertySlot | JSC::OverridesGetPropertyNames | Base::StructureFlags; 71 73 protected: 72 74 JSTestObj(JSC::Structure*, JSDOMGlobalObject&, Ref<TestObj>&&); -
trunk/Source/WebCore/bindings/scripts/test/ObjC/DOMTestObj.h
r196894 r197060 144 144 - (DOMTestObj *)objMethodWithArgs:(int)longArg strArg:(NSString *)strArg objArg:(DOMTestObj *)objArg; 145 145 - (int)unforgeableMethod; 146 - (NSString *)nullableStringMethod; 147 - (NSString *)nullableStringStaticMethod; 148 - (NSString *)nullableStringSpecialMethod:(unsigned)index; 146 149 - (void)methodWithEnumArg:(DOMTestEnumType *)enumArg; 147 150 - (void)methodWithOptionalEnumArgAndDefaultValue:(DOMTestEnumType *)enumArg; … … 177 180 - (DOMSVGDocument *)getSVGDocument; 178 181 - (void)convert1:(DOMTestNode *)value; 179 - (void)convert2:(DOMTestNode *)value;180 182 - (void)convert4:(DOMTestNode *)value; 181 183 - (void)convert5:(DOMTestNode *)value; -
trunk/Source/WebCore/bindings/scripts/test/ObjC/DOMTestObj.mm
r196894 r197060 982 982 } 983 983 984 - (NSString *)nullableStringMethod 985 { 986 WebCore::JSMainThreadNullState state; 987 return IMPL->nullableStringMethod(); 988 } 989 990 - (NSString *)nullableStringStaticMethod 991 { 992 WebCore::JSMainThreadNullState state; 993 return IMPL->nullableStringStaticMethod(); 994 } 995 996 - (NSString *)nullableStringSpecialMethod:(unsigned)index 997 { 998 WebCore::JSMainThreadNullState state; 999 return IMPL->nullableStringSpecialMethod(index); 1000 } 1001 984 1002 - (void)methodWithEnumArg:(DOMTestEnumType *)enumArg 985 1003 { … … 1266 1284 WebCore::JSMainThreadNullState state; 1267 1285 IMPL->convert1(core(value)); 1268 }1269 1270 - (void)convert2:(DOMTestNode *)value1271 {1272 WebCore::JSMainThreadNullState state;1273 IMPL->convert2(core(value));1274 1286 } 1275 1287 -
trunk/Source/WebCore/bindings/scripts/test/TestObj.idl
r196900 r197060 98 98 [Unforgeable] long unforgeableMethod(); 99 99 100 // Nullable String return values. 101 DOMString? nullableStringMethod(); 102 static DOMString? nullableStringStaticMethod(); 103 getter DOMString? nullableStringSpecialMethod(unsigned long index); 104 100 105 void methodWithSequenceArg(sequence<ScriptProfile> sequenceArg); 101 106 sequence<ScriptProfile> methodReturningSequence(long longArg); … … 257 262 [CheckSecurityForNode, RaisesException] SVGDocument getSVGDocument(); 258 263 259 void convert1([TreatReturnedNullStringAs=Null] TestNode value); 260 void convert2([TreatReturnedNullStringAs=Undefined] TestNode value); 264 void convert1(TestNode value); 261 265 void convert4([TreatNullAs=NullString] TestNode value); 262 266 void convert5([TreatNullAs=NullString, TreatUndefinedAs=NullString] TestNode value); -
trunk/Source/WebCore/css/CSSCharsetRule.idl
r151321 r197060 22 22 interface CSSCharsetRule : CSSRule { 23 23 #if defined(LANGUAGE_OBJECTIVE_C) && LANGUAGE_OBJECTIVE_C 24 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringencoding;24 readonly attribute DOMString? encoding; 25 25 #else 26 [ TreatReturnedNullStringAs=Null, TreatNullAs=NullString, SetterRaisesException] attribute DOMStringencoding;26 [SetterRaisesException] attribute DOMString? encoding; 27 27 #endif 28 28 }; -
trunk/Source/WebCore/css/CSSImportRule.idl
r131172 r197060 21 21 // Introduced in DOM Level 2: 22 22 interface CSSImportRule : CSSRule { 23 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringhref;23 readonly attribute DOMString? href; 24 24 readonly attribute MediaList media; 25 25 readonly attribute CSSStyleSheet styleSheet; -
trunk/Source/WebCore/css/CSSKeyframesRule.idl
r176157 r197060 28 28 29 29 interface CSSKeyframesRule : CSSRule { 30 31 [TreatReturnedNullStringAs=Null, TreatNullAs=NullString] attribute DOMString name; 30 attribute DOMString? name; 32 31 readonly attribute CSSRuleList cssRules; 33 32 -
trunk/Source/WebCore/css/CSSPageRule.idl
r131172 r197060 21 21 // Introduced in DOM Level 2: 22 22 interface CSSPageRule : CSSRule { 23 24 [TreatReturnedNullStringAs=Null, TreatNullAs=NullString] attribute DOMString selectorText; 23 attribute DOMString? selectorText; 25 24 26 25 readonly attribute CSSStyleDeclaration style; 27 28 26 }; 29 27 -
trunk/Source/WebCore/css/CSSRule.idl
r176157 r197060 51 51 readonly attribute unsigned short type; 52 52 53 [ TreatReturnedNullStringAs=Null, TreatNullAs=NullString, SetterRaisesException] attribute DOMStringcssText;53 [SetterRaisesException] attribute DOMString? cssText; 54 54 55 55 readonly attribute CSSStyleSheet parentStyleSheet; -
trunk/Source/WebCore/css/CSSStyleDeclaration.idl
r187813 r197060 29 29 SkipVTableValidation, 30 30 ] interface CSSStyleDeclaration { 31 [ TreatReturnedNullStringAs=Null, TreatNullAs=NullString, SetterRaisesException] attribute DOMStringcssText;31 [SetterRaisesException] attribute DOMString? cssText; 32 32 33 33 DOMString getPropertyValue([Default=Undefined] DOMString propertyName); 34 34 [Custom] CSSValue getPropertyCSSValue([Default=Undefined] optional DOMString propertyName); 35 [ TreatReturnedNullStringAs=Null,RaisesException] DOMString removeProperty([Default=Undefined] optional DOMString propertyName);36 [TreatReturnedNullStringAs=Null] DOMStringgetPropertyPriority([Default=Undefined] optional DOMString propertyName);35 [RaisesException] DOMString removeProperty([Default=Undefined] optional DOMString propertyName); 36 DOMString? getPropertyPriority([Default=Undefined] optional DOMString propertyName); 37 37 [ObjCLegacyUnnamedParameters, RaisesException] void setProperty([Default=Undefined] optional DOMString propertyName, 38 38 [TreatNullAs=NullString, Default=Undefined] optional DOMString value, … … 44 44 45 45 // Extensions 46 [TreatReturnedNullStringAs=Null] DOMStringgetPropertyShorthand([Default=Undefined] optional DOMString propertyName);46 DOMString? getPropertyShorthand([Default=Undefined] optional DOMString propertyName); 47 47 boolean isPropertyImplicit([Default=Undefined] optional DOMString propertyName); 48 48 }; -
trunk/Source/WebCore/css/CSSStyleRule.idl
r131172 r197060 21 21 // Introduced in DOM Level 2: 22 22 interface CSSStyleRule : CSSRule { 23 24 [TreatReturnedNullStringAs=Null, TreatNullAs=NullString] attribute DOMString selectorText; 23 attribute DOMString? selectorText; 25 24 26 25 readonly attribute CSSStyleDeclaration style; 27 28 26 }; 29 27 -
trunk/Source/WebCore/css/CSSValue.idl
r151321 r197060 26 26 ImplementationLacksVTable 27 27 ] interface CSSValue { 28 29 28 // UnitTypes 30 29 const unsigned short CSS_INHERIT = 0; … … 33 32 const unsigned short CSS_CUSTOM = 3; 34 33 35 [ TreatReturnedNullStringAs=Null, TreatNullAs=NullString, SetterRaisesException] attribute DOMStringcssText;34 [SetterRaisesException] attribute DOMString? cssText; 36 35 37 36 readonly attribute unsigned short cssValueType; 38 39 37 }; 40 38 -
trunk/Source/WebCore/css/MediaList.idl
r165676 r197060 31 31 ] interface MediaList { 32 32 33 [ TreatNullAs=NullString, TreatReturnedNullStringAs=Null, SetterRaisesException] attribute DOMStringmediaText;33 [SetterRaisesException] attribute DOMString? mediaText; 34 34 readonly attribute unsigned long length; 35 35 36 [TreatReturnedNullStringAs=Null] getter DOMStringitem([Default=Undefined] optional unsigned long index);36 getter DOMString? item([Default=Undefined] optional unsigned long index); 37 37 [RaisesException] void deleteMedium([Default=Undefined] optional DOMString oldMedium); 38 38 [RaisesException] void appendMedium([Default=Undefined] optional DOMString newMedium); -
trunk/Source/WebCore/css/StyleSheet.idl
r163389 r197060 27 27 ObjCPolymorphic, 28 28 ] interface StyleSheet { 29 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringtype;29 readonly attribute DOMString? type; 30 30 attribute boolean disabled; 31 31 readonly attribute Node ownerNode; 32 32 readonly attribute StyleSheet parentStyleSheet; 33 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringhref;34 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringtitle;33 readonly attribute DOMString? href; 34 readonly attribute DOMString? title; 35 35 readonly attribute MediaList media; 36 36 }; -
trunk/Source/WebCore/dom/Attr.idl
r189881 r197060 27 27 // DOM Level 1 28 28 29 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringname;29 readonly attribute DOMString? name; 30 30 31 31 readonly attribute boolean specified; 32 32 33 [ TreatReturnedNullStringAs=Null, TreatNullAs=NullString, SetterRaisesException] attribute DOMStringvalue;33 [SetterRaisesException] attribute DOMString? value; 34 34 35 35 // DOM Level 2 -
trunk/Source/WebCore/dom/CharacterData.idl
r195264 r197060 24 24 readonly attribute unsigned long length; 25 25 26 [ TreatReturnedNullStringAs=Null, ObjCLegacyUnnamedParameters, RaisesException] DOMStringsubstringData(unsigned long offset, unsigned long length);26 [ObjCLegacyUnnamedParameters, RaisesException] DOMString? substringData(unsigned long offset, unsigned long length); 27 27 28 28 void appendData(DOMString data); -
trunk/Source/WebCore/dom/DOMStringList.idl
r171824 r197060 29 29 ] interface DOMStringList { 30 30 readonly attribute unsigned long length; 31 [TreatReturnedNullStringAs=Null] getter DOMStringitem([Default=Undefined] optional unsigned long index);31 getter DOMString? item([Default=Undefined] optional unsigned long index); 32 32 boolean contains([Default=Undefined] optional DOMString string); 33 33 }; -
trunk/Source/WebCore/dom/Document.idl
r196954 r197060 70 70 [ImplementedAs=characterSetWithUTF8Fallback] readonly attribute DOMString inputEncoding; 71 71 72 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringxmlEncoding;73 [ TreatReturnedNullStringAs=Null, TreatNullAs=NullString, SetterRaisesException] attribute DOMStringxmlVersion;72 readonly attribute DOMString? xmlEncoding; 73 [SetterRaisesException] attribute DOMString? xmlVersion; 74 74 [SetterRaisesException] attribute boolean xmlStandalone; 75 75 … … 81 81 // the writable version around for Objective C clients, but are moving to 82 82 // read-only for other clients. 83 [TreatReturnedNullStringAs=Null, TreatNullAs=NullString] attribute DOMStringdocumentURI;83 attribute DOMString? documentURI; 84 84 #else 85 85 [ImplementedAs=urlForBindings] readonly attribute DOMString documentURI; … … 209 209 // WebKit extensions 210 210 211 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringpreferredStylesheetSet;212 [TreatReturnedNullStringAs=Null, TreatNullAs=NullString] attribute DOMStringselectedStylesheetSet;211 readonly attribute DOMString? preferredStylesheetSet; 212 attribute DOMString? selectedStylesheetSet; 213 213 214 214 #if !defined(LANGUAGE_JAVASCRIPT) || !LANGUAGE_JAVASCRIPT -
trunk/Source/WebCore/dom/DocumentType.idl
r195336 r197060 36 36 readonly attribute DOMString publicId; 37 37 readonly attribute DOMString systemId; 38 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringinternalSubset;38 readonly attribute DOMString? internalSubset; 39 39 }; 40 40 -
trunk/Source/WebCore/dom/Element.idl
r196430 r197060 26 26 // DOM Level 1 Core 27 27 28 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringtagName;29 30 [TreatReturnedNullStringAs=Null] DOMStringgetAttribute([Default=Undefined] optional DOMString name);28 readonly attribute DOMString? tagName; 29 30 DOMString? getAttribute([Default=Undefined] optional DOMString name); 31 31 [ObjCLegacyUnnamedParameters, RaisesException] void setAttribute([Default=Undefined] optional DOMString name, 32 32 [Default=Undefined] optional DOMString value); … … 50 50 // DOM Level 2 Core 51 51 52 [ObjCLegacyUnnamedParameters , TreatReturnedNullStringAs=Null] DOMStringgetAttributeNS([TreatNullAs=NullString, TreatUndefinedAs=NullString, Default=Undefined] optional DOMString namespaceURI,52 [ObjCLegacyUnnamedParameters] DOMString? getAttributeNS([TreatNullAs=NullString, TreatUndefinedAs=NullString, Default=Undefined] optional DOMString namespaceURI, 53 53 [Default=Undefined] optional DOMString localName); 54 54 [ObjCLegacyUnnamedParameters, RaisesException] void setAttributeNS([TreatNullAs=NullString, TreatUndefinedAs=NullString, Default=Undefined] optional DOMString namespaceURI, -
trunk/Source/WebCore/dom/Entity.idl
r189971 r197060 24 24 ImplementationLacksVTable 25 25 ] interface Entity : Node { 26 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringpublicId;27 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringsystemId;28 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringnotationName;26 readonly attribute DOMString? publicId; 27 readonly attribute DOMString? systemId; 28 readonly attribute DOMString? notationName; 29 29 }; 30 30 -
trunk/Source/WebCore/dom/MutationRecord.idl
r148257 r197060 40 40 readonly attribute Node nextSibling; 41 41 42 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringattributeName;43 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringattributeNamespace;42 readonly attribute DOMString? attributeName; 43 readonly attribute DOMString? attributeNamespace; 44 44 45 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringoldValue;45 readonly attribute DOMString? oldValue; 46 46 }; -
trunk/Source/WebCore/dom/Node.idl
r196998 r197060 47 47 const unsigned short NOTATION_NODE = 12; 48 48 49 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringnodeName;49 readonly attribute DOMString? nodeName; 50 50 51 51 // FIXME: the spec says this can also raise on retrieval. 52 [ TreatReturnedNullStringAs=Null, TreatNullAs=NullString, SetterRaisesException] attribute DOMStringnodeValue;52 [SetterRaisesException] attribute DOMString? nodeValue; 53 53 54 54 readonly attribute unsigned short nodeType; … … 81 81 #endif 82 82 83 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringnamespaceURI;84 [ TreatReturnedNullStringAs=Null, TreatNullAs=NullString, SetterRaisesException] attribute DOMStringprefix;85 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringlocalName;83 readonly attribute DOMString? namespaceURI; 84 [SetterRaisesException] attribute DOMString? prefix; 85 readonly attribute DOMString? localName; 86 86 87 87 #if defined(LANGUAGE_OBJECTIVE_C) … … 93 93 // Introduced in DOM Level 3: 94 94 95 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringbaseURI;95 readonly attribute DOMString? baseURI; 96 96 97 97 // FIXME: the spec says this can also raise on retrieval. 98 [ TreatReturnedNullStringAs=Null, TreatNullAs=NullString, TreatUndefinedAs=NullString, SetterRaisesException] attribute DOMStringtextContent;98 [SetterRaisesException] attribute DOMString? textContent; 99 99 100 100 boolean isSameNode([Default=Undefined] optional Node other); 101 101 boolean isEqualNode([Default=Undefined] optional Node other); 102 [TreatReturnedNullStringAs=Null] DOMStringlookupPrefix([TreatNullAs=NullString,Default=Undefined] optional DOMString namespaceURI);102 DOMString? lookupPrefix([TreatNullAs=NullString,Default=Undefined] optional DOMString namespaceURI); 103 103 boolean isDefaultNamespace([TreatNullAs=NullString,Default=Undefined] optional DOMString namespaceURI); 104 [TreatReturnedNullStringAs=Null] DOMStringlookupNamespaceURI([TreatNullAs=NullString,Default=Undefined] optional DOMString prefix);104 DOMString? lookupNamespaceURI([TreatNullAs=NullString,Default=Undefined] optional DOMString prefix); 105 105 106 106 // DocumentPosition -
trunk/Source/WebCore/dom/ProcessingInstruction.idl
r189881 r197060 26 26 // DOM Level 1 27 27 28 [TreatReturnedNullStringAs=Null] readonly attribute DOMStringtarget;28 readonly attribute DOMString? target; 29 29 30 30 // interface LinkStyle from DOM Level 2 Style Sheets -
trunk/Source/WebCore/html/DOMSettableTokenList.idl
r196136 r197060 32 32 attribute DOMString value; 33 33 34 [TreatReturnedNullStringAs=Null] getter DOMString(unsigned long index);34 getter DOMString? (unsigned long index); 35 35 }; 36 36 -
trunk/Source/WebCore/html/DOMTokenList.idl
r196123 r197060 29 29 ] interface DOMTokenList { 30 30 readonly attribute unsigned long length; 31 [TreatReturnedNullStringAs=Null] getter DOMStringitem(unsigned long index);31 getter DOMString? item(unsigned long index); 32 32 [RaisesException] boolean contains(DOMString token); 33 33 [RaisesException] void add(DOMString... tokens); -
trunk/Source/WebCore/html/DOMURL.idl
r171824 r197060 36 36 ImplementationLacksVTable, 37 37 ] interface DOMURL { 38 [CallWith=ScriptExecutionContext ,TreatReturnedNullStringAs=Null] static DOMStringcreateObjectURL(Blob? blob);38 [CallWith=ScriptExecutionContext] static DOMString? createObjectURL(Blob? blob); 39 39 [CallWith=ScriptExecutionContext] static void revokeObjectURL(DOMString url); 40 40 }; -
trunk/Source/WebCore/html/canvas/WebGLDebugShaders.idl
r159061 r197060 29 29 GenerateIsReachable=ImplWebGLRenderingContext, 30 30 ] interface WebGLDebugShaders { 31 [StrictTypeChecking, TreatReturnedNullStringAs=Null, RaisesException] DOMStringgetTranslatedShaderSource(WebGLShader shader);31 [StrictTypeChecking, RaisesException] DOMString? getTranslatedShaderSource(WebGLShader shader); 32 32 }; -
trunk/Source/WebCore/html/canvas/WebGLRenderingContextBase.idl
r179482 r197060 555 555 [StrictTypeChecking, Custom, RaisesException] any getParameter(GLenum pname); 556 556 [StrictTypeChecking, Custom, RaisesException] any getProgramParameter(WebGLProgram program, GLenum pname); 557 [StrictTypeChecking, TreatReturnedNullStringAs=Null, RaisesException] DOMStringgetProgramInfoLog(WebGLProgram program);557 [StrictTypeChecking, RaisesException] DOMString? getProgramInfoLog(WebGLProgram program); 558 558 [StrictTypeChecking, Custom, RaisesException] any getRenderbufferParameter(GLenum target, GLenum pname); 559 559 [StrictTypeChecking, Custom, RaisesException] any getShaderParameter(WebGLShader shader, GLenum pname); 560 560 561 [StrictTypeChecking, TreatReturnedNullStringAs=Null, RaisesException] DOMStringgetShaderInfoLog(WebGLShader shader);561 [StrictTypeChecking, RaisesException] DOMString? getShaderInfoLog(WebGLShader shader); 562 562 563 563 [StrictTypeChecking, RaisesException] WebGLShaderPrecisionFormat getShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype); 564 564 565 [StrictTypeChecking, TreatReturnedNullStringAs=Null, RaisesException] DOMStringgetShaderSource(WebGLShader shader);565 [StrictTypeChecking, RaisesException] DOMString? getShaderSource(WebGLShader shader); 566 566 567 567 [StrictTypeChecking, Custom] sequence<DOMString> getSupportedExtensions(); -
trunk/Source/WebCore/page/DOMWindow.idl
r196797 r197060 75 75 void alert([Default=Undefined] optional DOMString message); 76 76 boolean confirm([Default=Undefined] optional DOMString message); 77 [TreatReturnedNullStringAs=Null] DOMStringprompt([Default=Undefined] optional DOMString message,77 DOMString? prompt([Default=Undefined] optional DOMString message, 78 78 [TreatNullAs=NullString, TreatUndefinedAs=NullString,Default=Undefined] optional DOMString defaultValue); 79 79 -
trunk/Source/WebCore/storage/Storage.idl
r195760 r197060 32 32 ] interface Storage { 33 33 [GetterRaisesException] readonly attribute unsigned long length; 34 [ TreatReturnedNullStringAs=Null, RaisesException] DOMStringkey(unsigned long index);35 [ TreatReturnedNullStringAs=Null, RaisesException] getter DOMStringgetItem(DOMString key);34 [RaisesException] DOMString? key(unsigned long index); 35 [RaisesException] getter DOMString? getItem(DOMString key); 36 36 [RaisesException] void setItem(DOMString key, DOMString data); 37 37 [RaisesException] void removeItem(DOMString key); -
trunk/Source/WebCore/storage/StorageEvent.idl
r159061 r197060 28 28 ] interface StorageEvent : Event { 29 29 [InitializedByEventConstructor] readonly attribute DOMString key; 30 [InitializedByEventConstructor , TreatReturnedNullStringAs=Null] readonly attribute DOMStringoldValue;31 [InitializedByEventConstructor , TreatReturnedNullStringAs=Null] readonly attribute DOMStringnewValue;30 [InitializedByEventConstructor] readonly attribute DOMString? oldValue; 31 [InitializedByEventConstructor] readonly attribute DOMString? newValue; 32 32 [InitializedByEventConstructor] readonly attribute DOMString url; 33 33 [InitializedByEventConstructor] readonly attribute Storage storageArea; -
trunk/Source/WebCore/xml/XMLHttpRequest.idl
r196599 r197060 71 71 // response 72 72 [TreatReturnedNullStringAs=Undefined] DOMString getAllResponseHeaders(); 73 [TreatReturnedNullStringAs=Null] DOMStringgetResponseHeader(DOMString header);74 [GetterRaisesException, CustomGetter] readonly attribute DOMString responseText; // The custom getter implements TreatReturnedNullStringAs=Null73 DOMString? getResponseHeader(DOMString header); 74 [GetterRaisesException, CustomGetter] readonly attribute DOMString? responseText; 75 75 [GetterRaisesException] readonly attribute Document responseXML; 76 76 -
trunk/Source/WebCore/xml/XPathNSResolver.idl
r165676 r197060 24 24 SkipVTableValidation, 25 25 ] interface XPathNSResolver { 26 [TreatReturnedNullStringAs=Null] DOMStringlookupNamespaceURI([Default=Undefined] optional DOMString prefix);26 DOMString? lookupNamespaceURI([Default=Undefined] optional DOMString prefix); 27 27 }; 28 28
Note:
See TracChangeset
for help on using the changeset viewer.