Moved the function that recovers a tree from a backpointer from PCFG to CFG class.