Lexer: added struct LineLoc and refactored code.

* Unified lineBegin and lineNum into lineLoc.
* Reordered some members.