Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > C++ Moderated > Re: same name f...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 4 of 4 Topic 9513 of 10096
Post > Topic >>

Re: same name for types and variables

by Oncaphillis <oncaphillis@[EMAIL PROTECTED] > Apr 18, 2008 at 05:20 PM

red floyd wrote:

> Oncaphillis wrote:
>> Hi all,
>> 
>> Working with g++ 3.* I have to include 3rd
>> party C-headers which tend to use the same
>> name for typedefs and
>> variables
>> 
>> e.g:
>> 
>> <snip>
>> /* test.h
>>   */
>> 
>> typedef int bar;
>> 
>> struct foo {
>>    bar bar;
>> };
>> 
> 
> Find the guy who wrote that code, and shoot him.
> 

Ok.. that was my plan B. But since Mom and Dad always
told me that it is something you shouldn't do I tried
to find something else. 

So is this kind of typdef and variable name mix up
forbidden by C++ or is it just g++ that barks at
me ?

Cheers

O.


-- 
      [ See http://www.gotw.ca/resources/clcm.htm
for info about ]
      [ comp.lang.c++.moderated.    First time posters: Do this! ]
 




 4 Posts in Topic:
same name for types and variables
Oncaphillis <oncaphill  2008-04-17 11:39:21 
Re: same name for types and variables
red floyd <no.spam@[EM  2008-04-18 06:13:15 
Re: same name for types and variables
Marco Manfredini <ok_n  2008-04-18 17:15:07 
Re: same name for types and variables
Oncaphillis <oncaphill  2008-04-18 17:20:00 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Tue Oct 14 8:52:29 CDT 2008.