OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 command_line_config; | 5 library command_line_config; |
6 | 6 |
7 import 'dart:io'; | 7 import 'dart:io'; |
8 | 8 |
9 import '../../../pkg/path/lib/path.dart' as path; | 9 import '../../../pkg/pathos/lib/path.dart' as path; |
10 import '../../../pkg/unittest/lib/unittest.dart'; | 10 import '../../../pkg/unittest/lib/unittest.dart'; |
11 import '../../pub/utils.dart'; | 11 import '../../pub/utils.dart'; |
12 | 12 |
13 /// Gets a "special" string (ANSI escape or Unicode). On Windows, returns | 13 /// Gets a "special" string (ANSI escape or Unicode). On Windows, returns |
14 /// something else since those aren't supported. | 14 /// something else since those aren't supported. |
15 String _getSpecial(String color, [String onWindows = '']) { | 15 String _getSpecial(String color, [String onWindows = '']) { |
16 // No ANSI escapes on windows. | 16 // No ANSI escapes on windows. |
17 if (Platform.operatingSystem == 'windows') return onWindows; | 17 if (Platform.operatingSystem == 'windows') return onWindows; |
18 return color; | 18 return color; |
19 } | 19 } |
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
159 var library = match[2]; | 159 var library = match[2]; |
160 if (!isCore) { | 160 if (!isCore) { |
161 // Make the library path relative to the entrypoint. | 161 // Make the library path relative to the entrypoint. |
162 library = path.relative(library); | 162 library = path.relative(library); |
163 } | 163 } |
164 | 164 |
165 var member = match[1].replaceAll("<anonymous closure>", _lambda); | 165 var member = match[1].replaceAll("<anonymous closure>", _lambda); |
166 return new _StackFrame._(isCore, library, match[3], match[4], member); | 166 return new _StackFrame._(isCore, library, match[3], match[4], member); |
167 } | 167 } |
168 } | 168 } |
OLD | NEW |