Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1012)

Unified Diff: test/codegen/expect/language/regress_20840_test.js

Issue 2128353002: Check in codegen test expectations. (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: test/codegen/expect/language/regress_20840_test.js
diff --git a/test/codegen/expect/language/regress_20840_test.js b/test/codegen/expect/language/regress_20840_test.js
new file mode 100644
index 0000000000000000000000000000000000000000..e242e8000892ad0c474fac8050f4b2965808413c
--- /dev/null
+++ b/test/codegen/expect/language/regress_20840_test.js
@@ -0,0 +1,35 @@
+dart_library.library('language/regress_20840_test', null, /* Imports */[
+ 'dart_sdk'
+], function load__regress_20840_test(exports, dart_sdk) {
+ 'use strict';
+ const core = dart_sdk.core;
+ const _interceptors = dart_sdk._interceptors;
+ const dart = dart_sdk.dart;
+ const dartx = dart_sdk.dartx;
+ const regress_20840_test = Object.create(null);
+ let JSArrayOfint = () => (JSArrayOfint = dart.constFn(_interceptors.JSArray$(core.int)))();
+ let intTovoid = () => (intTovoid = dart.constFn(dart.definiteFunctionType(dart.void, [core.int])))();
+ let VoidTovoid = () => (VoidTovoid = dart.constFn(dart.definiteFunctionType(dart.void, [])))();
+ regress_20840_test.SomeClass = class SomeClass extends core.Object {
+ new() {
+ this.someField = null;
+ JSArrayOfint().of([1])[dartx.forEach](dart.fn(o => this.someMethod(), intTovoid()));
+ this.someField = new core.Object();
+ }
+ someMethod() {
+ if (this.someField != null) {
+ dart.throw("FAIL");
+ }
+ }
+ };
+ dart.setSignature(regress_20840_test.SomeClass, {
+ constructors: () => ({new: dart.definiteFunctionType(regress_20840_test.SomeClass, [])}),
+ methods: () => ({someMethod: dart.definiteFunctionType(dart.void, [])})
+ });
+ regress_20840_test.main = function() {
+ new regress_20840_test.SomeClass();
+ };
+ dart.fn(regress_20840_test.main, VoidTovoid());
+ // Exports:
+ exports.regress_20840_test = regress_20840_test;
+});
« no previous file with comments | « test/codegen/expect/language/regress_20394_test_none_multi.js ('k') | test/codegen/expect/language/regress_21016_test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698