MyDeveloperDay added a comment. This looks good to me but I would wait for one of @JonasToth or @alexfh to perhaps take a look,
maybe you should add some nested scope example too using the same name, I know the compiler should warn about a shadow variable anyway but std::mutex m; m.lock(); { std::mutex m; m.lock(); m.unlock(); } m_unlock(); and what about std::mutex m1; std::mutex m2; m1.lock(); m1.unlock(); m2.lock(); m2.unlock(); and std::mutex m1; std::mutex m2; m1.lock(); m2.lock(); m2.unlock(); m1.unlock(); std::mutex m1; std::mutex m2; m1.lock(); m1.unlock(); m2.lock(); m2.unlock(); std::mutex m1; std::mutex m2; m1.lock(); m2.lock(); m1.unlock(); m2.unlock(); Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58818/new/ https://reviews.llvm.org/D58818 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits