Chromium Code Reviews| Index: runtime/bin/builtin.cc |
| diff --git a/runtime/bin/builtin.cc b/runtime/bin/builtin.cc |
| index f6d297e9c8435400cc0f83f30b2803f9a150fdfd..5de4f64de8c55e5193735ef5ddef37935f0106b1 100644 |
| --- a/runtime/bin/builtin.cc |
| +++ b/runtime/bin/builtin.cc |
| @@ -30,6 +30,13 @@ Dart_Handle Builtin::Source(BuiltinLibraryId id) { |
| } |
| +Dart_NativeFunction Builtin::NativeLookup(Dart_Handle name, |
| + int argument_count) { |
| + UNREACHABLE(); |
| + return NULL; |
| +} |
| + |
| + |
| void Builtin::SetNativeResolver(BuiltinLibraryId id) { |
| UNREACHABLE(); |
| } |
| @@ -45,7 +52,11 @@ Dart_Handle Builtin::LoadAndCheckLibrary(BuiltinLibraryId id) { |
| library = Dart_LoadLibrary(url, Source(id)); |
| if (!Dart_IsError(library) && (builtin_libraries_[id].has_natives_)) { |
| // Setup the native resolver for built in library functions. |
| - DART_CHECK_VALID(Dart_SetNativeResolver(library, NativeLookup)); |
| + // Looks up native functions only in libdart_builtin, not libdart_io. |
| + // This is for use in the snapshot generator, which must not link with |
|
Mads Ager (google)
2012/11/08 09:32:26
Instead of focusing this comment on the problem ca
|
| + // the native implementations for libdart_io, to break the dependence |
| + // of Dartium on our copies of NSS and NSPR (secure networking libraries). |
| + DART_CHECK_VALID(Dart_SetNativeResolver(library, BuiltinNativeLookup)); |
| } |
| if (builtin_libraries_[id].patch_url_ != NULL) { |
| ASSERT(builtin_libraries_[id].patch_source_ != NULL); |