Index: base/threading/thread_checker.h |
diff --git a/base/threading/thread_checker.h b/base/threading/thread_checker.h |
index 1d970f093ed74b4d8f71c8d0c34006a10f171f3f..87c26ec052dda948d63f376d3c65df476c6fee79 100644 |
--- a/base/threading/thread_checker.h |
+++ b/base/threading/thread_checker.h |
@@ -63,6 +63,15 @@ class ThreadCheckerDoNothing { |
// ThreadChecker thread_checker_; |
// } |
// |
+// Note that, when enabled, CalledOnValidThread() returns false when called from |
+// tasks posted to SingleThreadTaskRunners bound to different sequences, even if |
+// the tasks happen to run on the same thread (e.g. two independent TaskRunners |
+// with ExecutionMode::SINGLE_THREADED on the TaskScheduler that happen to share |
+// a thread). Also, CalledOnValidThread() returns false when called from a non- |
+// single-threaded task which is associated with a SequenceToken (e.g. a task |
+// posted with ExecutionMode::PARALLEL or ExecutionMode::SEQUENCED to the |
gab
2016/07/21 21:14:24
PARALLEL won't have a SequenceToken -- keeping the
fdoray
2016/07/25 13:24:28
keeping the example about SEQUENCED to avoid confu
gab
2016/07/25 14:09:31
Ah right, but IMO that's an implementation detail
|
+// TaskScheduler). |
+// |
// In Release mode, CalledOnValidThread will always return true. |
#if ENABLE_THREAD_CHECKER |
class ThreadChecker : public ThreadCheckerImpl { |