Changeset 122608 in webkit
- Timestamp:
- Jul 13, 2012 11:15:52 AM (12 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r122604 r122608 1 2012-07-13 Kentaro Hara <haraken@chromium.org> 2 3 [CallWith=XXX] arguments should be placed at the head of method arguments 4 https://bugs.webkit.org/show_bug.cgi?id=91217 5 6 Reviewed by Adam Barth. 7 8 The EFL build with the ENABLE_FILE_SYSTEM flag caused a build error, 9 because CodeGeneratorJS.pm assumes webkitEntries(ScriptExecutionContext*, HTMLInputElement*) 10 but the actual signature is webkitEntries(HTMLInputElement*, ScriptExecutionContext*) (bug 91185). 11 12 Per https://trac.webkit.org/wiki/WebKitIDL#CallWith, [CallWith=XXX] arguments should be placed 13 at the head of the arguments. (i.e. the behavior of CodeGeneratorJS.pm is correct.) 14 15 Thus the correct fix is (1) to change the signature of webkitEntries() and webkitGetAsEntry() 16 so that ScriptExecutionContext* comes first and (2) to modify CodeGeneratorV8.pm to support the order. 17 18 Test: bindings/scripts/test/TestObj.idl 19 20 * Modules/filesystem/DataTransferItemFileSystem.h: Placed ScriptExecutionContext* at the head of arguments. 21 (DataTransferItemFileSystem): 22 * Modules/filesystem/HTMLInputElementFileSystem.cpp: Ditto. 23 (WebCore::HTMLInputElementFileSystem::webkitEntries): 24 * Modules/filesystem/HTMLInputElementFileSystem.h: Ditto. 25 (HTMLInputElementFileSystem): 26 * Modules/filesystem/chromium/DataTransferItemFileSystemChromium.cpp: Ditto. 27 (WebCore::DataTransferItemFileSystem::webkitGetAsEntry): 28 29 * bindings/scripts/CodeGeneratorV8.pm: Modified to support the correct order. 30 (GenerateNormalAttrGetter): 31 (GenerateNormalAttrSetter): 32 (GenerateFunctionCallString): 33 34 * bindings/scripts/test/V8/V8TestInterface.cpp: Updated run-bindings-tests results. 35 (WebCore::TestInterfaceV8Internal::supplementalMethod2Callback): 36 1 37 2012-07-13 Mary Wu <mary.wu@torchmobile.com.cn> 2 38 -
trunk/Source/WebCore/Modules/filesystem/DataTransferItemFileSystem.h
r119371 r122608 44 44 class DataTransferItemFileSystem { 45 45 public: 46 static PassRefPtr<Entry> webkitGetAsEntry( DataTransferItem*, ScriptExecutionContext*);46 static PassRefPtr<Entry> webkitGetAsEntry(ScriptExecutionContext*, DataTransferItem*); 47 47 48 48 private: -
trunk/Source/WebCore/Modules/filesystem/HTMLInputElementFileSystem.cpp
r120667 r122608 47 47 48 48 // static 49 PassRefPtr<EntryArray> HTMLInputElementFileSystem::webkitEntries( HTMLInputElement* input, ScriptExecutionContext* scriptExecutionContext)49 PassRefPtr<EntryArray> HTMLInputElementFileSystem::webkitEntries(ScriptExecutionContext* scriptExecutionContext, HTMLInputElement* input) 50 50 { 51 51 RefPtr<EntryArray> array = EntryArray::create(); -
trunk/Source/WebCore/Modules/filesystem/HTMLInputElementFileSystem.h
r120667 r122608 42 42 class HTMLInputElementFileSystem { 43 43 public: 44 static PassRefPtr<EntryArray> webkitEntries( HTMLInputElement*, ScriptExecutionContext*);44 static PassRefPtr<EntryArray> webkitEntries(ScriptExecutionContext*, HTMLInputElement*); 45 45 46 46 private: -
trunk/Source/WebCore/Modules/filesystem/chromium/DataTransferItemFileSystemChromium.cpp
r119371 r122608 52 52 53 53 // static 54 PassRefPtr<Entry> DataTransferItemFileSystem::webkitGetAsEntry( DataTransferItem* item, ScriptExecutionContext* scriptExecutionContext)54 PassRefPtr<Entry> DataTransferItemFileSystem::webkitGetAsEntry(ScriptExecutionContext* scriptExecutionContext, DataTransferItem* item) 55 55 { 56 56 DataTransferItemPolicyWrapper* itemPolicyWrapper = static_cast<DataTransferItemPolicyWrapper*>(item); -
trunk/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm
r122535 r122608 923 923 if ($getterStringUsesImp) { 924 924 my ($functionName, @arguments) = $codeGenerator->GetterExpression(\%implIncludes, $interfaceName, $attribute); 925 926 push(@arguments, GenerateCallWith($attribute->signature->extendedAttributes->{"CallWith"}, \@implContentDecls, " ", 0, 0));927 928 925 push(@arguments, "ec") if $useExceptions; 929 926 if ($attribute->signature->extendedAttributes->{"ImplementedBy"}) { … … 935 932 $functionName = "imp->${functionName}"; 936 933 } 934 unshift(@arguments, GenerateCallWith($attribute->signature->extendedAttributes->{"CallWith"}, \@implContentDecls, " ", 0, 0)); 937 935 $getterString = "${functionName}(" . join(", ", @arguments) . ")"; 938 936 } else { … … 1216 1214 } else { 1217 1215 my ($functionName, @arguments) = $codeGenerator->SetterExpression(\%implIncludes, $interfaceName, $attribute); 1218 1219 push(@arguments, GenerateCallWith($attribute->signature->extendedAttributes->{"CallWith"}, \@implContentDecls, " ", 1, 0));1220 1221 1216 push(@arguments, $result); 1222 1217 push(@arguments, "ec") if $useExceptions; … … 1229 1224 $functionName = "imp->${functionName}"; 1230 1225 } 1226 unshift(@arguments, GenerateCallWith($attribute->signature->extendedAttributes->{"CallWith"}, \@implContentDecls, " ", 1, 0)); 1231 1227 push(@implContentDecls, " ${functionName}(" . join(", ", @arguments) . ");\n"); 1232 1228 } … … 3375 3371 my @callWithArgs = GenerateCallWith($callWith, \@callWithOutput, $indent, 0, 1, $function); 3376 3372 $result .= join("", @callWithOutput); 3377 push(@arguments, @callWithArgs);3373 unshift(@arguments, @callWithArgs); 3378 3374 $index += @callWithArgs; 3379 3375 $numberOfParameters += @callWithArgs; -
trunk/Source/WebCore/bindings/scripts/test/V8/V8TestInterface.cpp
r120968 r122608 135 135 if (!scriptContext) 136 136 return v8::Undefined(); 137 RefPtr<TestObj> result = TestSupplemental::supplementalMethod2( imp, scriptContext, strArg, objArg, ec);137 RefPtr<TestObj> result = TestSupplemental::supplementalMethod2(scriptContext, imp, strArg, objArg, ec); 138 138 if (UNLIKELY(ec)) 139 139 goto fail;
Note: See TracChangeset
for help on using the changeset viewer.