Registered Member
|
Hi,
our project uses libeigen for some linear algebra stuff. Generally we use g++ for compilation but clang++ would be fine too. When we compile with clang++ we get tons of compiler warnings inside of libeigen code. I will give some examples here:
So is there a way to silence those warnings related to libeigen code while beeing verbose at our code? How do you handle such situations? Thanks for any suggestions and recommendations. |
Registered Member
|
n=n is probably to avoid 'unused' warnings.
Qt for example avoids these warnings by using this macro:
so you can use
Maybe this is a good approach also for Eigen? |
Registered Member
|
As there are many diffrent warnings, not only related to self assignments, I thought there would be a better way to disable all warnings related to a certain lib...
|
Registered Member
|
I also used clang++. My way of processing this is:
clang++ -isystem <the_eigen_path> ..... instead of clang++ -I<the_eigen_path> By using -isystem, the compiler will suppress all warnings arising from inside the files in the eigen directory. (The same trick also applies to g++) |
Registered Member
|
Great with CMake and this http://stackoverflow.com/questions/3371 ... with-cmake I got it running and now can focus only our code. Thanks for this hint.
|
Registered Member
|
It would also be a good idea to upgrade Eigen. I think that the issues you are referring to were fixed in Eigen 3.0.2, released in August last year. The latest (stable) release is Eigen 3.0.5.
|
Registered users: Bing [Bot], claydoh, Google [Bot], rblackwell, Yahoo [Bot]