Avoid unused typedef warnings with clang

Clang generates warnings about unused typedefs when using BOOST_STATIC_ASSERT.
The workaround for this already exists, but for some reason is restricted to GCC 4.7+.
Since the 'unused' attribute has existed since the GCC 3.x days, we might as well enable it for any GCC 4.x, which also includes Clang, which is compatible with GCC 4.2.