Re: atom_number/2: Type error

Steve Moyle <[email protected]>
Newsgroups gmane.comp.ai.prolog.swi
Message-ID <[email protected]>
Carlo is indeed correct -- or at least his fix works.

I just find a touch of irony in finding it hard to determine the underlying type of an untyped language :-)

(none the wiser, but moving forward)
>  
> Hi Steve 
> are you sure it's not already a number ? 

Still not sure :-)

> Guard the conversion with a test before: 
>  
> ( atom(A) -> atom_number(A,N) ; N = A ), 

Thanks -- this works.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.