Bill Allombert on Thu, 17 May 2012 13:55:19 +0200

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: Re : Re: "Unknown function" message for compiled function

On Thu, May 17, 2012 at 01:16:18PM +0200, Ewan Delanoy wrote:
> Thanks Karim for your answer.
>  > why the 'local_' prefix in your (indeed, local) variable names; (to my
>  > taste) it makes the script a little harder to read.
>  Because (as far as I could understand) it seems that even though I declare a variable
>  "toto" to be local in some function, the GP interpreter will complain if I
>  try to re-use the name "toto" later as a function name.

Ah yes this was a limitation that was removed in PARI 2.5.

>  Generally speaking, my impression is that reusability of names is limited in
>  GP somehow.
>  Is that another gross misunderstanding of mine, or is there really a
>  limitation of Pari-GP on this ?

The whole interpreter was rewritten for PARI 2.5. A lot of things were improved:
now there are lexically scoped local variables, and functions are first class