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

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

Issue 10828149: Change final field to abstract getter. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 4 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 | no next file » | 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 #library('elements'); 5 #library('elements');
6 6
7 #import('../tree/tree.dart'); 7 #import('../tree/tree.dart');
8 #import('../scanner/scannerlib.dart'); 8 #import('../scanner/scannerlib.dart');
9 #import('../leg.dart'); // TODO(karlklose): we only need type. 9 #import('../leg.dart'); // TODO(karlklose): we only need type.
10 #import('../util/util.dart'); 10 #import('../util/util.dart');
(...skipping 827 matching lines...) Expand 10 before | Expand all | Expand 10 after
838 abstract class TypeDeclarationElement implements Element { 838 abstract class TypeDeclarationElement implements Element {
839 // TODO(johnniwinther): This class should eventually be a mixin. 839 // TODO(johnniwinther): This class should eventually be a mixin.
840 840
841 /** 841 /**
842 * The type variables declared on this declaration. The type variables are not 842 * The type variables declared on this declaration. The type variables are not
843 * available until the type of the element has been computed through 843 * available until the type of the element has been computed through
844 * [computeType]. 844 * [computeType].
845 */ 845 */
846 // TODO(johnniwinther): Find a (better) way to decouple [typeVariables] from 846 // TODO(johnniwinther): Find a (better) way to decouple [typeVariables] from
847 // [Compiler]. 847 // [Compiler].
848 final Link<Type> typeVariables; 848 abstract Link<Type> get typeVariables();
849 849
850 /** 850 /**
851 * Creates the type variables, their type and corresponding element, for the 851 * Creates the type variables, their type and corresponding element, for the
852 * type variables declared in [parameter] on [element]. The bounds of the type 852 * type variables declared in [parameter] on [element]. The bounds of the type
853 * variables are not set until [element] has been resolved. 853 * variables are not set until [element] has been resolved.
854 */ 854 */
855 static Link<Type> createTypeVariables(TypeDeclarationElement element, 855 static Link<Type> createTypeVariables(TypeDeclarationElement element,
856 NodeList parameters) { 856 NodeList parameters) {
857 if (parameters === null) return const EmptyLink<Type>(); 857 if (parameters === null) return const EmptyLink<Type>();
858 858
(...skipping 389 matching lines...) Expand 10 before | Expand all | Expand 10 after
1248 TypeVariableElement(name, Element enclosing, this.cachedNode, 1248 TypeVariableElement(name, Element enclosing, this.cachedNode,
1249 [this.type, this.bound]) 1249 [this.type, this.bound])
1250 : super(name, ElementKind.TYPE_VARIABLE, enclosing); 1250 : super(name, ElementKind.TYPE_VARIABLE, enclosing);
1251 1251
1252 TypeVariableType computeType(compiler) => type; 1252 TypeVariableType computeType(compiler) => type;
1253 1253
1254 Node parseNode(compiler) => cachedNode; 1254 Node parseNode(compiler) => cachedNode;
1255 1255
1256 String toString() => "${enclosingElement.toString()}.${name.slowToString()}"; 1256 String toString() => "${enclosingElement.toString()}.${name.slowToString()}";
1257 } 1257 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698