[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Groff] question regarding PIC and variable scoping
From: |
Werner LEMBERG |
Subject: |
Re: [Groff] question regarding PIC and variable scoping |
Date: |
Tue, 25 Jun 2002 11:09:39 +0200 (CEST) |
> Adding the suggested functionality is ambiguous:
> Change the example to
> A: [
> box
> x = 5
> ]
> print A.x
> Now, what is the value of A.x? Better to remove "variable or"
> from the documentation and add the example as proposed.
As mentioned in another mail, I've removed that `variable or'.
Your example doesn't work. Similar to suffixes like `.e' or `.ne',
`.x' is also a predefined suffix which gives the x component of a
location. The right mechanism to get the variable's value is using
`:=':
x = 0
[
box
x := 5
]
print x
Werner