C++Talk.NET Forum Index C++Talk.NET
C++ language newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

brackets issue specifying ::*s

 
Post new topic   Reply to topic    C++Talk.NET Forum Index -> C++ Language (Moderated)
View previous topic :: View next topic  
Author Message
Phil Carmody
Guest





PostPosted: Thu Sep 25, 2003 1:50 pm    Post subject: brackets issue specifying ::*s Reply with quote



Greetings all,

I've always been a bit of a excessive bracketer, and have recently
been stung by g++-3.0 barfing
"kbitmap.c:161: address of overloaded function with no contextual type information"
at:

commit =
(kremoval==1) ? &(kbitmap::commit1)
: (kremoval==2) ? &(kbitmap::commit2)
: &(kbitmap::commitmany);

2.95 was quite happy with it, for example. (They're just member
functions with identical type, and commit is pointer to same,
obviously.)

I can 'fix' it simply by changing to

commit =
(kremoval==1) ? &kbitmap::commit1
: (kremoval==2) ? &kbitmap::commit2
: &kbitmap::commitmany;

Is this a g++ quirk, or is there genuinely something different between
"class::method" and "(class::method)"?

They'll be adding white-space sensitivity next!?!?

Phil
(yes, I know! Smile )

[ See http://www.gotw.ca/resources/clcm.htm for info about ]
[ comp.lang.c++.moderated. First time posters: Do this! ]
Back to top
Display posts from previous:   
Post new topic   Reply to topic    C++Talk.NET Forum Index -> C++ Language (Moderated) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.