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

Side by Side Diff: dart/frog/tests/leg/src/mock_compiler.dart

Issue 9724032: Resolve type Dynamic and implement black listing. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Address review comments Created 8 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « dart/frog/leg/warnings.dart ('k') | dart/tests/co19/co19-leg.status » ('j') | 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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 #library('mock_compiler'); 5 #library('mock_compiler');
6 6
7 #import("../../../../lib/uri/uri.dart"); 7 #import("../../../../lib/uri/uri.dart");
8 8
9 #import("../../../leg/elements/elements.dart"); 9 #import("../../../leg/elements/elements.dart");
10 #import("../../../leg/io/io.dart", prefix: 'io'); 10 #import("../../../leg/io/io.dart", prefix: 'io');
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 super.withCurrentDirectory(io.getCurrentDirectory()) { 60 super.withCurrentDirectory(io.getCurrentDirectory()) {
61 Uri uri = new Uri(scheme: "source"); 61 Uri uri = new Uri(scheme: "source");
62 var script = new Script(uri, new MockFile(coreSource)); 62 var script = new Script(uri, new MockFile(coreSource));
63 coreLibrary = new LibraryElement(script); 63 coreLibrary = new LibraryElement(script);
64 parseScript(coreSource, coreLibrary); 64 parseScript(coreSource, coreLibrary);
65 script = new Script(uri, new MockFile(helperSource)); 65 script = new Script(uri, new MockFile(helperSource));
66 jsHelperLibrary = new LibraryElement(script); 66 jsHelperLibrary = new LibraryElement(script);
67 parseScript(helperSource, jsHelperLibrary); 67 parseScript(helperSource, jsHelperLibrary);
68 scanner.importLibrary(jsHelperLibrary, coreLibrary, null); 68 scanner.importLibrary(jsHelperLibrary, coreLibrary, null);
69 mainApp = mockLibrary(this, ""); 69 mainApp = mockLibrary(this, "");
70 objectClass = coreLibrary.find(Compiler.OBJECT); 70 initializeSpecialClasses();
71 closureClass = jsHelperLibrary.find(Compiler.CLOSURE);
72 } 71 }
73 72
74 void reportWarning(Node node, var message) { 73 void reportWarning(Node node, var message) {
75 warnings.add(new WarningMessage(node, message.message)); 74 warnings.add(new WarningMessage(node, message.message));
76 } 75 }
77 76
78 void reportError(Node node, var message) { 77 void reportError(Node node, var message) {
79 errors.add(new WarningMessage(node, message.message)); 78 errors.add(new WarningMessage(node, message.message));
80 } 79 }
81 80
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 importLibrary(library, compiler.coreLibrary, compiler); 183 importLibrary(library, compiler.coreLibrary, compiler);
185 return library; 184 return library;
186 } 185 }
187 186
188 class StringScript extends Script { 187 class StringScript extends Script {
189 final String code; 188 final String code;
190 StringScript(this.code) : super(null, null); 189 StringScript(this.code) : super(null, null);
191 String get text() => code; 190 String get text() => code;
192 String get name() => "mock script"; 191 String get name() => "mock script";
193 } 192 }
OLDNEW
« no previous file with comments | « dart/frog/leg/warnings.dart ('k') | dart/tests/co19/co19-leg.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698