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

Unified Diff: runtime/lib/isolate.cc

Issue 9422019: isolates refactor: this change introduces 'dart:isolate' as a library. This is a (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: '' Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/bin/io.dart ('k') | runtime/lib/isolate.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/lib/isolate.cc
diff --git a/runtime/lib/isolate.cc b/runtime/lib/isolate.cc
index 08a6f71ac7f9f790441431937a766704822428d2..efeea7b7871acb1464a983563a20666f404f7cab 100644
--- a/runtime/lib/isolate.cc
+++ b/runtime/lib/isolate.cc
@@ -83,14 +83,16 @@ static void ThrowErrorException(Exceptions::ExceptionType type,
// TODO(turnidge): Move to DartLibraryCalls.
RawObject* ReceivePortCreate(intptr_t port_id) {
+ Library& isolate_lib = Library::Handle(Library::IsolateLibrary());
+ ASSERT(!isolate_lib.IsNull());
const String& class_name =
- String::Handle(String::NewSymbol("ReceivePortImpl"));
+ String::Handle(isolate_lib.PrivateName("_ReceivePortImpl"));
const String& function_name =
String::Handle(String::NewSymbol("_get_or_create"));
const int kNumArguments = 1;
const Array& kNoArgumentNames = Array::Handle();
const Function& function = Function::Handle(
- Resolver::ResolveStatic(Library::Handle(Library::CoreLibrary()),
+ Resolver::ResolveStatic(isolate_lib,
class_name,
function_name,
kNumArguments,
@@ -109,12 +111,15 @@ RawObject* ReceivePortCreate(intptr_t port_id) {
// TODO(turnidge): Move to DartLibraryCalls.
static RawObject* SendPortCreate(intptr_t port_id) {
- const String& class_name = String::Handle(String::NewSymbol("SendPortImpl"));
+ Library& isolate_lib = Library::Handle(Library::IsolateLibrary());
+ ASSERT(!isolate_lib.IsNull());
+ const String& class_name =
+ String::Handle(isolate_lib.PrivateName("_SendPortImpl"));
const String& function_name = String::Handle(String::NewSymbol("_create"));
const int kNumArguments = 1;
const Array& kNoArgumentNames = Array::Handle();
const Function& function = Function::Handle(
- Resolver::ResolveStatic(Library::Handle(Library::CoreLibrary()),
+ Resolver::ResolveStatic(isolate_lib,
class_name,
function_name,
kNumArguments,
« no previous file with comments | « runtime/bin/io.dart ('k') | runtime/lib/isolate.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698