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

Unified Diff: frog/world.dart

Issue 8481023: cleanup errors and fix a couple field negative tests (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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « frog/value.dart ('k') | tests/language/language.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: frog/world.dart
diff --git a/frog/world.dart b/frog/world.dart
index 8a7e58b173a70cfea592a66d27c52fb076910958..92e90250e6bb4346dc5d3b6138ffd1e8fad85f54 100644
--- a/frog/world.dart
+++ b/frog/world.dart
@@ -360,7 +360,7 @@ class World {
// ********************** Message support ***********************
void _message(String message, SourceSpan span, SourceSpan span1,
- bool throwing) {
+ SourceSpan span2, bool throwing) {
var text = message;
if (span != null) {
text = span.toMessageString(message);
@@ -369,6 +369,9 @@ class World {
if (span1 != null) {
print(span1.toMessageString(message));
}
+ if (span2 != null) {
+ print(span2.toMessageString(message));
+ }
if (throwing) {
throw new CompilerException(message, span);
@@ -376,39 +379,39 @@ class World {
}
/** [message] is considered a static compile-time error by the Dart lang. */
- void error(String message, [SourceSpan span, SourceSpan span1]) {
+ void error(String message, [SourceSpan span, SourceSpan span1, SourceSpan span2]) {
errors++;
- _message('error: $message', span, span1, options.throwOnErrors);
+ _message('error: $message', span, span1, span2, options.throwOnErrors);
}
/** [message] is considered a type warning by the Dart lang. */
- void warning(String message, [SourceSpan span, SourceSpan span1]) {
+ void warning(String message, [SourceSpan span, SourceSpan span1, SourceSpan span2]) {
warnings++;
if (options.showWarnings) {
- _message('warning: $message', span, span1, options.throwOnWarnings);
+ _message('warning: $message', span, span1, span2, options.throwOnWarnings);
}
}
/** [message] at [location] is so bad we can't generate runnable code. */
- void fatal(String message, [SourceSpan span, SourceSpan span1]) {
+ void fatal(String message, [SourceSpan span, SourceSpan span1, SourceSpan span2]) {
errors++;
seenFatal = true;
- _message('fatal: $message', span, span1,
+ _message('fatal: $message', span, span1, span2,
options.throwOnFatal || options.throwOnErrors);
}
/** [message] at [location] is about a bug in the compiler. */
- void internalError(String message, [SourceSpan span, SourceSpan span1]) {
- _message('We are sorry, but... $message', span, span1, true);
+ void internalError(String message, [SourceSpan span, SourceSpan span1, SourceSpan span2]) {
+ _message('We are sorry, but... $message', span, span1, span2, true);
}
/**
* [message] at [location] will tell the user about what the compiler
* is doing.
*/
- void info(String message, [SourceSpan span, SourceSpan span1]) {
+ void info(String message, [SourceSpan span, SourceSpan span1, SourceSpan span2]) {
if (options.showInfo) {
- _message('info: $message', span, span1, false);
+ _message('info: $message', span, span1, span2, false);
}
}
« no previous file with comments | « frog/value.dart ('k') | tests/language/language.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698