Avoid an exception with some backend Prolog compilers when testing for the `foreign` predicate property