Added features to Lexical Analyser and general bug fixes