Turning on warnings as errors

This is a bit sub-optimal, but please give some feedback, and suggest improvements.