laas/metapod — pull request #30 by sbarthelemy (2013-01-09 18:34:37+00:00)
Title: choose STATIC_ASSERT implementation automatically

This commit removes the need for the USE_C11_STATIC_ASSERT option.

This option is annoying because

* it is one more option to deal with
* it is not prefixed with METAPOD
* C11 is can lead to confusions with the C version [1], CXX11 would
have been better.

With this commit the compiler support for C++11-like static assert is
inferred from 1) the __cplusplus version 2) the boost config library.

I checked that with gcc 4.6.3 and boost 1.50, it is able to detect when
the -std=c++0x is provided or not to gcc.

If such support is detected, it is used.

If it is not available, but boost >1.40 is, boost implementation is used
instead.

(Olivier reports that version 1.40 does not work, a link to a changelog or a
bug report is welcome).

Otherwise a no-op implementation is defined.

This commit adds a dependancy on boost. Since we will soon depend on boost
fusion anyway, I think it is ok.

[1] http://en.wikipedia.org/wiki/C11_%28C_standard_revision%29