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

Side by Side Diff: third_party/WebKit/Source/wtf/Functional.h

Issue 1845923005: CL for perf tryjob on android Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Source/wtf/Deque.h ('k') | third_party/WebKit/Source/wtf/HashTable.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2011 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after
233 { 233 {
234 } 234 }
235 235
236 void NEVER_INLINE checkThread() 236 void NEVER_INLINE checkThread()
237 { 237 {
238 // Function with SameThreadAffinity, including SameThreadClosure 238 // Function with SameThreadAffinity, including SameThreadClosure
239 // created by WTF::bind() or blink::createSameThreadTask(), 239 // created by WTF::bind() or blink::createSameThreadTask(),
240 // must be called and destructed on the thread where it is created. 240 // must be called and destructed on the thread where it is created.
241 // If it is intended to be used cross-thread, use 241 // If it is intended to be used cross-thread, use
242 // blink::threadSafeBind() or blink::createCrossThreadTask() instead. 242 // blink::threadSafeBind() or blink::createCrossThreadTask() instead.
243 CHECK_EQ(m_createdThread, currentThread()); 243 RELEASE_ASSERT(m_createdThread == currentThread());
244 } 244 }
245 245
246 private: 246 private:
247 const ThreadIdentifier m_createdThread; 247 const ThreadIdentifier m_createdThread;
248 }; 248 };
249 #endif 249 #endif
250 250
251 template <FunctionThreadAffinity threadAffinity, typename BoundParametersTuple, typename FunctionWrapper, typename... UnboundParameters> 251 template <FunctionThreadAffinity threadAffinity, typename BoundParametersTuple, typename FunctionWrapper, typename... UnboundParameters>
252 class PartBoundFunctionImpl; 252 class PartBoundFunctionImpl;
253 253
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
309 typedef Function<void(), CrossThreadAffinity> CrossThreadClosure; 309 typedef Function<void(), CrossThreadAffinity> CrossThreadClosure;
310 310
311 } // namespace WTF 311 } // namespace WTF
312 312
313 using WTF::Function; 313 using WTF::Function;
314 using WTF::bind; 314 using WTF::bind;
315 using WTF::SameThreadClosure; 315 using WTF::SameThreadClosure;
316 using WTF::CrossThreadClosure; 316 using WTF::CrossThreadClosure;
317 317
318 #endif // WTF_Functional_h 318 #endif // WTF_Functional_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/wtf/Deque.h ('k') | third_party/WebKit/Source/wtf/HashTable.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698