bonjour,
j'essaie de compiler ce bout de code quis se trouve dans un Exeption.h
j'a un Exception.cc et un main.cc
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7 #ifdef _DEBUG # define Assert(condition) if (!(condition)) throw CAssertException(__FILE__, __LINE__, "Condition non satisfaite\n\n" #condition) #else inline void DoNothing(bool) {cout << "bonjour" << endl;} # define Assert(condition) DoNothing(!(condition)) #endif
pour compiler je tape ceci
g++ -g main.cc ./tools/CException.cc -o test
et ben il m'affiche toujours le bonjour, (donc il ne reconnais pas mon -g
par contre si je met en dur #define _DEBUG; la tout est ok.
pk??et surtout comment faire pour avoir le DEBUG
merci
merci
a++
Partager