Re: More efficient "global variables"

From: Kish Shen <ks15_at_icparc.ic.ac.uk>
Date: Thu 08 Apr 2004 06:28:00 PM GMT
Message-Id: <E1BBeFs-0003yI-00@holborn.icparc.ic.ac.uk>
Dear Tallys,

>  In other words, I'm using dynamic predicates to emulate
>  global variables.

As you suspected, we indeed do not recommend that you do this.

>  I'd like to know if there is another (more efficient/
>  less naive) way to do such a thing. Is this what
>  "Global References" are for? If so, are they more efficient
>  than what I'm currently doing?

There are several different ways of doing this, depending on your
requirements. The user manual chapter "Non-logical Storage and
References" discuss this, have you read it?

References would not preserve information through backtracking. Non-logical
variable may be what you want.

Cheers,

Kish
Received on Thu Apr 08 18:25:56 2004

This archive was generated by hypermail 2.1.8 : Wed 16 Nov 2005 06:07:28 PM GMT GMT