This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: threads in C++

Mike Stump wrote:

> > Date: Mon, 15 Nov 1999 12:14:22 -0500
> > From: Dima Volodin <>
> > > Not necessarily. You could use a static member function. But if you need
> > > to get at object data, you'll have to get that passed in explicitly.
> > POSIX doesn't say you can use a "static member function", ergo you
> > can not. If the trick works for g++, it doesn't mean it will work
> > for any other compiler.
> They also don't say that you can do with with functions named foo, but
> guess what, you can.

Guess what, you can't. Unless foo is a C function whose type is void*(void*),
in which case POSIX together with the C Language standard (all of them) say
that it doesn't really matter if it's foo or bar or baz.

>  Or let me put this another way, C++ guarantees
> that this can be done.

Now would you care to quote the appropriate part of the C++ Standard that
guarantees you that? The problem is that parts from Bjarne Stroustrup's book
and from the Standard that were referenced and quoted in my exchange with
Jonathan Larmour state something very different, that is that C++ _doesn't_
guarantee you that.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]