Set the visibility of method definitions.

Signed-off-by: Yorick Peterse <yorickpeterse@gmail.com>
Bail out after parser errors.

Due to a bug in the pure Ruby version of Racc it will forever hang in recovery
mode after detecting a syntax error. To work around this we'll bail out after
detecting the first one.

Signed-off-by: Yorick Peterse <yorickpeterse@gmail.com>