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: Other Features Wishlist and/or Bugs » Question about Blitz (bug?)
Question about Blitz (bug?) [message #22013] Sun, 14 June 2009 21:50 Go to next message
janwilmans is currently offline  janwilmans
Messages: 51
Registered: January 2007
Member

My existing projects often do not build using Blitz.
When Blitz is turned of there is no problem.

The problem lies in (re-)defining macros in different files.

suppose: foo.cpp has:

#define FOOBAR foo

and bar.cpp has:

#define FOOBAR bar

normally these definitions stay within the scope of the file, but with blitz on, they seem to clash?

I this normal behaviour for blitz? and should I just disable the use of blitz for these files? or is it a bug ?

Greetings,

Jan


Jan (skyhawk)
Re: Question about Blitz (bug?) [message #22022 is a reply to message #22013] Sun, 14 June 2009 22:20 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
skyhawk wrote on Sun, 14 June 2009 15:50

My existing projects often do not build using Blitz.
When Blitz is turned of there is no problem.

The problem lies in (re-)defining macros in different files.

suppose: foo.cpp has:

#define FOOBAR foo

and bar.cpp has:

#define FOOBAR bar

normally these definitions stay within the scope of the file, but with blitz on, they seem to clash?

I this normal behaviour for blitz? and should I just disable the use of blitz for these files? or is it a bug ?

Greetings,

Jan


Actually, BLITZ should undefine them when needed. But perhaps something does not work as expected.

You can check what BLITZ does looking at $blitz.cpp file in output directory.

Mirek
Re: Question about Blitz (bug?) [message #22023 is a reply to message #22022] Sun, 14 June 2009 22:20 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Alternatively, you can submit a testcase that demonstrates the problem.
Re: Question about Blitz (bug?) [message #22078 is a reply to message #22023] Tue, 16 June 2009 21:08 Go to previous message
janwilmans is currently offline  janwilmans
Messages: 51
Registered: January 2007
Member

To report on our private discussion about this;

The behaviour is a feature, .cpp files that redefine macros that are elsewhere defined in header (.h) files are undefined by blitz.

This behaviour is (apparently) required to make blitz work; to compile sources that have this problem, there are basically two options:

- move the defines into header files and include them in the .cpp
- disable blitz for the effected files

Greetings,

Jan


Jan (skyhawk)
Previous Topic: Breakpoints in gcc
Next Topic: How do I make a package a library?
Goto Forum:
  


Current Time: Sun Apr 28 07:14:23 CEST 2024

Total time taken to generate the page: 0.04689 seconds