| Index: frog/leg/resolver.dart
|
| diff --git a/frog/leg/resolver.dart b/frog/leg/resolver.dart
|
| index 0719b23532b118b0a745d247f5e136ca5e7ec904..144c080424de59d5ce78169aa28a0e9a8fb2c6e8 100644
|
| --- a/frog/leg/resolver.dart
|
| +++ b/frog/leg/resolver.dart
|
| @@ -489,7 +489,19 @@ class FullResolverVisitor extends ResolverVisitor {
|
| }
|
|
|
| visitForInStatement(ForInStatement node) {
|
| - cancel(node, 'unimplemented');
|
| + visit(node.expression);
|
| + Scope scope = new BlockScope(context);
|
| + Node declaration = node.declaredIdentifier;
|
| + visitIn(declaration, scope);
|
| + visitIn(node.body, scope);
|
| + if (declaration is !VariableDefinitions ||
|
| + !declaration.definitions.nodes.tail.isEmpty()) {
|
| + // The variable declaration is either not a declaration, or it's
|
| + // declaring more than one variable.
|
| + // TODO(lrn): A non-terminating error report would be fine here.
|
| + print(declaration);
|
| + cancel(node.declaredIdentifier, "Invalid variable declaration");
|
| + }
|
| }
|
|
|
| visitLabelledStatement(LabelledStatement node) {
|
|
|