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

Side by Side Diff: test/codegen/misc.dart

Issue 1341963003: qualify core types: Object, Error, Symbol (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: 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
« lib/src/js/nodes.dart ('K') | « test/codegen/expect/misc.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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 5
6 // Codegen dependency order test 6 // Codegen dependency order test
7 const UNINITIALIZED = const _Uninitialized(); 7 const UNINITIALIZED = const _Uninitialized();
8 class _Uninitialized { const _Uninitialized(); } 8 class _Uninitialized { const _Uninitialized(); }
9 9
10 class Generic<T> { 10 class Generic<T> {
(...skipping 23 matching lines...) Expand all
34 const _escapeMap = const { 34 const _escapeMap = const {
35 '\n': r'\n', 35 '\n': r'\n',
36 '\r': r'\r', 36 '\r': r'\r',
37 '\f': r'\f', 37 '\f': r'\f',
38 '\b': r'\b', 38 '\b': r'\b',
39 '\t': r'\t', 39 '\t': r'\t',
40 '\v': r'\v', 40 '\v': r'\v',
41 '\x7F': r'\x7F', // delete 41 '\x7F': r'\x7F', // delete
42 }; 42 };
43 43
44 // Wacky but supported...
45 class Symbol<T> {
46 final T _foo;
47 Symbol(this._foo);
48 }
49
44 50
45 main() { 51 main() {
46 // Number literals in call expressions. 52 // Number literals in call expressions.
47 print(1.toString()); 53 print(1.toString());
48 print(1.0.toString()); 54 print(1.0.toString());
49 print(1.1.toString()); 55 print(1.1.toString());
50 56
51 // Type literals, #184 57 // Type literals, #184
52 dynamic x = 42; 58 dynamic x = 42;
53 print(x == dynamic); 59 print(x == dynamic);
54 print(x == Generic); 60 print(x == Generic);
55 61
56 // Should be Generic<dynamic> 62 // Should be Generic<dynamic>
57 print(new Generic<int>().type); 63 print(new Generic<int>().type);
58 64
59 print(new Derived() == new Derived()); // true 65 print(new Derived() == new Derived()); // true
66
67 print(new Symbol<String>('hi')._foo);
60 } 68 }
OLDNEW
« lib/src/js/nodes.dart ('K') | « test/codegen/expect/misc.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698