Chnage how errors are handled and positions are done
Import initial scanner code