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

Side by Side Diff: runtime/bin/dartutils.cc

Issue 9254026: Split dart:builtin into dart:builtin and dart:io. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 #include "bin/dartutils.h" 5 #include "bin/dartutils.h"
6 6
7 #include "bin/file.h" 7 #include "bin/file.h"
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "platform/globals.h" 9 #include "platform/globals.h"
10 10
11 const char* DartUtils::kDartScheme = "dart:"; 11 const char* DartUtils::kDartScheme = "dart:";
12 const char* DartUtils::kBuiltinLibURL = "dart:builtin"; 12 const char* DartUtils::kBuiltinLibURL = "dart:builtin";
13 const char* DartUtils::kCoreLibURL = "dart:core"; 13 const char* DartUtils::kCoreLibURL = "dart:core";
14 const char* DartUtils::kCoreImplLibURL = "dart:coreimpl"; 14 const char* DartUtils::kCoreImplLibURL = "dart:coreimpl";
15 const char* DartUtils::kCoreNativeWrappersLibURL = "dart:nativewrappers"; 15 const char* DartUtils::kIOLibURL = "dart:io";
16 const char* DartUtils::kNativeWrappersLibURL = "dart:nativewrappers";
17
18
16 const char* DartUtils::kIdFieldName = "_id"; 19 const char* DartUtils::kIdFieldName = "_id";
17 20
18 21
19 static const char* MapLibraryUrl(CommandLineOptions* url_mapping, 22 static const char* MapLibraryUrl(CommandLineOptions* url_mapping,
20 const char* url_string) { 23 const char* url_string) {
21 ASSERT(url_mapping != NULL); 24 ASSERT(url_mapping != NULL);
22 // We need to check if the passed in url is found in the url_mapping array, 25 // We need to check if the passed in url is found in the url_mapping array,
23 // in that case use the mapped entry. 26 // in that case use the mapped entry.
24 int len = strlen(url_string); 27 int len = strlen(url_string);
25 for (int idx = 0; idx < url_mapping->count(); idx++) { 28 for (int idx = 0; idx < url_mapping->count(); idx++) {
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 path, File::PathSeparator(), filename); 217 path, File::PathSeparator(), filename);
215 218
216 free(path); 219 free(path);
217 char* canonical_filename = File::GetCanonicalPath(absolute_filename); 220 char* canonical_filename = File::GetCanonicalPath(absolute_filename);
218 if (canonical_filename == NULL) { 221 if (canonical_filename == NULL) {
219 return absolute_filename; 222 return absolute_filename;
220 } 223 }
221 free(absolute_filename); 224 free(absolute_filename);
222 return canonical_filename; 225 return canonical_filename;
223 } 226 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698