| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 import "package:expect/expect.dart"; | |
| 6 | |
| 7 closure0() { | 5 closure0() { |
| 8 var x = 499; | 6 var x = 499; |
| 9 // TODO(floitsch): remove name from functions. | 7 // TODO(floitsch): remove name from functions. |
| 10 var f = fun() { return x; }; | 8 var f = fun() { return x; }; |
| 11 Expect.equals(499, f()); | 9 Expect.equals(499, f()); |
| 12 } | 10 } |
| 13 | 11 |
| 14 class A { | 12 class A { |
| 15 closure1() { | 13 closure1() { |
| 16 var x = 499; | 14 var x = 499; |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 new A().closure1(); | 82 new A().closure1(); |
| 85 closure2(); | 83 closure2(); |
| 86 closure3(); | 84 closure3(); |
| 87 closure4(); | 85 closure4(); |
| 88 closure5(); | 86 closure5(); |
| 89 new A2().closure6(); | 87 new A2().closure6(); |
| 90 closure7(); | 88 closure7(); |
| 91 closure8(); | 89 closure8(); |
| 92 closure9(); | 90 closure9(); |
| 93 } | 91 } |
| OLD | NEW |