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

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

Issue 867113003: Revert r43217, r43215, r43208, r43207, and r43202. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 10 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
« no previous file with comments | « runtime/bin/builtin.h ('k') | runtime/bin/builtin.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 <stdio.h> 5 #include <stdio.h>
6 6
7 #include "include/dart_api.h" 7 #include "include/dart_api.h"
8 8
9 #include "bin/builtin.h" 9 #include "bin/builtin.h"
10 #include "bin/dartutils.h" 10 #include "bin/dartutils.h"
11 #include "bin/platform.h"
12 11
13 namespace dart { 12 namespace dart {
14 namespace bin { 13 namespace bin {
15 14
16 Builtin::builtin_lib_props Builtin::builtin_libraries_[] = { 15 Builtin::builtin_lib_props Builtin::builtin_libraries_[] = {
17 /* { url_, source_, patch_url_, patch_source_, has_natives_ } */ 16 /* { url_, source_, patch_url_, patch_source_, has_natives_ } */
18 { DartUtils::kBuiltinLibURL, _builtin_source_paths_, NULL, NULL, true }, 17 { DartUtils::kBuiltinLibURL, _builtin_source_paths_, NULL, NULL, true },
19 { DartUtils::kIOLibURL, io_source_paths_, 18 { DartUtils::kIOLibURL, io_source_paths_,
20 DartUtils::kIOLibPatchURL, io_patch_paths_, true }, 19 DartUtils::kIOLibPatchURL, io_patch_paths_, true },
21 }; 20 };
22 21
23 Dart_Port Builtin::load_port_ = ILLEGAL_PORT;
24 22
25 // Patch all the specified patch files in the array 'patch_files' into the 23 // Patch all the specified patch files in the array 'patch_files' into the
26 // library specified in 'library'. 24 // library specified in 'library'.
27 static void LoadPatchFiles(Dart_Handle library, 25 static void LoadPatchFiles(Dart_Handle library,
28 const char* patch_uri, 26 const char* patch_uri,
29 const char** patch_files) { 27 const char** patch_files) {
30 for (intptr_t j = 0; patch_files[j] != NULL; j += 2) { 28 for (intptr_t j = 0; patch_files[j] != NULL; j += 2) {
31 Dart_Handle patch_src = DartUtils::ReadStringFromFile(patch_files[j + 1]); 29 Dart_Handle patch_src = DartUtils::ReadStringFromFile(patch_files[j + 1]);
32 30
33 // Prepend the patch library URI to form a unique script URI for the patch. 31 // Prepend the patch library URI to form a unique script URI for the patch.
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 Dart_Handle library = Dart_LookupLibrary(url); 111 Dart_Handle library = Dart_LookupLibrary(url);
114 if (Dart_IsError(library)) { 112 if (Dart_IsError(library)) {
115 library = LoadLibrary(url, id); 113 library = LoadLibrary(url, id);
116 } 114 }
117 DART_CHECK_VALID(library); 115 DART_CHECK_VALID(library);
118 return library; 116 return library;
119 } 117 }
120 118
121 } // namespace bin 119 } // namespace bin
122 } // namespace dart 120 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/bin/builtin.h ('k') | runtime/bin/builtin.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698