Chromium Code Reviews| Index: lib/compiler/implementation/resolver.dart |
| diff --git a/lib/compiler/implementation/resolver.dart b/lib/compiler/implementation/resolver.dart |
| index 246a546edf7ae8b40d13e80b57ae7a63b3775156..e2fc4caf9ac7aa7ad1df01a6864cbbca27594f41 100644 |
| --- a/lib/compiler/implementation/resolver.dart |
| +++ b/lib/compiler/implementation/resolver.dart |
| @@ -1875,10 +1875,11 @@ class ClassResolverVisitor extends TypeDefinitionVisitor { |
| * constructors. |
| */ |
| void addDefaultConstructorIfNeeded(ClassElement element) { |
| - if (element.constructors.length != 0) return; |
| + //if (element.constructors.length != 0) return; |
|
Lasse Reichstein Nielsen
2012/08/08 14:22:12
Remove commented code.
Anders Johnsen
2012/08/08 17:30:37
Done.
|
| + if (element.hasConstructor) return; |
| SynthesizedConstructorElement constructor = |
| new SynthesizedConstructorElement(element); |
| - element.constructors[element.name] = constructor; |
| + element.addToScope(constructor, compiler); |
| Type returnType = compiler.types.voidType; |
| constructor.type = new FunctionType(returnType, const EmptyLink<Type>(), |
| constructor); |