Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(170)

Unified Diff: Source/bindings/scripts/code_generator_v8.pm

Issue 28863007: IDL compiler: mostly merge Non-wrapper types and RefPtr conversion exceptions (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Incremental, no web-exposed changes Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/scripts/code_generator_v8.pm
diff --git a/Source/bindings/scripts/code_generator_v8.pm b/Source/bindings/scripts/code_generator_v8.pm
index 8d63d0b946603ac7004090d8a26b81b0805ffd17..c1de01b7e2c06a3827b598954980d006f2947bcd 100644
--- a/Source/bindings/scripts/code_generator_v8.pm
+++ b/Source/bindings/scripts/code_generator_v8.pm
@@ -5229,12 +5229,6 @@ sub GetNativeType
return "ScriptValue" if $type eq "any" or IsCallbackFunctionType($type);
return "Dictionary" if $type eq "Dictionary";
- return "RefPtr<DOMStringList>" if $type eq "DOMStringList";
- return "RefPtr<MediaQueryListListener>" if $type eq "MediaQueryListListener";
- return "RefPtr<NodeFilter>" if $type eq "NodeFilter";
- return "RefPtr<SerializedScriptValue>" if $type eq "SerializedScriptValue";
- return "RefPtr<XPathNSResolver>" if $type eq "XPathNSResolver";
-
die "UnionType is not supported" if IsUnionType($type);
if (IsTypedArrayType($type)) {
@@ -5242,12 +5236,13 @@ sub GetNativeType
}
# We need to check [ImplementedAs] extended attribute for wrapper types.
+ return "RefPtr<$type>" if $type eq "DOMStringList" or $type eq "XPathNSResolver"; # FIXME: can these be put in nonWrapperTypes instead?
if (IsWrapperType($type)) {
my $interface = ParseInterface($type);
my $implClassName = GetImplName($interface);
return $isParameter ? "${implClassName}*" : "RefPtr<${implClassName}>";
}
- return "RefPtr<${type}>" if IsRefPtrType($type) and not $isParameter;
+ return "RefPtr<$type>" if IsRefPtrType($type) and (not $isParameter or $nonWrapperTypes{$type});
my $arrayOrSequenceType = GetArrayOrSequenceType($type);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698