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

Unified Diff: runtime/vm/resolver.cc

Issue 24631003: Add proper API for creating private symbols wrt a library. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: maintain dart2js coverage 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 | « runtime/vm/resolver.h ('k') | sdk/lib/_internal/lib/mirrors_patch.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/resolver.cc
diff --git a/runtime/vm/resolver.cc b/runtime/vm/resolver.cc
index 17028e1fc21f8ff4e8388322821db24dc2941e54..1b43064f5cca7a9fd511fd59266d98b3e19cb1d8 100644
--- a/runtime/vm/resolver.cc
+++ b/runtime/vm/resolver.cc
@@ -140,47 +140,6 @@ RawFunction* Resolver::ResolveDynamicAnyArgs(
}
-// TODO(13355): Remove.
-RawFunction* Resolver::ResolveDynamicAnyArgsAllowPrivate(
- const Class& receiver_class,
- const String& function_name) {
- Class& cls = Class::Handle(receiver_class.raw());
- if (FLAG_trace_resolving) {
- OS::Print("ResolveDynamic '%s' for class %s\n",
- function_name.ToCString(),
- String::Handle(cls.Name()).ToCString());
- }
-
- const bool is_getter = Field::IsGetterName(function_name);
- String& field_name = String::Handle();
- if (is_getter) {
- field_name ^= Field::NameFromGetter(function_name);
- }
-
- // Now look for an instance function whose name matches function_name
- // in the class.
- Function& function = Function::Handle();
- while (!cls.IsNull()) {
- function ^= cls.LookupDynamicFunctionAllowPrivate(function_name);
- if (!function.IsNull()) {
- return function.raw();
- }
- // Getter invocation might actually be a method extraction.
- if (is_getter && function.IsNull()) {
- function ^= cls.LookupDynamicFunction(field_name);
- if (!function.IsNull()) {
- // We were looking for the getter but found a method with the same name.
- // Create a method extractor and return it.
- function ^= CreateMethodExtractor(function_name, function);
- return function.raw();
- }
- }
- cls = cls.SuperClass();
- }
- return function.raw();
-}
-
-
RawFunction* Resolver::ResolveStatic(const Library& library,
const String& class_name,
const String& function_name,
« no previous file with comments | « runtime/vm/resolver.h ('k') | sdk/lib/_internal/lib/mirrors_patch.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698