| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 // This tests uses the multi-test "ok" feature: | 5 // This tests uses the multi-test "ok" feature: |
| 6 // none: Desired behaviour, passing on the VM. | 6 // none: Desired behaviour, passing on the VM. |
| 7 // 01: Trimmed version for dart2js. | 7 // 01: Trimmed version for dart2js. |
| 8 // | 8 // |
| 9 // TODO(rmacnak,ahe): Remove multi-test when VM and dart2js are on par. | 9 // TODO(rmacnak,ahe): Remove multi-test when VM and dart2js are on par. |
| 10 | 10 |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 // TODO(6490): Currently only supported by the VM. | 25 // TODO(6490): Currently only supported by the VM. |
| 26 B.baz(final int x, int y, final int z); | 26 B.baz(final int x, int y, final int z); |
| 27 B.qux(int x, [int y= 3 + 1]); | 27 B.qux(int x, [int y= 3 + 1]); |
| 28 B.quux(int x, {String str: "foo"}); | 28 B.quux(int x, {String str: "foo"}); |
| 29 B.corge({int x: 3 * 17, String str: "bar"}); | 29 B.corge({int x: 3 * 17, String str: "bar"}); |
| 30 | 30 |
| 31 var _x; | 31 var _x; |
| 32 get x => _x; | 32 get x => _x; |
| 33 set x(final value) { _x = value; } | 33 set x(final value) { _x = value; } |
| 34 | 34 |
| 35 grault([int x]); | 35 grault([int x]) {} |
| 36 garply({int y}); | 36 garply({int y}) {} |
| 37 waldo(int z); | 37 waldo(int z) {} |
| 38 } | 38 } |
| 39 | 39 |
| 40 class C <S extends int, T> { | 40 class C <S extends int, T> { |
| 41 // TODO(6490): Currently only supported by the VM. | 41 // TODO(6490): Currently only supported by the VM. |
| 42 foo(int a, S b) => b; | 42 foo(int a, S b) => b; |
| 43 bar(S a, T b, num c) {} | 43 bar(S a, T b, num c) {} |
| 44 } | 44 } |
| 45 | 45 |
| 46 main() { | 46 main() { |
| 47 ClassMirror cm = reflectClass(B); | 47 ClassMirror cm = reflectClass(B); |
| (...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 173 expect('[Parameter(s(a) in s(bar),' | 173 expect('[Parameter(s(a) in s(bar),' |
| 174 ' type = TypeVariable(s(S) in s(C),' | 174 ' type = TypeVariable(s(S) in s(C),' |
| 175 ' upperBound = Class(s(int) in s(dart.core), top-level))), ' | 175 ' upperBound = Class(s(int) in s(dart.core), top-level))), ' |
| 176 'Parameter(s(b) in s(bar),' | 176 'Parameter(s(b) in s(bar),' |
| 177 ' type = TypeVariable(s(T) in s(C),' | 177 ' type = TypeVariable(s(T) in s(C),' |
| 178 ' upperBound = Class(s(Object) in s(dart.core), top-level))), ' | 178 ' upperBound = Class(s(Object) in s(dart.core), top-level))), ' |
| 179 'Parameter(s(c) in s(bar),' | 179 'Parameter(s(c) in s(bar),' |
| 180 ' type = Class(s(num) in s(dart.core), top-level))]', | 180 ' type = Class(s(num) in s(dart.core), top-level))]', |
| 181 barInC.parameters); | 181 barInC.parameters); |
| 182 } | 182 } |
| OLD | NEW |