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

Unified Diff: lib/compiler/implementation/ssa/codegen.dart

Issue 11264005: InvocationMirror implemented in dart2js. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Working version Created 8 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
Index: lib/compiler/implementation/ssa/codegen.dart
diff --git a/lib/compiler/implementation/ssa/codegen.dart b/lib/compiler/implementation/ssa/codegen.dart
index d8cda34819f032deac654b695f644fdd9f52c831..3e74229b68d0037809892794f9136ad01e8917be 100644
--- a/lib/compiler/implementation/ssa/codegen.dart
+++ b/lib/compiler/implementation/ssa/codegen.dart
@@ -1513,6 +1513,12 @@ abstract class SsaCodeGenerator implements HVisitor, HBlockInformationVisitor {
Selector defaultSelector) {
// TODO(4434): For private members we need to use the untyped selector.
if (defaultSelector.name.isPrivate()) return defaultSelector;
+ // If [InvocationMirror.invokeOn] is called we must not create a typed
+ // selector based on the receiver type.
+ if (backend.compiler.enabledNoSuchMethod &&
+ backend.compiler.enabledInvokeOn) {
+ return defaultSelector;
+ }
HType receiverHType = types[node.inputs[0]];
DartType receiverType = receiverHType.computeType(compiler);
if (receiverType != null) {

Powered by Google App Engine
This is Rietveld 408576698