mirror of https://github.com/davisking/dlib.git
Make Clang compile cpp11_test.cpp without warnings
Warnings about unused variables are quenched by simply incrementing the variables in question. This makes the try_compile() call in CMake succeed without warnings when checking for C++11 compatibility and using -Wall.
This commit is contained in:
parent
e9d49fee8f
commit
5cb036564c
|
@ -26,8 +26,10 @@ public:
|
|||
{
|
||||
thread_local int stuff1 = 999;
|
||||
auto x = 4;
|
||||
++stuff1;
|
||||
|
||||
decltype(x) asdf = 9;
|
||||
++asdf;
|
||||
|
||||
auto f = []() { cout << "in a lambda!" << endl; };
|
||||
f();
|
||||
|
|
Loading…
Reference in New Issue