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

Unified Diff: sdk/lib/_internal/compiler/implementation/lib/isolate_patch.dart

Issue 12919011: Remove streamSpawnUri and mangler. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. Created 7 years, 9 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 | « sdk/lib/_internal/compiler/implementation/lib/isolate_helper.dart ('k') | sdk/lib/isolate/isolate.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/compiler/implementation/lib/isolate_patch.dart
diff --git a/sdk/lib/_internal/compiler/implementation/lib/isolate_patch.dart b/sdk/lib/_internal/compiler/implementation/lib/isolate_patch.dart
index 410d032422039e7bea935859f541363c18f16c98..4e6982ae430082ac93dbca7bab7d55b89829bcea 100644
--- a/sdk/lib/_internal/compiler/implementation/lib/isolate_patch.dart
+++ b/sdk/lib/_internal/compiler/implementation/lib/isolate_patch.dart
@@ -6,7 +6,9 @@
import 'dart:_isolate_helper' show IsolateNatives,
lazyPort,
- ReceivePortImpl;
+ ReceivePortImpl,
+ CloseToken,
+ JsIsolateSink;
patch class _Isolate {
patch static ReceivePort get port {
@@ -31,9 +33,33 @@ patch class _Isolate {
}
}
+patch bool _isCloseToken(var object) {
+ return identical(object, const CloseToken());
+}
+
/** Default factory for receive ports. */
patch class ReceivePort {
patch factory ReceivePort() {
return new ReceivePortImpl();
}
}
+
+patch class MessageBox {
+ patch MessageBox.oneShot() : this._oneShot(new ReceivePort());
+ MessageBox._oneShot(ReceivePort receivePort)
+ : stream = new IsolateStream._fromOriginalReceivePortOneShot(receivePort),
+ sink = new JsIsolateSink.fromPort(receivePort.toSendPort());
+
+ patch MessageBox() : this._(new ReceivePort());
+ MessageBox._(ReceivePort receivePort)
+ : stream = new IsolateStream._fromOriginalReceivePort(receivePort),
+ sink = new JsIsolateSink.fromPort(receivePort.toSendPort());
+}
+
+patch IsolateSink streamSpawnFunction(
+ void topLevelFunction(),
+ [bool unhandledExceptionCallback(IsolateUnhandledException e)]) {
+ SendPort sendPort = spawnFunction(topLevelFunction,
+ unhandledExceptionCallback);
+ return new JsIsolateSink.fromPort(sendPort);
+}
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/lib/isolate_helper.dart ('k') | sdk/lib/isolate/isolate.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698