[Python-ideas] aliasing

Terry Reedy tjreedy at udel.edu
Thu Sep 1 18:17:53 CEST 2011


On 9/1/2011 11:38 AM, Bruce Leban wrote:
> On Thu, Sep 1, 2011 at 6:19 AM, Peio Borthelle
> <peio.borthelle at gmail.com
> <mailto:peio.borthelle at gmail.com>> wrot
>     e.g. I have two images in a gui and they must stay at the same
>     position (relatively one to the other) but follow the movements of
>     the arrow keys (truthful!).

You put them in a frame so that their positions are relative to a frame 
rather than absolute pixel positions. Then you move the frame. Relative 
positioning is fundamental to computer graphics.

> What you're saying is you have objects in a gui which must be
> manipulated by simple variables rather than be encapsulated in a class.

The position should be an attribute of a class and relative to something.

> Fortran has a statement called COMMON which aliases variables.

This works because in Fortran a 'variable' is a block of memory. As I 
remember, COMMON says to reuse memory for different variables.

> It's
> useful for reshaping arrays. Other than that, it's an easy way to
> confuse programmers and the compiler.

-- 
Terry Jan Reedy




More information about the Python-ideas mailing list