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

Side by Side Diff: frog/leg/ssa/builder.dart

Issue 9169008: Do not resolve the selector to find the getter, but the receiver instead. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 8 years, 11 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 class Interceptors { 5 class Interceptors {
6 Compiler compiler; 6 Compiler compiler;
7 Interceptors(Compiler this.compiler); 7 Interceptors(Compiler this.compiler);
8 8
9 SourceString mapOperatorToMethodName(Operator op) { 9 SourceString mapOperatorToMethodName(Operator op) {
10 String name = op.source.stringValue; 10 String name = op.source.stringValue;
(...skipping 790 matching lines...) Expand 10 before | Expand all | Expand 10 after
801 add(target); 801 add(target);
802 List<HInstruction> inputs = <HInstruction>[target, receiver]; 802 List<HInstruction> inputs = <HInstruction>[target, receiver];
803 push(new HInvokeInterceptor(getterName.stringValue, true, inputs)); 803 push(new HInvokeInterceptor(getterName.stringValue, true, inputs));
804 } else { 804 } else {
805 String jsGetterName = compiler.namer.getterName(getterName); 805 String jsGetterName = compiler.namer.getterName(getterName);
806 push(new HInvokeDynamicGetter(null, jsGetterName, receiver)); 806 push(new HInvokeDynamicGetter(null, jsGetterName, receiver));
807 } 807 }
808 } else { 808 } else {
809 HInstruction instruction = definitions[element]; 809 HInstruction instruction = definitions[element];
810 if (instruction === null) { 810 if (instruction === null) {
811 compiler.unimplemented("SsaBuilder.visitSend with static"); 811 compiler.unimplemented("SsaBuilder.visitSend with static", node: send);
812 } 812 }
813 assert(instruction !== null); 813 assert(instruction !== null);
814 stack.add(instruction); 814 stack.add(instruction);
815 } 815 }
816 } 816 }
817 817
818 void generateSetter(SendSet send, Element element, HInstruction value) { 818 void generateSetter(SendSet send, Element element, HInstruction value) {
819 if (Elements.isStaticOrTopLevelField(element)) { 819 if (Elements.isStaticOrTopLevelField(element)) {
820 add(new HStaticStore(element, value)); 820 add(new HStaticStore(element, value));
821 stack.add(value); 821 stack.add(value);
(...skipping 459 matching lines...) Expand 10 before | Expand all | Expand 10 after
1281 } 1281 }
1282 1282
1283 visitCatchBlock(CatchBlock node) { 1283 visitCatchBlock(CatchBlock node) {
1284 compiler.unimplemented('SsaBuilder.visitCatchBlock', node: node); 1284 compiler.unimplemented('SsaBuilder.visitCatchBlock', node: node);
1285 } 1285 }
1286 1286
1287 visitTypedef(Typedef node) { 1287 visitTypedef(Typedef node) {
1288 compiler.unimplemented('SsaBuilder.visitTypedef', node: node); 1288 compiler.unimplemented('SsaBuilder.visitTypedef', node: node);
1289 } 1289 }
1290 } 1290 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698