See Static Assertions for details about how to use static_assert., which is one of the C++0x features.