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

Side by Side Diff: pkg/front_end/lib/src/fasta/source/diet_listener.dart

Issue 2723883002: Add AstBuilder support for fields. (Closed)
Patch Set: Created 3 years, 9 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) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 fasta.diet_listener; 5 library fasta.diet_listener;
6 6
7 import 'package:kernel/ast.dart' show AsyncMarker; 7 import 'package:kernel/ast.dart' show AsyncMarker;
8 8
9 import 'package:kernel/class_hierarchy.dart' show ClassHierarchy; 9 import 'package:kernel/class_hierarchy.dart' show ClassHierarchy;
10 10
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 171
172 @override 172 @override
173 void endFunctionTypeAlias( 173 void endFunctionTypeAlias(
174 Token typedefKeyword, Token equals, Token endToken) { 174 Token typedefKeyword, Token equals, Token endToken) {
175 debugEvent("FunctionTypeAlias"); 175 debugEvent("FunctionTypeAlias");
176 discard(2); // Name + endToken. 176 discard(2); // Name + endToken.
177 checkEmpty(typedefKeyword.charOffset); 177 checkEmpty(typedefKeyword.charOffset);
178 } 178 }
179 179
180 @override 180 @override
181 void endFields(int count, Token beginToken, Token endToken) { 181 void endFields(
182 int count, Token covariantToken, Token beginToken, Token endToken) {
182 debugEvent("Fields"); 183 debugEvent("Fields");
183 List<String> names = popList(count); 184 List<String> names = popList(count);
184 Builder builder = lookupBuilder(beginToken, null, names.first); 185 Builder builder = lookupBuilder(beginToken, null, names.first);
185 buildFields(beginToken, false, builder); 186 buildFields(beginToken, false, builder);
186 } 187 }
187 188
188 @override 189 @override
189 void handleAsyncModifier(Token asyncToken, Token startToken) { 190 void handleAsyncModifier(Token asyncToken, Token startToken) {
190 debugEvent("AsyncModifier"); 191 debugEvent("AsyncModifier");
191 } 192 }
(...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after
553 bool get isTargetingDartVm { 554 bool get isTargetingDartVm {
554 // TODO(ahe): Find a more reliable way to check if this is the Dart VM. 555 // TODO(ahe): Find a more reliable way to check if this is the Dart VM.
555 return !coreTypes.containsLibrary("dart:_js_helper"); 556 return !coreTypes.containsLibrary("dart:_js_helper");
556 } 557 }
557 558
558 @override 559 @override
559 void debugEvent(String name) { 560 void debugEvent(String name) {
560 // printEvent(name); 561 // printEvent(name);
561 } 562 }
562 } 563 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698