Implement more library functions, implement env:toNumber, fix lexer.