Changeset 204033 in webkit
- Timestamp:
- Aug 2, 2016 12:11:27 PM (8 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r204032 r204033 1 2016-08-02 Chris Dumez <cdumez@apple.com> 2 3 Kill [StrictTypeChecking] IDL extended attribute 4 https://bugs.webkit.org/show_bug.cgi?id=160382 5 6 Reviewed by Darin Adler. 7 8 Kill [StrictTypeChecking] IDL extended attribute. Its only remaining 9 use was on DOMString parameters for a few CanvasRenderingContext2D 10 operations in order to work around a bug in our overload resolution. 11 12 However, as of r204028, we implement the Web IDL overload resolution 13 algorithm and [StrictTypeChecking] is now a no-op and is no longer 14 needed. 15 16 * bindings/scripts/CodeGeneratorJS.pm: 17 (GenerateParametersCheckExpression): 18 * bindings/scripts/IDLAttributes.txt: 19 * bindings/scripts/test/TestObj.idl: 20 * bindings/scripts/test/TestTypedefs.idl: 21 * html/canvas/CanvasRenderingContext2D.idl: 22 1 23 2016-08-02 Frederic Wang <fwang@igalia.com> 2 24 -
trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
r204028 r204033 1957 1957 my $type = $parameter->type; 1958 1958 1959 # For DOMString with StrictTypeChecking only Null, Undefined and Object 1960 # are accepted for compatibility. Otherwise, no restrictions are made to 1961 # match the non-overloaded behavior. 1962 # FIXME: Implement WebIDL overload resolution algorithm. 1963 if ($type eq "DOMString" || $codeGenerator->IsEnumType($type)) { 1964 if ($parameter->extendedAttributes->{"StrictTypeChecking"}) { 1965 push(@andExpression, "(${value}.isUndefinedOrNull() || ${value}.isString() || ${value}.isObject())"); 1966 $usedArguments{$parameterIndex} = 1; 1967 } 1968 } elsif ($codeGenerator->IsCallbackInterface($parameter->type)) { 1959 if ($codeGenerator->IsCallbackInterface($parameter->type)) { 1969 1960 # For Callbacks only checks if the value is null or object. 1970 1961 if ($codeGenerator->IsFunctionOnlyCallbackInterface($parameter->type)) { -
trunk/Source/WebCore/bindings/scripts/IDLAttributes.txt
r203463 r204033 121 121 SetterCallWith=ScriptExecutionContext|ScriptState|ScriptArguments|CallStack|ActiveWindow|FirstWindow 122 122 SkipVTableValidation 123 StrictTypeChecking124 123 SuppressToJSObject 125 124 TreatNullAs=EmptyString -
trunk/Source/WebCore/bindings/scripts/test/TestObj.idl
r204028 r204033 252 252 #if defined(TESTING_JS) 253 253 // Overloads 254 void overloadedMethod(TestObj? objArg, [StrictTypeChecking]DOMString strArg);254 void overloadedMethod(TestObj? objArg, DOMString strArg); 255 255 void overloadedMethod(TestObj? objArg, optional long longArg); 256 void overloadedMethod( [StrictTypeChecking]DOMString strArg);256 void overloadedMethod(DOMString strArg); 257 257 void overloadedMethod(long longArg); 258 258 void overloadedMethod(TestCallback callback); -
trunk/Source/WebCore/bindings/scripts/test/TestTypedefs.idl
r203956 r204033 43 43 void func(optional ARRAY_OF_LONGS x = []); 44 44 45 void setShadow(DOUBLE width, DOUBLE height, unrestricted float blur, [StrictTypeChecking]optional STRING color, optional DOUBLE alpha);45 void setShadow(DOUBLE width, DOUBLE height, unrestricted float blur, optional STRING color, optional DOUBLE alpha); 46 46 47 47 ULONGLONG methodWithSequenceArg(sequence<SCRIPT_VALUE> sequenceArg); -
trunk/Source/WebCore/html/canvas/CanvasRenderingContext2D.idl
r203510 r204033 127 127 void strokeText(DOMString text, unrestricted float x, unrestricted float y, optional unrestricted float maxWidth); 128 128 129 void setStrokeColor( [StrictTypeChecking]DOMString color, optional unrestricted float alpha);129 void setStrokeColor(DOMString color, optional unrestricted float alpha); 130 130 void setStrokeColor(unrestricted float grayLevel, optional float alpha = 1); 131 131 void setStrokeColor(unrestricted float r, unrestricted float g, unrestricted float b, unrestricted float a); 132 132 void setStrokeColor(unrestricted float c, unrestricted float m, unrestricted float y, unrestricted float k, unrestricted float a); 133 133 134 void setFillColor( [StrictTypeChecking]DOMString color, optional unrestricted float alpha);134 void setFillColor(DOMString color, optional unrestricted float alpha); 135 135 void setFillColor(unrestricted float grayLevel, optional unrestricted float alpha = 1); 136 136 void setFillColor(unrestricted float r, unrestricted float g, unrestricted float b, unrestricted float a); … … 161 161 162 162 void setShadow(unrestricted float width, unrestricted float height, unrestricted float blur, 163 [StrictTypeChecking]optional DOMString color, optional unrestricted float alpha);163 optional DOMString color, optional unrestricted float alpha); 164 164 void setShadow(unrestricted float width, unrestricted float height, unrestricted float blur, unrestricted float grayLevel, 165 165 optional unrestricted float alpha = 1);
Note: See TracChangeset
for help on using the changeset viewer.