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

Side by Side Diff: compiler/java/com/google/dart/compiler/ast/DartExpression.java

Issue 8231031: Check for compile-time constants in DartCompiler (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: All tests pass but one junit test Created 9 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
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 package com.google.dart.compiler.ast; 5 package com.google.dart.compiler.ast;
6 6
7 import com.google.dart.compiler.type.Type;
8
7 /** 9 /**
8 * Abstract base class for Dart expressions. 10 * Abstract base class for Dart expressions.
9 */ 11 */
10 public abstract class DartExpression extends DartNode { 12 public abstract class DartExpression extends DartNode {
13 Type type;
zundel 2011/10/14 01:54:28 I was advised to use getSymbol().getType(), but bi
11 14
12 public boolean isAssignable() { 15 public boolean isAssignable() {
13 // By default you cannot assign to expressions. 16 // By default you cannot assign to expressions.
14 return false; 17 return false;
15 } 18 }
16 19
17 @Override 20 @Override
18 public DartExpression getNormalizedNode() { 21 public DartExpression getNormalizedNode() {
19 return (DartExpression) super.getNormalizedNode(); 22 return (DartExpression) super.getNormalizedNode();
20 } 23 }
24
25 @Override
26 public void setType(Type type) {
27 this.type = type;
28 }
29
30 @Override
31 public Type getType() {
32 return type;
33 }
21 } 34 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698