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

Unified Diff: Source/bindings/dart/DartUtilities.cpp

Issue 26571005: Enforcing that custom tag extensions have correct super classes. (Closed) Base URL: svn://svn.chromium.org/multivm/trunk/webkit
Patch Set: 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 | « Source/bindings/dart/DartUtilities.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/dart/DartUtilities.cpp
diff --git a/Source/bindings/dart/DartUtilities.cpp b/Source/bindings/dart/DartUtilities.cpp
index 99508573306e3ed8719d254eee05ae6a70c5c86c..ad93749483e9e77df6f136b86b12423ca8462874 100644
--- a/Source/bindings/dart/DartUtilities.cpp
+++ b/Source/bindings/dart/DartUtilities.cpp
@@ -403,6 +403,21 @@ bool DartUtilities::isTypeSubclassOf(Dart_Handle type, intptr_t libraryId, const
return boolResult;
}
+bool DartUtilities::isTypeSubclassOfTag(Dart_Handle type, const String& tagName)
+{
+ Dart_Handle args[2] = { type, stringToDartString(tagName) };
+ Dart_Handle result = DartUtilities::invokeUtilsMethod("isTypeSubclassOfTag", 2, args);
+ ASSERT(!Dart_IsError(result));
+ if (Dart_IsError(result))
vsm 2013/10/14 18:25:33 Move ASSERT into the if as ASSERT_NOT_REACHED?
blois 2013/10/14 19:24:13 Done.
+ return false;
+
+ Dart_Handle exception = 0;
+ bool boolResult = dartToBool(result, exception);
+ if (exception)
+ return false;
+ return boolResult;
+}
+
bool DartUtilities::isTypedData(Dart_Handle handle)
{
return (Dart_GetTypeOfTypedData(handle) != Dart_TypedData_kInvalid)
« no previous file with comments | « Source/bindings/dart/DartUtilities.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698