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

Side by Side Diff: dart/sdk/lib/_internal/compiler/implementation/resolution/members.dart

Issue 28923002: Version 0.8.3.1 (Closed) Base URL: http://dart.googlecode.com/svn/trunk/
Patch Set: Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | dart/tests/lib/mirrors/static_metatarget_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 resolution; 5 part of resolution;
6 6
7 abstract class TreeElements { 7 abstract class TreeElements {
8 Element get currentElement; 8 Element get currentElement;
9 Set<Node> get superUses; 9 Set<Node> get superUses;
10 10
(...skipping 698 matching lines...) Expand 10 before | Expand all | Expand 10 after
709 // Stepwise assignment to ensure invariant. 709 // Stepwise assignment to ensure invariant.
710 element.supertypeLoadState = STATE_STARTED; 710 element.supertypeLoadState = STATE_STARTED;
711 element.supertypeLoadState = STATE_DONE; 711 element.supertypeLoadState = STATE_DONE;
712 element.resolutionState = STATE_DONE; 712 element.resolutionState = STATE_DONE;
713 // TODO(johnniwinther): Check matching type variables and 713 // TODO(johnniwinther): Check matching type variables and
714 // empty extends/implements clauses. 714 // empty extends/implements clauses.
715 } 715 }
716 for (MetadataAnnotation metadata in element.metadata) { 716 for (MetadataAnnotation metadata in element.metadata) {
717 metadata.ensureResolved(compiler); 717 metadata.ensureResolved(compiler);
718 } 718 }
719
720 // Force resolution of metadata on non-instance members since they may be
721 // inspected by the backend while emitting. Metadata on instance members is
722 // handled as a result of processing instantiated class members in the
723 // enqueuer.
724 // TODO(ahe): Avoid this eager resolution.
725 element.forEachMember((_, Element member) {
726 if (!member.isInstanceMember()) {
727 compiler.withCurrentElement(member, () {
728 for (MetadataAnnotation metadata in member.metadata) {
729 metadata.ensureResolved(compiler);
730 }
731 });
732 }
733 });
719 } 734 }
720 735
721 void checkClass(ClassElement element) { 736 void checkClass(ClassElement element) {
722 if (element.isMixinApplication) { 737 if (element.isMixinApplication) {
723 checkMixinApplication(element); 738 checkMixinApplication(element);
724 } else { 739 } else {
725 checkClassMembers(element); 740 checkClassMembers(element);
726 } 741 }
727 } 742 }
728 743
(...skipping 3913 matching lines...) Expand 10 before | Expand all | Expand 10 after
4642 return finishConstructorReference(visit(expression), 4657 return finishConstructorReference(visit(expression),
4643 expression, expression); 4658 expression, expression);
4644 } 4659 }
4645 } 4660 }
4646 4661
4647 /// Looks up [name] in [scope] and unwraps the result. 4662 /// Looks up [name] in [scope] and unwraps the result.
4648 Element lookupInScope(Compiler compiler, Node node, 4663 Element lookupInScope(Compiler compiler, Node node,
4649 Scope scope, SourceString name) { 4664 Scope scope, SourceString name) {
4650 return Elements.unwrap(scope.lookup(name), compiler, node); 4665 return Elements.unwrap(scope.lookup(name), compiler, node);
4651 } 4666 }
OLDNEW
« no previous file with comments | « no previous file | dart/tests/lib/mirrors/static_metatarget_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698