Go 1.0 compat

Makes sure all functions have a return/panic.