| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "base/basictypes.h" | 5 #include "base/basictypes.h" |
| 6 #include "base/logging.h" | 6 #include "base/logging.h" |
| 7 #include "base/memory/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
| 8 #include "base/threading/thread_checker.h" | 8 #include "base/threading/thread_checker.h" |
| 9 #include "base/threading/simple_thread.h" | 9 #include "base/threading/simple_thread.h" |
| 10 #include "testing/gtest/include/gtest/gtest.h" | 10 #include "testing/gtest/googletest/include/gtest/gtest.h" |
| 11 | 11 |
| 12 // Duplicated from base/threading/thread_checker.h so that we can be | 12 // Duplicated from base/threading/thread_checker.h so that we can be |
| 13 // good citizens there and undef the macro. | 13 // good citizens there and undef the macro. |
| 14 #if !defined(NDEBUG) || defined(DCHECK_ALWAYS_ON) | 14 #if !defined(NDEBUG) || defined(DCHECK_ALWAYS_ON) |
| 15 #define ENABLE_THREAD_CHECKER 1 | 15 #define ENABLE_THREAD_CHECKER 1 |
| 16 #else | 16 #else |
| 17 #define ENABLE_THREAD_CHECKER 0 | 17 #define ENABLE_THREAD_CHECKER 0 |
| 18 #endif | 18 #endif |
| 19 | 19 |
| 20 namespace base { | 20 namespace base { |
| (...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 170 ThreadCheckerClass::DetachThenCallFromDifferentThreadImpl(); | 170 ThreadCheckerClass::DetachThenCallFromDifferentThreadImpl(); |
| 171 } | 171 } |
| 172 #endif // ENABLE_THREAD_CHECKER | 172 #endif // ENABLE_THREAD_CHECKER |
| 173 | 173 |
| 174 #endif // GTEST_HAS_DEATH_TEST || !ENABLE_THREAD_CHECKER | 174 #endif // GTEST_HAS_DEATH_TEST || !ENABLE_THREAD_CHECKER |
| 175 | 175 |
| 176 // Just in case we ever get lumped together with other compilation units. | 176 // Just in case we ever get lumped together with other compilation units. |
| 177 #undef ENABLE_THREAD_CHECKER | 177 #undef ENABLE_THREAD_CHECKER |
| 178 | 178 |
| 179 } // namespace base | 179 } // namespace base |
| OLD | NEW |