Add ability to override defaults with ease.

Add the 'has_observers' method. Add GCC warning disable pragmas.
Fix some potential scope problems depending on compiler. Selectively
include stdint on mingw.