Page 1 of 1

Declaring predicates containing elipse

Posted: 4 Jan 2020 14:51
by daveplummermd
How do I declare the predicates supporting the following?

Code: Select all

clauses ppp(...) :- W = { () :- stdio::write(...) }, qqq(W).
I am working through the examples included in the document "Language Reference/Terms", under the heading "Capturing ellipsis (...)". The above code is included to illustrate, and I am including it in a program so that I can use debug to follow and learn.

I am declaring ppp:

Code: Select all

predicates     ppp : (...).
How do I declare qqq ?

Thanks in advance

Re: Declaring predicates containing elipse

Posted: 4 Jan 2020 16:22
by Thomas Linder Puls
The predicate takes a predicate without arguments (e. g. a runnable) as argument

Code: Select all

predicates     qqq : (core::runnable Action).

Re: Declaring predicates containing elipse

Posted: 4 Jan 2020 17:40
by daveplummermd
Thanks you.