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 » cpp/icpp name clashes [BUG?]
cpp/icpp name clashes [BUG?] [message #25649] Sat, 06 March 2010 02:25 Go to previous message
dolik.rce is currently offline  dolik.rce
Messages: 1789
Registered: August 2008
Location: Czech Republic
Ultimate Contributor

Hello!
I just realized, that having package with .cpp and .icpp file of the same name leads to error, because the second object file rewrites the first. I'm not sure if it can be called a bug, but I think it should be at least mentioned somewhere in the documentation. Solution to this could be using different name or separate folder when compiling icpp files... Simple testcase follows:

File test.cpp:
#include <Core/Core.h>
using namespace Upp;
extern int test;

CONSOLE_APP_MAIN{
	Cout()<<"test: "<<test<<"\n";
}
File test.icpp:
#include <Core/Core.h>
using namespace Upp;

int test;
INITBLOCK{test=1;}
This fails to link, but if you rename one of the files, it works as expected.

Best regards,
Honza
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: theIDE crashes on win32 since revision 2221
Next Topic: batch build
Goto Forum:
  


Current Time: Sat Apr 27 18:23:22 CEST 2024

Total time taken to generate the page: 0.03097 seconds