Index: base/message_loop/message_loop.h |
diff --git a/base/message_loop/message_loop.h b/base/message_loop/message_loop.h |
index 91a7b1d33268d470ee4220202dd45734bc3d01ec..8417ce49c0cf25851fbb2fd304b0781bb48ae2ea 100644 |
--- a/base/message_loop/message_loop.h |
+++ b/base/message_loop/message_loop.h |
@@ -346,11 +346,13 @@ class BASE_EXPORT MessageLoop : public MessagePump::Delegate { |
void BindToCurrentThread(); |
private: |
- friend class RunLoop; |
friend class internal::IncomingTaskQueue; |
+ friend class RunLoop; |
friend class ScheduleWorkTest; |
friend class Thread; |
+ friend struct PendingTask; |
FRIEND_TEST_ALL_PREFIXES(MessageLoopTest, DeleteUnboundLoop); |
+ friend class PendingTaskTest; |
// Creates a MessageLoop without binding to a thread. |
// If |type| is TYPE_CUSTOM non-null |pump_factory| must be also given |
@@ -450,6 +452,13 @@ class BASE_EXPORT MessageLoop : public MessagePump::Delegate { |
debug::TaskAnnotator task_annotator_; |
+ // Used to allow creating a breadcrumb of program counters in PostTask. |
+ // This variable is only initialized while a task is being executed and is |
+ // meant only to store context for creating a backtrace breadcrumb. Do not |
+ // attach other semantics to it without thinking through the use caes |
+ // thoroughly. |
+ const PendingTask* current_pending_task_; |
+ |
scoped_refptr<internal::IncomingTaskQueue> incoming_task_queue_; |
// A task runner which we haven't bound to a thread yet. |