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

Side by Side Diff: lib/isolate/isolate_leg.dart

Issue 9702074: Add support for capturing and changing the current isolate in the closure wrapper. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 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 unified diff | Download patch | Annotate | Revision Log
« frog/leg/ssa/builder.dart ('K') | « frog/leg/ssa/builder.dart ('k') | no next file » | 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 5
6 /** 6 /**
7 * The `dart:isolate` library defines APIs to spawn and communicate with 7 * The `dart:isolate` library defines APIs to spawn and communicate with
8 * isolates. 8 * isolates.
9 * 9 *
10 * All code in dart runs in the context of an isolate. Each isolate has its own 10 * All code in dart runs in the context of an isolate. Each isolate has its own
(...skipping 25 matching lines...) Expand all
36 */ 36 */
37 #library("dart:isolate"); 37 #library("dart:isolate");
38 38
39 //#import("../uri/uri.dart"); 39 //#import("../uri/uri.dart");
40 #import("../../frog/leg/lib/uri_toremove.dart"); 40 #import("../../frog/leg/lib/uri_toremove.dart");
41 #source("isolate_api.dart"); 41 #source("isolate_api.dart");
42 #source("frog/compiler_hooks.dart"); 42 #source("frog/compiler_hooks.dart");
43 #source("frog/isolateimpl.dart"); 43 #source("frog/isolateimpl.dart");
44 #source("frog/ports.dart"); 44 #source("frog/ports.dart");
45 #source("frog/messages.dart"); 45 #source("frog/messages.dart");
46
47 /**
48 * These methods are called by the compiler to support switching
ahe 2012/03/16 14:03:16 A documentation comment only applies to one elemen
ngeoffray 2012/03/19 10:29:58 Done.
49 * between isolates when we get a callback from the DOM.
50 */
51 void _callInIsolate(IsolateContext isolate, Function function) {
ahe 2012/03/16 14:03:16 I would rather have these methods in js_helper.
ngeoffray 2012/03/19 10:29:58 I agree, and maybe long-term that's what will happ
52 isolate.eval(function);
53 _globalState.topEventLoop.run();
54 }
55
56 void _currentIsolate() => _globalState.currentContext;
OLDNEW
« frog/leg/ssa/builder.dart ('K') | « frog/leg/ssa/builder.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698