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

Unified Diff: tests/compiler/dart2js/sourcemaps/load.dart

Issue 2654023003: Add no-info mappings at start of out.js and after mapped functions (Closed)
Patch Set: Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: tests/compiler/dart2js/sourcemaps/load.dart
diff --git a/tests/compiler/dart2js/sourcemaps/load.dart b/tests/compiler/dart2js/sourcemaps/load.dart
index 29cb8e096ad660f3b5812bf66c11d17c5c2e1c45..6553a0572691bb7144e3c286c2d1dc72db8de8d2 100644
--- a/tests/compiler/dart2js/sourcemaps/load.dart
+++ b/tests/compiler/dart2js/sourcemaps/load.dart
@@ -74,21 +74,21 @@ String convertToHumanReadableSourceMap(SingleMapping sourceMap) {
} else {
position = '$line,$columnStart-';
}
+ if (needsComma) {
+ sb.write(',\n');
+ }
+ sb.write(' {"target": "$position"');
if (entry.sourceUrlId != null) {
int sourceUrlId = entry.sourceUrlId;
int sourceLine = entry.sourceLine + 1;
int sourceColumn = entry.sourceColumn + 1;
- if (needsComma) {
- sb.write(',\n');
- }
- sb.write(' {"target": "$position"');
sb.write(', "source": "$sourceUrlId:$sourceLine,$sourceColumn"');
if (entry.sourceNameId != null) {
sb.write(', "name": "${sourceMap.names[entry.sourceNameId]}"');
}
- sb.write('}');
- needsComma = true;
}
+ sb.write('}');
+ needsComma = true;
}
}
sb.write('\n ]\n');

Powered by Google App Engine
This is Rietveld 408576698