[OT] Can global variable be passed into Python function?

Grant Edwards invalid at invalid.invalid
Mon Mar 3 15:18:09 CET 2014

On 2014-03-02, Chris Angelico <rosuav at gmail.com> wrote:
> On Mon, Mar 3, 2014 at 3:55 AM, Mark Lawrence <breamoreboy at yahoo.co.uk> wrote:
>> On 02/03/2014 16:45, Grant Edwards wrote:
>>> That's irrelevent.  The actual location of the memory containing the
>>> struct object (static, stack, heap, shared) doesn't matter.  The
>>> address of the first field in a struture object _is_ the address of
>>> the structure object.
>> You say struture, I'll say structure, let's call the whole thing off :)
> Note that, technically, Grant is correct as long as you grant (heh)
> that a structure may have an invisible member, the virtual function
> table pointer. C++ only (I don't believe C has virtual functions -
> but it may have grown them in one of the newer standards), so in C,
> all members are public.

Yes. I was talking about C, not C++.  I made that quite clear in
portions of my post that have been elided.  In C there is no such
thing as a virtual table pointer.

Grant Edwards               grant.b.edwards        Yow! We have DIFFERENT
                                  at               amounts of HAIR --

More information about the Python-list mailing list