Parser cleanup and organization