A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2002-April/023509.html below:

[Python-Dev] LOAD_NAME & classes

[Python-Dev] LOAD_NAME & classes [Python-Dev] LOAD_NAME & classesAlex Martelli aleax@aleax.it
Wed, 24 Apr 2002 09:38:39 +0200
On Wednesday 24 April 2002 04:40, Greg Ewing wrote:
> Michael Gilfix <mgilfix@eecs.tufts.edu>:
> > The our is akin to declaring something static in C.
>
> Except that it sounds like if two functions declare
> "our" variables with the same name, they get the
> same variable, whereas in C they would be different
> variables. (I think -- it just occurred to me that
> I'm not really sure about that!)

You think correctly: two C functions declaring static
function-scope variables with the same name get
different variables.  static variables at FILE scope are
'shared' throughout the file, but not between files.


Alex




RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4