WIP version of Prolog parser