Basic scanner and parser