Does nothing if the current thread holds the mutex. Otherwise, crashes with high probability.
| 2462 | // Does nothing if the current thread holds the mutex. Otherwise, crashes |
| 2463 | // with high probability. |
| 2464 | void AssertHeld() const { |
| 2465 | GTEST_CHECK_(has_owner_ && pthread_equal(owner_, pthread_self())) |
| 2466 | << "The current thread is not holding the mutex @" << this; |
| 2467 | } |
| 2468 | |
| 2469 | // A static mutex may be used before main() is entered. It may even |
| 2470 | // be used before the dynamic initialization stage. Therefore we |
nothing calls this directly
no outgoing calls
no test coverage detected