| Index: lib/compiler/implementation/tree/nodes.dart
|
| diff --git a/lib/compiler/implementation/tree/nodes.dart b/lib/compiler/implementation/tree/nodes.dart
|
| index 5fcd0eadcd7cd09d3b79318adc5105c1a4113e26..addc4fd318fac0880b2284d1d84a3b0fd4824609 100644
|
| --- a/lib/compiler/implementation/tree/nodes.dart
|
| +++ b/lib/compiler/implementation/tree/nodes.dart
|
| @@ -1169,6 +1169,17 @@ class Modifiers extends Node {
|
| }
|
| return flags;
|
| }
|
| +
|
| + Node findModifier(String modifier) {
|
| + Link<Node> nodeList = nodes.nodes;
|
| + for (; !nodeList.isEmpty(); nodeList = nodeList.tail) {
|
| + String value = nodeList.head.asIdentifier().source.stringValue;
|
| + if(value === modifier) {
|
| + return nodeList.head;
|
| + }
|
| + }
|
| + return null;
|
| + }
|
|
|
| Modifiers asModifiers() => this;
|
| Token getBeginToken() => nodes.getBeginToken();
|
| @@ -1184,6 +1195,8 @@ class Modifiers extends Node {
|
| bool isFactory() => (flags & FLAG_FACTORY) != 0;
|
| bool isExternal() => (flags & FLAG_EXTERNAL) != 0;
|
|
|
| + Node getStatic() => findModifier('static');
|
| +
|
| /**
|
| * Use this to check if the declaration is either explicitly or implicitly
|
| * final.
|
|
|