Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ TheIDE » U++ TheIDE: Compiling, Linking, Debugging of your packages » BUG?: .cpp local typedefs mess up /w BLITZ$
Re: BUG?: .cpp local typedefs mess up /w BLITZ$ [message #31120 is a reply to message #31119] Sun, 06 February 2011 14:48 Go to previous messageGo to previous message
dolik.rce is currently offline  dolik.rce
Messages: 1789
Registered: August 2008
Location: Czech Republic
Ultimate Contributor

kohait00 wrote on Sun, 06 February 2011 10:16

hi guys

i'm getting compilation errors when using blitz enabled in a szenario like the one in attachment.

i always thought cpp local typedefs were what they are.
blitz seems to mess them up intrenally.

compile w/ blitz -> error (i.e. msc9, shared)
compile w/o blitz -> ok..

same for GCC

any idea?

Hi kohati,

You are right, typedef should work only in scope where it is defined, that is single file if it is at global level. The problem is how the files are combined when using BLITZ. Since typedef can't be "undone", it is impossible for BLITZ to solve such situation.

There are two simple solutions you can try (simple==not requiring to rewrite half of your program Smile )
1) Use macros for the same effect: "typedef int _MyType_;" -> "#define _MyType_ int"
2) Switch BLITZ off for the files where you use this by adding "#pragma BLITZ_PROHIBIT"

Hope that helps,
Honza
 
Read Message
Read Message
Read Message
Previous Topic: Custom build steps includes
Next Topic: using namespace system
Goto Forum:
  


Current Time: Thu Apr 25 00:18:53 CEST 2024

Total time taken to generate the page: 0.02550 seconds