Coroutine versions of built-in Prolog predicates