Re: [eclipse-clp-users] Accessing Eclipse predicates

From: Volkan Unsal <spocksplanet_at_...6...>
Date: Thu, 15 Aug 2013 23:37:11 -0400
I mean the string(A) or integer(A). They return a yes or no on the
commandline, but I am wondering if they can be used within the program as
well.



On Thu, Aug 15, 2013 at 11:19 PM, <mskala_at_...206...> wrote:

> On Thu, 15 Aug 2013, Volkan Unsal wrote:
> > Being new to Eclipse, I am trying to understand some basic concepts. I
> don't
> > understand why are some Eclipse predicates not available from inside
> loops.
> > For example:
> > # test.ecl
> > main :-
> >   (foreach(A,[1,2]) do
> >       Z is string(A),
> >       writeln( Z )
> >     ).
>
> It's nothing to do with loops.  "Z is string(A)" would be an error
> outside a loop too; "is" is only for doing arithmetic.
>
> > These are available from the command line when I query the data, but not
> > from within the program. How do I do type checking on the variables if I
> > can't use these...?
>
> What exactly do you mean by "these"?  What are you typing on the
> command line?
>
> --
> Matthew Skala
> mskala_at_...206...                 People before principles.
> http://ansuz.sooke.bc.ca/
Received on Fri Aug 16 2013 - 03:37:48 CEST

This archive was generated by hypermail 2.3.0 : Tue Apr 16 2024 - 09:13:20 CEST