Updated lexer function to use a given buffer for input.
Added basic template for mctok.h