Chromium Code Reviews| Index: dart/lib/compiler/implementation/resolver.dart |
| diff --git a/dart/lib/compiler/implementation/resolver.dart b/dart/lib/compiler/implementation/resolver.dart |
| index bcd63bb596299f64a75eed2676ce93086146c91e..1431ac57ca36c7e540765bd3491e69d8fd756903 100644 |
| --- a/dart/lib/compiler/implementation/resolver.dart |
| +++ b/dart/lib/compiler/implementation/resolver.dart |
| @@ -399,6 +399,18 @@ class ResolverTask extends CompilerTask { |
| element); |
| } |
| + void resolveMetadataAnnotation(MetadataAnnotation annotation) { |
| + Node node = annotation.parseNode(compiler); |
| + Element fakeElement = new Element(const SourceString(''), |
|
ngeoffray
2012/08/22 14:28:56
Should we have a metadata element instead? This so
ahe
2012/08/22 17:23:02
Done.
|
| + ElementKind.FUNCTION, |
| + annotation.enclosingElement); |
|
Johnni Winther
2012/08/22 13:45:40
The element kind should be something else. We cann
ahe
2012/08/22 17:23:02
Done.
|
| + ResolverVisitor visitor = new ResolverVisitor(compiler, fakeElement); |
| + node.accept(visitor); |
| + annotation.value = compiler.constantHandler.compileNodeWithDefinitions( |
| + node, visitor.mapping); |
| + print(annotation); |
|
Johnni Winther
2012/08/22 13:45:40
Debug output.
ahe
2012/08/22 17:23:02
Done.
|
| + } |
| + |
| error(Node node, MessageKind kind, [arguments = const []]) { |
| ResolutionError message = new ResolutionError(kind, arguments); |
| compiler.reportError(node, message); |