Chromium Code Reviews| Index: compiler/java/com/google/dart/compiler/resolver/HasConstantTypeSetter.java |
| diff --git a/compiler/java/com/google/dart/compiler/resolver/HasConstantTypeSetter.java b/compiler/java/com/google/dart/compiler/resolver/HasConstantTypeSetter.java |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..45d0c566a6f99e75d6c4a5b75acda004cea95cee |
| --- /dev/null |
| +++ b/compiler/java/com/google/dart/compiler/resolver/HasConstantTypeSetter.java |
| @@ -0,0 +1,20 @@ |
| +// Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
|
zundel
2012/03/13 17:10:34
2012
|
| +// for details. All rights reserved. Use of this source code is governed by a |
| +// BSD-style license that can be found in the LICENSE file. |
| +package com.google.dart.compiler.resolver; |
| + |
| +import com.google.dart.compiler.type.Type; |
| + |
| +/** |
| + * Optional interface of {@link FieldElement} which can remember {@link Type} of constant. Note that |
| + * it also extends {@link NodeElement} because we can set {@link Type} only if we can infer it from |
| + * the AST. |
| + */ |
| +public interface HasConstantTypeSetter extends NodeElement { |
| + /** |
| + * Sets the inferred type of this constant. |
| + * |
| + * @param type the {@link Type} to set, not <code>null</code>. |
| + */ |
| + void setConstantType(Type type); |
| +} |