sanity check template parameters at compile time

in c++11 we can now sanity check the template parameters of the
different data structures used in the library using static_assert.
this commit introduces basic checks to all applicable data structures in
the library.
Merge pull request #29 from mpetri/c++11

sanity check template parameters at compile time