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

Side by Side Diff: pkg/compiler/lib/src/js_emitter/program_builder/field_visitor.dart

Issue 2603263002: Prefix resolution_types with Resolution. (Closed)
Patch Set: Rebased Created 3 years, 11 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) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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 dart2js.js_emitter.program_builder; 5 part of dart2js.js_emitter.program_builder;
6 6
7 /** 7 /**
8 * [member] is a field (instance, static, or top level). 8 * [member] is a field (instance, static, or top level).
9 * 9 *
10 * [name] is the field name that the [Namer] has picked for this field's 10 * [name] is the field name that the [Namer] has picked for this field's
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 // We never access a field in a closure (a captured variable) without 158 // We never access a field in a closure (a captured variable) without
159 // knowing that it is there. Therefore we don't need to use a getter 159 // knowing that it is there. Therefore we don't need to use a getter
160 // (that will throw if the getter method is missing), but can always 160 // (that will throw if the getter method is missing), but can always
161 // access the field directly. 161 // access the field directly.
162 field is ClosureFieldElement; 162 field is ClosureFieldElement;
163 } 163 }
164 164
165 bool canAvoidGeneratedCheckedSetter(VariableElement member) { 165 bool canAvoidGeneratedCheckedSetter(VariableElement member) {
166 // We never generate accessors for top-level/static fields. 166 // We never generate accessors for top-level/static fields.
167 if (!member.isInstanceMember) return true; 167 if (!member.isInstanceMember) return true;
168 DartType type = member.type; 168 ResolutionDartType type = member.type;
169 return type.treatAsDynamic || type.isObject; 169 return type.treatAsDynamic || type.isObject;
170 } 170 }
171 } 171 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698