Multiply error detection in one compilation pass

Add to |options| new parameter: |collector|, that is object with following functions:
- emitFatalError(...)
- emitError(...)
- emitWarning(...)
- emitInfo(...)

By default, |emitFatalError| and |emitError| throws |GrammarError| with all arguments, passed to them; |emitWarning| and |emitInfo| do nothing.