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

Unified Diff: lib/src/compiler/code_generator.dart

Issue 1919173004: Use static dispatch for dynamic on Object methods (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 4 years, 8 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 | test/codegen/expect/language-all.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/src/compiler/code_generator.dart
diff --git a/lib/src/compiler/code_generator.dart b/lib/src/compiler/code_generator.dart
index 43de895f24bd03427106230beb2078f5d600b6e6..77820f188a561cbeefa8563f4c21a9e66c185cf9 100644
--- a/lib/src/compiler/code_generator.dart
+++ b/lib/src/compiler/code_generator.dart
@@ -3130,7 +3130,7 @@ class CodeGenerator extends GeneralizingAstVisitor
}
bool _requiresStaticDispatch(Expression target, String memberName) {
- var type = getStaticType(target);
+ var type = target.propagatedType ?? getStaticType(target);
Harry Terkelsen 2016/04/26 20:51:55 btw, this is the only use of propagatedType in ddc
Jennifer Messerly 2016/04/26 21:04:56 yeah we never to use it. It's the old Analyzer inf
if (!isObjectProperty(memberName)) {
return false;
}
« no previous file with comments | « no previous file | test/codegen/expect/language-all.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698