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

Side by Side Diff: lib/runtime/dart/_js_primitives.js

Issue 1355893003: Rewire DDC to use the analyzer task model (Closed) Base URL: https://github.com/dart-lang/dev_compiler.git@master
Patch Set: Fix for identifiers Created 5 years, 3 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
OLDNEW
1 dart_library.library('dart/_js_primitives', null, /* Imports */[ 1 dart_library.library('dart/_js_primitives', null, /* Imports */[
2 "dart_runtime/dart", 2 "dart_runtime/dart",
3 'dart/core' 3 'dart/core'
4 ], /* Lazy imports */[ 4 ], /* Lazy imports */[
5 ], function(exports, dart, core) { 5 ], function(exports, dart, core) {
6 'use strict'; 6 'use strict';
7 let dartx = dart.dartx; 7 let dartx = dart.dartx;
8 function printString(string) { 8 function printString(string) {
9 if (typeof dartPrint == "function") { 9 if (dart.notNull(dart.as(typeof dartPrint == "function", core.bool))) {
10 dartPrint(string); 10 dartPrint(string);
11 return; 11 return;
12 } 12 }
13 if (typeof console == "object" && typeof console.log != "undefined") { 13 if (dart.notNull(dart.as(typeof console == "object", core.bool)) && dart.not Null(dart.as(typeof console.log != "undefined", core.bool))) {
14 console.log(string); 14 console.log(string);
15 return; 15 return;
16 } 16 }
17 if (typeof window == "object") { 17 if (dart.notNull(dart.as(typeof window == "object", core.bool))) {
18 return; 18 return;
19 } 19 }
20 if (typeof print == "function") { 20 if (dart.notNull(dart.as(typeof print == "function", core.bool))) {
21 print(string); 21 print(string);
22 return; 22 return;
23 } 23 }
24 throw "Unable to print message: " + String(string); 24 throw "Unable to print message: " + String(string);
25 } 25 }
26 dart.fn(printString, dart.void, [core.String]); 26 dart.fn(printString, dart.void, [core.String]);
27 // Exports: 27 // Exports:
28 exports.printString = printString; 28 exports.printString = printString;
29 }); 29 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698