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

Unified Diff: runtime/vm/os_thread.h

Issue 1134003005: Automatic thread cleanup on non-Windows platforms. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 years, 7 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/vm/dart_api_impl.cc ('k') | runtime/vm/os_thread_android.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/os_thread.h
===================================================================
--- runtime/vm/os_thread.h (revision 45815)
+++ runtime/vm/os_thread.h (working copy)
@@ -30,6 +30,7 @@
static ThreadId kInvalidThreadId;
typedef void (*ThreadStartFunction) (uword parameter);
+ typedef void (*ThreadDestructor) (void* parameter);
// Start a thread running the specified function. Returns 0 if the
// thread started successfuly and a system specific error code if
@@ -36,7 +37,8 @@
// the thread failed to start.
static int Start(ThreadStartFunction function, uword parameters);
- static ThreadLocalKey CreateThreadLocal();
+ // NOTE: Destructor currently ignored on Windows (issue 23474).
+ static ThreadLocalKey CreateThreadLocal(ThreadDestructor destructor = NULL);
static void DeleteThreadLocal(ThreadLocalKey key);
static uword GetThreadLocal(ThreadLocalKey key) {
return ThreadInlineImpl::GetThreadLocal(key);
« no previous file with comments | « runtime/vm/dart_api_impl.cc ('k') | runtime/vm/os_thread_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698