User forums > Using Code::Blocks

Function list & #define

(1/1)

blinde:
Hello

I have some code :

#ifndef TITI
void func()
{

}
#endif

...

#ifdef TITI
void func()
{

}
#endif

I use an external makefile where I define TITI.
So the function I use is the second one.

In the function list of my file, I see the function func()
But it points on the first one. (not the good one)

Is there a way to inform Codeblocks that TITI is defined and that should force it to point on the second function ?

Thanks

Chris

MortenMacFly:

--- Quote from: blinde on September 09, 2010, 09:31:36 am ---Is there a way to inform Codeblocks that TITI is defined and that should force it to point on the second function ?

--- End quote ---
The C::B version of the code completion branch handles that just fine. This will be available through the nightlies probably soon.

Jenna:

--- Quote from: MortenMacFly on September 09, 2010, 09:54:16 am ---
--- Quote from: blinde on September 09, 2010, 09:31:36 am ---Is there a way to inform Codeblocks that TITI is defined and that should force it to point on the second function ?

--- End quote ---
The C::B version of the code completion branch handles that just fine. This will be available through the nightlies probably soon.

--- End quote ---
I don't think it can be handled if the define is in the makefile, as amkefiles are not parsed by cc.

MortenMacFly:

--- Quote from: jens on September 09, 2010, 09:56:28 am ---I don't think it can be handled if the define is in the makefile, as amkefiles are not parsed by cc.

--- End quote ---
Oops - you are right, I missed that part. :oops:

Navigation

[0] Message Index

Go to full version