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

Side by Side Diff: frog/evaluator.dart

Issue 8485002: more negative test fixes (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 9 years, 1 month 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 | « no previous file | frog/frogsh » ('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) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 #import('file_system.dart'); 6 #import('file_system.dart');
7 #import('lang.dart'); 7 #import('lang.dart');
8 8
9 interface JsEvaluator { 9 interface JsEvaluator {
10 var eval(String source); 10 var eval(String source);
(...skipping 16 matching lines...) Expand all
27 _markAllUsed(world.corelib); 27 _markAllUsed(world.corelib);
28 world.gen.writeTypes(world.coreimpl); 28 world.gen.writeTypes(world.coreimpl);
29 world.gen.writeTypes(world.corelib); 29 world.gen.writeTypes(world.corelib);
30 30
31 // Set these here so that we can compile the corelib without its errors 31 // Set these here so that we can compile the corelib without its errors
32 // killing us 32 // killing us
33 options.throwOnErrors = true; 33 options.throwOnErrors = true;
34 options.throwOnFatal = true; 34 options.throwOnFatal = true;
35 } 35 }
36 36
37 // TODO(jimhug): Should be calling world.genMethod - but I'm scared to
38 // make the change myself because we don't have any test coverage here.
37 static void _markMethodUsed(Member m) { 39 static void _markMethodUsed(Member m) {
38 if (m == null || m.isGenerated || m.definition == null || m.isAbstract) { 40 if (m == null || m.isGenerated || m.definition == null || m.isAbstract) {
39 return; 41 return;
40 } 42 }
41 new MethodGenerator(m, null).run(); 43 new MethodGenerator(m, null).run();
42 } 44 }
43 45
44 // TODO(nweiz): use this logic for the --compile_all flag 46 // TODO(nweiz): use this logic for the --compile_all flag
45 static void _markAllUsed(Library l) { 47 static void _markAllUsed(Library l) {
46 if (_marked.contains(l.name)) return; 48 if (_marked.contains(l.name)) return;
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 gen.writeType(type); 130 gen.writeType(type);
129 code = gen.writer.text; 131 code = gen.writer.text;
130 } else { 132 } else {
131 parsed.visit(methGen); 133 parsed.visit(methGen);
132 code = methGen.writer.text; 134 code = methGen.writer.text;
133 } 135 }
134 136
135 return this._jsEvaluator.eval(code); 137 return this._jsEvaluator.eval(code);
136 } 138 }
137 } 139 }
OLDNEW
« no previous file with comments | « no previous file | frog/frogsh » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698