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

Side by Side Diff: test/codegen/expect/temps.js

Issue 1879373004: Implement modular compilation (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 4 years, 8 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 unified diff | Download patch
« no previous file with comments | « test/codegen/expect/syncstar_syntax.txt ('k') | test/codegen/expect/temps.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 dart_library.library('temps', null, /* Imports */[ 1 dart_library.library('temps', null, /* Imports */[
2 'dart/_runtime', 2 'dart_sdk'
3 'dart/core' 3 ], function(exports, dart_sdk) {
4 ], /* Lazy imports */[
5 ], function(exports, dart, core) {
6 'use strict'; 4 'use strict';
7 let dartx = dart.dartx; 5 const core = dart_sdk.core;
6 const dart = dart_sdk.dart;
7 const dartx = dart_sdk.dartx;
8 const temps = Object.create(null);
8 const _x = Symbol('_x'); 9 const _x = Symbol('_x');
9 const __x = Symbol('__x'); 10 const __x = Symbol('__x');
10 const _function = Symbol('_function'); 11 const _function = Symbol('_function');
11 class FormalCollision extends core.Object { 12 temps.FormalCollision = class FormalCollision extends core.Object {
12 FormalCollision(x, _x$, func) { 13 FormalCollision(x, _x$, func) {
13 this[_x] = x; 14 this[_x] = x;
14 this[__x] = _x$; 15 this[__x] = _x$;
15 this[_function] = func; 16 this[_function] = func;
16 } 17 }
17 } 18 };
18 dart.setSignature(FormalCollision, { 19 dart.setSignature(temps.FormalCollision, {
19 constructors: () => ({FormalCollision: [FormalCollision, [core.int, core.int , core.Function]]}) 20 constructors: () => ({FormalCollision: [temps.FormalCollision, [core.int, co re.int, core.Function]]})
20 }); 21 });
21 const _opt = Symbol('_opt'); 22 const _opt = Symbol('_opt');
22 class OptionalArg extends core.Object { 23 temps.OptionalArg = class OptionalArg extends core.Object {
23 OptionalArg(opt) { 24 OptionalArg(opt) {
24 if (opt === void 0) opt = 123; 25 if (opt === void 0) opt = 123;
25 this[_opt] = opt; 26 this[_opt] = opt;
26 this.opt = null; 27 this.opt = null;
27 } 28 }
28 named(opts) { 29 named(opts) {
29 let opt = opts && 'opt' in opts ? opts.opt : 456; 30 let opt = opts && 'opt' in opts ? opts.opt : 456;
30 this.opt = opt; 31 this.opt = opt;
31 this[_opt] = null; 32 this[_opt] = null;
32 } 33 }
33 } 34 };
34 dart.defineNamedConstructor(OptionalArg, 'named'); 35 dart.defineNamedConstructor(temps.OptionalArg, 'named');
35 dart.setSignature(OptionalArg, { 36 dart.setSignature(temps.OptionalArg, {
36 constructors: () => ({ 37 constructors: () => ({
37 OptionalArg: [OptionalArg, [], [core.int]], 38 OptionalArg: [temps.OptionalArg, [], [core.int]],
38 named: [OptionalArg, [], {opt: core.int}] 39 named: [temps.OptionalArg, [], {opt: core.int}]
39 }) 40 })
40 }); 41 });
41 function main() { 42 temps.main = function() {
42 core.print(new FormalCollision(1, 2, dart.fn(x => x))); 43 core.print(new temps.FormalCollision(1, 2, dart.fn(x => x)));
43 core.print(new OptionalArg()[_opt]); 44 core.print(new temps.OptionalArg()[_opt]);
44 core.print(new OptionalArg.named()[_opt]); 45 core.print(new temps.OptionalArg.named()[_opt]);
45 } 46 };
46 dart.fn(main); 47 dart.fn(temps.main);
47 // Exports: 48 // Exports:
48 exports.FormalCollision = FormalCollision; 49 exports.temps = temps;
49 exports.OptionalArg = OptionalArg;
50 exports.main = main;
51 }); 50 });
OLDNEW
« no previous file with comments | « test/codegen/expect/syncstar_syntax.txt ('k') | test/codegen/expect/temps.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698