Fixed some minor bugs with caching with the parser