OLD | NEW |
1 dart_library.library('language/closure_call_wrong_argument_count_negative_test',
null, /* Imports */[ | 1 dart_library.library('language/closure_call_wrong_argument_count_negative_test',
null, /* Imports */[ |
2 'dart_sdk' | 2 'dart_sdk' |
3 ], function load__closure_call_wrong_argument_count_negative_test(exports, dart_
sdk) { | 3 ], function load__closure_call_wrong_argument_count_negative_test(exports, dart_
sdk) { |
4 'use strict'; | 4 'use strict'; |
5 const core = dart_sdk.core; | 5 const core = dart_sdk.core; |
6 const dart = dart_sdk.dart; | 6 const dart = dart_sdk.dart; |
7 const dartx = dart_sdk.dartx; | 7 const dartx = dart_sdk.dartx; |
8 const closure_call_wrong_argument_count_negative_test = Object.create(null); | 8 const closure_call_wrong_argument_count_negative_test = Object.create(null); |
9 let intAndintTodynamic = () => (intAndintTodynamic = dart.constFn(dart.definit
eFunctionType(dart.dynamic, [core.int, core.int])))(); | 9 let intAndintToint = () => (intAndintToint = dart.constFn(dart.definiteFunctio
nType(core.int, [core.int, core.int])))(); |
10 let VoidTodynamic = () => (VoidTodynamic = dart.constFn(dart.definiteFunctionT
ype(dart.dynamic, [])))(); | 10 let VoidTodynamic = () => (VoidTodynamic = dart.constFn(dart.definiteFunctionT
ype(dart.dynamic, [])))(); |
11 closure_call_wrong_argument_count_negative_test.ClosureCallWrongArgumentCountN
egativeTest = class ClosureCallWrongArgumentCountNegativeTest extends core.Objec
t { | 11 closure_call_wrong_argument_count_negative_test.ClosureCallWrongArgumentCountN
egativeTest = class ClosureCallWrongArgumentCountNegativeTest extends core.Objec
t { |
12 static melke(f) { | 12 static melke(f) { |
13 return core.int._check(dart.dcall(f, 1, 2, 3)); | 13 return core.int._check(dart.dcall(f, 1, 2, 3)); |
14 } | 14 } |
15 static testMain() { | 15 static testMain() { |
16 function kuh(a, b) { | 16 function kuh(a, b) { |
17 return dart.notNull(a) + dart.notNull(b); | 17 return dart.notNull(a) + dart.notNull(b); |
18 } | 18 } |
19 dart.fn(kuh, intAndintTodynamic()); | 19 dart.fn(kuh, intAndintToint()); |
20 closure_call_wrong_argument_count_negative_test.ClosureCallWrongArgumentCo
untNegativeTest.melke(kuh); | 20 closure_call_wrong_argument_count_negative_test.ClosureCallWrongArgumentCo
untNegativeTest.melke(kuh); |
21 } | 21 } |
22 }; | 22 }; |
23 dart.setSignature(closure_call_wrong_argument_count_negative_test.ClosureCallW
rongArgumentCountNegativeTest, { | 23 dart.setSignature(closure_call_wrong_argument_count_negative_test.ClosureCallW
rongArgumentCountNegativeTest, { |
24 statics: () => ({ | 24 statics: () => ({ |
25 melke: dart.definiteFunctionType(core.int, [dart.dynamic]), | 25 melke: dart.definiteFunctionType(core.int, [dart.dynamic]), |
26 testMain: dart.definiteFunctionType(dart.void, []) | 26 testMain: dart.definiteFunctionType(dart.void, []) |
27 }), | 27 }), |
28 names: ['melke', 'testMain'] | 28 names: ['melke', 'testMain'] |
29 }); | 29 }); |
30 closure_call_wrong_argument_count_negative_test.main = function() { | 30 closure_call_wrong_argument_count_negative_test.main = function() { |
31 closure_call_wrong_argument_count_negative_test.ClosureCallWrongArgumentCoun
tNegativeTest.testMain(); | 31 closure_call_wrong_argument_count_negative_test.ClosureCallWrongArgumentCoun
tNegativeTest.testMain(); |
32 }; | 32 }; |
33 dart.fn(closure_call_wrong_argument_count_negative_test.main, VoidTodynamic())
; | 33 dart.fn(closure_call_wrong_argument_count_negative_test.main, VoidTodynamic())
; |
34 // Exports: | 34 // Exports: |
35 exports.closure_call_wrong_argument_count_negative_test = closure_call_wrong_a
rgument_count_negative_test; | 35 exports.closure_call_wrong_argument_count_negative_test = closure_call_wrong_a
rgument_count_negative_test; |
36 }); | 36 }); |
OLD | NEW |