Author Topic: Code betwen "#ifdef MY_SYMBOL" and "#endif" are grayed out  (Read 6292 times)

Offline cuiewk86

  • Single posting newcomer
  • *
  • Posts: 3
Code betwen "#ifdef MY_SYMBOL" and "#endif" are grayed out
« on: January 04, 2013, 08:22:49 pm »
Betwen the preprocesor conditionals (# ifdef, #endif) the code is grayed out, even if the
coresponding symbols are defined in a included header



PS. I am using C::B 12.11 rev 8629 on Windows XP
« Last Edit: January 12, 2013, 03:44:14 pm by cuiewk86 »

Offline euzkoarima

  • Single posting newcomer
  • *
  • Posts: 8
Re: Code betwen "#ifdef MY_SYMBOL" and "#endif" are grayed out
« Reply #1 on: January 18, 2013, 10:49:14 pm »
Same problem here!!
C::B 12.11
Ubuntu 12.04 x86_64

Offline euzkoarima

  • Single posting newcomer
  • *
  • Posts: 8
Re: Code betwen "#ifdef MY_SYMBOL" and "#endif" are grayed out
« Reply #2 on: January 18, 2013, 11:05:30 pm »
I've just read this thread http://forums.codeblocks.org/index.php/topic,17393.0.html
Works ok with defines in build options and defines in the same source, but fail with defines in headers !!

Offline cuiewk86

  • Single posting newcomer
  • *
  • Posts: 3
Re: Code betwen "#ifdef MY_SYMBOL" and "#endif" are grayed out
« Reply #3 on: February 19, 2013, 07:40:27 pm »
I've just read this thread http://forums.codeblocks.org/index.php/topic,17393.0.html
Works ok with defines in build options and defines in the same source, but fail with defines in headers !!

It does not work ok. If the symbol is undefined later in the file, the change is not recognized by the
program

Off the topic: I don't know how to insert an image in my post.  I tried "Insert Image", but cannot paste the
file between the tags.

   

Offline Alpha

  • Developer
  • Lives here!
  • *****
  • Posts: 1513
Re: Code betwen "#ifdef MY_SYMBOL" and "#endif" are grayed out
« Reply #4 on: February 19, 2013, 11:18:59 pm »
See explanations here and here.

For an image, upload it to an image hosting site (for example PasteAll), then put the url in the [img]http://www.pasteall.org/pic/show.php?id=XXXXX[/img] tags.  Or, if it is a small file, you could attach it (under additional options)... but keep in mind that forum space is limited, so it may be deleted.