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

Side by Side Diff: pkg/compiler/lib/src/resolution/registry.dart

Issue 1346093003: Revert "Add optional message to assert in Dart2js - continued" (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years, 3 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) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 library dart2js.resolution.registry; 5 library dart2js.resolution.registry;
6 6
7 import '../common/backend_api.dart' show 7 import '../common/backend_api.dart' show
8 Backend; 8 Backend;
9 import '../common/registry.dart' show 9 import '../common/registry.dart' show
10 Registry; 10 Registry;
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 47
48 ResolutionEnqueuer get world => compiler.enqueuer.resolution; 48 ResolutionEnqueuer get world => compiler.enqueuer.resolution;
49 49
50 @override 50 @override
51 bool get isForResolution => true; 51 bool get isForResolution => true;
52 52
53 @override 53 @override
54 Iterable<Element> get otherDependencies => mapping.otherDependencies; 54 Iterable<Element> get otherDependencies => mapping.otherDependencies;
55 55
56 @override 56 @override
57 void registerAssert(bool hasMessage) {
58 // TODO(johnniwinther): Do something here?
59 }
60
61 @override
62 void registerDependency(Element element) { 57 void registerDependency(Element element) {
63 mapping.registerDependency(element); 58 mapping.registerDependency(element);
64 } 59 }
65 60
66 @override 61 @override
67 void registerDynamicGetter(UniverseSelector selector) { 62 void registerDynamicGetter(UniverseSelector selector) {
68 world.registerDynamicGetter(selector); 63 world.registerDynamicGetter(selector);
69 } 64 }
70 65
71 @override 66 @override
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after
576 // [registerDependency]. 571 // [registerDependency].
577 if (element == null) return; 572 if (element == null) return;
578 registerStaticUse(element); 573 registerStaticUse(element);
579 registerDependency(element); 574 registerDependency(element);
580 } 575 }
581 576
582 void registerInstantiation(InterfaceType type) { 577 void registerInstantiation(InterfaceType type) {
583 world.registerInstantiatedType(type, this); 578 world.registerInstantiatedType(type, this);
584 } 579 }
585 580
586 void registerAssert(bool hasMessage) { 581 void registerAssert(Send node) {
587 backend.resolutionCallbacks.onAssert(hasMessage, this); 582 mapping.setAssert(node);
583 backend.resolutionCallbacks.onAssert(node, this);
584 }
585
586 bool isAssert(Send node) {
587 return mapping.isAssert(node);
588 } 588 }
589 589
590 void registerSendStructure(Send node, SendStructure sendStructure) { 590 void registerSendStructure(Send node, SendStructure sendStructure) {
591 mapping.setSendStructure(node, sendStructure); 591 mapping.setSendStructure(node, sendStructure);
592 } 592 }
593 593
594 // TODO(johnniwinther): Remove this when [SendStructure]s are part of the 594 // TODO(johnniwinther): Remove this when [SendStructure]s are part of the
595 // [ResolutionResult]. 595 // [ResolutionResult].
596 SendStructure getSendStructure(Send node) { 596 SendStructure getSendStructure(Send node) {
597 return mapping.getSendStructure(node); 597 return mapping.getSendStructure(node);
598 } 598 }
599 599
600 void registerAsyncMarker(FunctionElement element) { 600 void registerAsyncMarker(FunctionElement element) {
601 backend.registerAsyncMarker(element, world, this); 601 backend.registerAsyncMarker(element, world, this);
602 } 602 }
603 603
604 void registerAsyncForIn(AsyncForIn node) { 604 void registerAsyncForIn(AsyncForIn node) {
605 backend.resolutionCallbacks.onAsyncForIn(node, this); 605 backend.resolutionCallbacks.onAsyncForIn(node, this);
606 } 606 }
607 607
608 void registerIncDecOperation() { 608 void registerIncDecOperation() {
609 backend.resolutionCallbacks.onIncDecOperation(this); 609 backend.resolutionCallbacks.onIncDecOperation(this);
610 } 610 }
611 611
612 void registerTryStatement() { 612 void registerTryStatement() {
613 mapping.containsTryStatement = true; 613 mapping.containsTryStatement = true;
614 } 614 }
615 } 615 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/resolution/members.dart ('k') | pkg/compiler/lib/src/resolution/resolution_result.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698