fixing bugs in kast parser