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

Side by Side Diff: lib/compiler/implementation/resolver.dart

Issue 10957060: First stab at parsing redirecting constructors. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address review comments. Add test exceptions. 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | lib/compiler/implementation/scanner/listener.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 abstract class TreeElements { 5 abstract class TreeElements {
6 Element operator[](Node node); 6 Element operator[](Node node);
7 Selector getSelector(Send send); 7 Selector getSelector(Send send);
8 DartType getType(TypeAnnotation annotation); 8 DartType getType(TypeAnnotation annotation);
9 bool isParameterChecked(Element element); 9 bool isParameterChecked(Element element);
10 } 10 }
(...skipping 1744 matching lines...) Expand 10 before | Expand all | Expand 10 after
1755 for (Link<Node> link = node.nodes; !link.isEmpty(); link = link.tail) { 1755 for (Link<Node> link = node.nodes; !link.isEmpty(); link = link.tail) {
1756 visit(link.head); 1756 visit(link.head);
1757 } 1757 }
1758 } 1758 }
1759 1759
1760 visitOperator(Operator node) { 1760 visitOperator(Operator node) {
1761 unimplemented(node, 'operator'); 1761 unimplemented(node, 'operator');
1762 } 1762 }
1763 1763
1764 visitReturn(Return node) { 1764 visitReturn(Return node) {
1765 if (node.isRedirectingConstructorBody) {
1766 unimplemented(node, 'redirecting constructors');
1767 }
1765 visit(node.expression); 1768 visit(node.expression);
1766 } 1769 }
1767 1770
1768 visitThrow(Throw node) { 1771 visitThrow(Throw node) {
1769 if (!inCatchBlock && node.expression === null) { 1772 if (!inCatchBlock && node.expression === null) {
1770 error(node, MessageKind.THROW_WITHOUT_EXPRESSION); 1773 error(node, MessageKind.THROW_WITHOUT_EXPRESSION);
1771 } 1774 }
1772 visit(node.expression); 1775 visit(node.expression);
1773 } 1776 }
1774 1777
(...skipping 1362 matching lines...) Expand 10 before | Expand all | Expand 10 after
3137 return result; 3140 return result;
3138 } 3141 }
3139 Element lookup(SourceString name) => localLookup(name); 3142 Element lookup(SourceString name) => localLookup(name);
3140 Element lexicalLookup(SourceString name) => localLookup(name); 3143 Element lexicalLookup(SourceString name) => localLookup(name);
3141 3144
3142 Element add(Element newElement) { 3145 Element add(Element newElement) {
3143 throw "Cannot add an element in a patch library scope"; 3146 throw "Cannot add an element in a patch library scope";
3144 } 3147 }
3145 String toString() => 'PatchLibraryScope($origin,$patch)'; 3148 String toString() => 'PatchLibraryScope($origin,$patch)';
3146 } 3149 }
OLDNEW
« no previous file with comments | « no previous file | lib/compiler/implementation/scanner/listener.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698