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

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

Issue 1074223002: Update Isolate API. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix typo Created 5 years, 8 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/js_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/js_lib/isolate_patch.dart
diff --git a/sdk/lib/_internal/compiler/js_lib/isolate_patch.dart b/sdk/lib/_internal/compiler/js_lib/isolate_patch.dart
index b612cced56949081ebe6afb65137b8acae2c7d37..b01318c713da40f5ba125eae3ef779d5fe77d7e7 100644
--- a/sdk/lib/_internal/compiler/js_lib/isolate_patch.dart
+++ b/sdk/lib/_internal/compiler/js_lib/isolate_patch.dart
@@ -76,12 +76,13 @@ class Isolate {
}
@patch
- void addOnExitListener(SendPort responsePort) {
+ void addOnExitListener(SendPort responsePort, {Object response}) {
// TODO(lrn): Can we have an internal method that checks if the receiving
// isolate of a SendPort is still alive?
- var message = new List(2)
+ var message = new List(3)
..[0] = "add-ondone"
- ..[1] = responsePort;
+ ..[1] = responsePort
+ ..[2] = response;
controlPort.send(message);
}
@@ -103,16 +104,18 @@ class Isolate {
}
@patch
- void kill([int priority = BEFORE_NEXT_EVENT]) {
+ void kill({int priority: BEFORE_NEXT_EVENT}) {
controlPort.send(["kill", terminateCapability, priority]);
}
@patch
- void ping(SendPort responsePort, [int pingType = IMMEDIATE]) {
- var message = new List(3)
+ void ping(SendPort responsePort, {Object response,
+ int priority: IMMEDIATE}) {
+ var message = new List(4)
..[0] = "ping"
..[1] = responsePort
- ..[2] = pingType;
+ ..[2] = priority
+ ..[3] = response;
controlPort.send(message);
}
« no previous file with comments | « sdk/lib/_internal/compiler/js_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