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: pkg/dev_compiler/lib/src/compiler/compiler.dart

Issue 2811343002: Dev compiler debugger related tweaks. (Closed)
Patch Set: Dev compiler debugger related tweaks. Created 3 years, 8 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
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 import 'dart:collection' show HashSet, Queue; 5 import 'dart:collection' show HashSet, Queue;
6 import 'dart:convert' show JSON; 6 import 'dart:convert' show JSON;
7 import 'dart:io' show File; 7 import 'dart:io' show File;
8 8
9 import 'package:analyzer/analyzer.dart' 9 import 'package:analyzer/analyzer.dart'
10 show AnalysisError, CompilationUnit, ErrorSeverity; 10 show AnalysisError, CompilationUnit, ErrorSeverity;
(...skipping 584 matching lines...) Expand 10 before | Expand all | Expand 10 after
595 595
596 for (int i = 0; i < list.length; i++) { 596 for (int i = 0; i < list.length; i++) {
597 list[i] = transformUri(list[i]); 597 list[i] = transformUri(list[i]);
598 } 598 }
599 map['file'] = transformUri(map['file']); 599 map['file'] = transformUri(map['file']);
600 return map; 600 return map;
601 } 601 }
602 602
603 /// Cleanup the dart_sdk source map. 603 /// Cleanup the dart_sdk source map.
604 /// 604 ///
605 /// Strip out files that should not be included in the sdk sourcemap as they
606 /// are implementation details that would just confuse users.
607 /// Normalize sdk urls to use "dart:" for more understandable stack traces. 605 /// Normalize sdk urls to use "dart:" for more understandable stack traces.
608 Map cleanupSdkSourcemap(Map sourceMap) { 606 Map cleanupSdkSourcemap(Map sourceMap) {
609 var map = new Map.from(sourceMap); 607 var map = new Map.from(sourceMap);
610 map['sources'] = map['sources'] 608 map['sources'] = map['sources'].map((url) {
611 .map((url) => url.contains('/_internal/') ? null : url) 609 var urlPrefix = '../../../gen/patched_sdk/lib/';
612 .toList(); 610 if (!url.startsWith(urlPrefix)) throw new Error('Unexpected sdk url: $url');
611 return 'dart:${url.substring(urlPrefix.length)}';
612 }).toList();
613 return map; 613 return map;
614 } 614 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698