Suppress strict aliasing warnings for g++

This suppresses warnings reported by g++-4.8.2 for tests/cast.cpp about
possible violation of strict aliasing rules.