Correctly propagate errors.

Part of the solution to chrisdickinson/glsl-parser#5