minor improvements
more testing and missing (and 'extra') tokens added
minor fix