Subject:
|
Re: thread class for legOS
|
Newsgroups:
|
lugnet.robotics.rcx.legos
|
Date:
|
Tue, 22 Jan 2002 08:15:35 GMT
|
Viewed:
|
2198 times
|
| |
| |
On Mon, 21 Jan 2002, John A. Tamplin wrote:
> Unless you define a function as a member function, there is no this
> parameter at all. In the example given, it was not a member function at
> all (nor should it be).
In the post you replied to saying "static doesn't matter", the proposal
was:
private:
static int runWrapper(...);
I then replied to your post, etc.
Anyway, let's not degenerate into he-said-she-said. We're really just
talking past each other while agreeing, I think.
> I believe you are thinking of a static member function vs. a non-static
> member function, in which case you are correct -- a non-static member
> function will never work. However, there is no guarantee that C will be
> able to call a C++ static member function at all. It may work on many
> platforms, but the standard doesn't require it at all (in fact on most
> platforms you can probably call a member function by supplying your own
> this parameter). There are many things that C++ can do differently, such
> as handling exceptions propagated into C code. If you want to write
> portable code, you will use C linkage for any code that will be called by
> C.
Right, I was talking about member functions. You're right that it's not
portable, but I think portability is probably a pretty low concern for
most legOS programs.
--
"From now on, we live in a world where man has walked on the moon.
And it's not a miracle, we just decided to go." -- Jim Lovell
Mike Ash - <http://www.mikeash.com/>, <mailto:mail@mikeash.com>
|
|
Message is in Reply To:
| | Re: thread class for legOS
|
| (...) Unless you define a function as a member function, there is no this parameter at all. In the example given, it was not a member function at all (nor should it be). I believe you are thinking of a static member function vs. a non-static member (...) (23 years ago, 21-Jan-02, to lugnet.robotics.rcx.legos)
|
8 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|