Changed asserts to LexerExceptions

closes #4