Added isEmpty function to PrecedenceGroup