Split the parser out from the core

The core is too big to manage. The parser is a good sized, fairly self contained, block to move to it's own module.