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

Side by Side Diff: pkg/compiler/lib/src/dart_backend/backend.dart

Issue 1278353003: Handle more unqualified SendSets (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years, 4 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
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 part of dart_backend; 5 part of dart_backend;
6 6
7 // TODO(ahe): This class is simply wrong. This backend should use 7 // TODO(ahe): This class is simply wrong. This backend should use
8 // elements when it can, not AST nodes. Perhaps a [Map<Element, 8 // elements when it can, not AST nodes. Perhaps a [Map<Element,
9 // TreeElements>] is what is needed. 9 // TreeElements>] is what is needed.
10 class ElementAst { 10 class ElementAst {
(...skipping 464 matching lines...) Expand 10 before | Expand all | Expand 10 after
475 return getConstantValue(metadata.constant); 475 return getConstantValue(metadata.constant);
476 } 476 }
477 477
478 @override 478 @override
479 ConstantExpression compileConstant(VariableElement element) { 479 ConstantExpression compileConstant(VariableElement element) {
480 return measure(() { 480 return measure(() {
481 return constantCompiler.compileConstant(element); 481 return constantCompiler.compileConstant(element);
482 }); 482 });
483 } 483 }
484 484
485 @override
486 void evaluate(ConstantExpression constant) {
487 return measure(() {
488 return constantCompiler.evaluate(constant);
489 });
490 }
491
485 void compileVariable(VariableElement element) { 492 void compileVariable(VariableElement element) {
486 measure(() { 493 measure(() {
487 constantCompiler.compileVariable(element); 494 constantCompiler.compileVariable(element);
488 }); 495 });
489 } 496 }
490 497
491 @override 498 @override
492 ConstantExpression compileNode( 499 ConstantExpression compileNode(
493 Node node, 500 Node node,
494 TreeElements elements, 501 TreeElements elements,
(...skipping 15 matching lines...) Expand all
510 } 517 }
511 518
512 // TODO(johnniwinther): Remove this when values are computed from the 519 // TODO(johnniwinther): Remove this when values are computed from the
513 // expressions. 520 // expressions.
514 @override 521 @override
515 void copyConstantValues(DartConstantTask task) { 522 void copyConstantValues(DartConstantTask task) {
516 constantCompiler.constantValueMap.addAll( 523 constantCompiler.constantValueMap.addAll(
517 task.constantCompiler.constantValueMap); 524 task.constantCompiler.constantValueMap);
518 } 525 }
519 } 526 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/cps_ir/cps_ir_nodes.dart ('k') | pkg/compiler/lib/src/js_backend/constant_handler_javascript.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698