🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #5095

Re: access Windows API

#5095
From: Remy Lebeau (TeamB)
Date: Mon, 03 Oct 2005 17:11
27 lines
2188 bytes
"Geert Verdoolaege" <Geert.Verdoolaege@telenet.be> wrote in message
news:43414545$1@newsgroups.borland.com...

> > Try ::GetCurrentThread()
>
> Doesn't help.

Yes, it does.  By prepending "::" to the beginning, you are forcing the
compiler to call the version of GetCurrentThread() that is in the global
namespace.  Microsoft uses the global namespace for all API functions and
structures.  IOTAProcess60's copy of GetCurrentThread() is not in the global
namespace.

Besides, IOTAProcess60 is a class (well, an interface).  You cannot call
IOTAProcess60::GetCurrentThread() without invoking it via a pointer to an
IOTAProcess60 instance.  The only way you can call GetCurrentThread() by
itself and have it invoke IOTAProcess60::GetCurrentThread() is if you are
writing your own class that is derived from IOTAProcess60 and then call
GetCurrentThread() from inside a method of your class.  Then
IOTAProcess60::GetCurrentThread() would be getting called via the class's
'this' pointer.  However prepending "::" to GetCurrentThread() would still
force the compiler to call the GetCurrentThread() this is in the global
namespace, not the IOTAProcess60::GetCurrentThread() method.


Gambit
Technical Details
Message-ID: <43416634@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!news.moat.net!news-out.newsfeeds.com!propagator3-LAX.newsfeeds.com!news-in.spamkiller.net!news-in.superfeed.net!caladan.landsraad.net!newsgroups.borland.com!not-for-mail
References: <4340e5e5$1@newsgroups.borland.com> <4340fb91$1@newsgroups.borland.com> <43414545$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,d676f1ab4b4ec6fd
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <4340e5e5$1@newsgroups.borland.com> <4340fb91$1@newsgroups.borland.com> <43414545$1@newsgroups.borland.com>
Subject: Re: access Windows API
Date: Mon, 3 Oct 2005 10:11:48 -0700
Lines: 29
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
NNTP-Posting-Host: 68.69.17.41
Message-ID: <43416634@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1128359476 68.69.17.41 (3 Oct 2005 10:11:16 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!news.moat.net!news-out.newsfeeds.com!propagator3-LAX.newsfeeds.com!news-in.spamkiller.net!news-in.superfeed.net!caladan.landsraad.net!newsgroups.borland.com!not-for-mail