Home Download Buy Blog Forum Support

#ifdefs break SB2's block detection logic

#ifdefs break SB2's block detection logic

Postby rab on Thu Nov 15, 2012 11:06 pm

Consider this snippet:

Code: Select all
int main(void) {

#if 1
   if (1) {
   if (0) {


SB2 gets confused by the opening braces in the #if/#else clause, and doesn't match up the opening and closing braces of main(). It doesn't recognize that only one of those lines with an opening brace can be active at a time. This means that a file with such a construct in the middle stops having its function names available (via cmd-P, or @- search-everything), after whichever function contains the #if/#else.
Posts: 4
Joined: Wed Oct 19, 2011 10:57 pm

Return to Technical Support

Who is online

Users browsing this forum: Exabot [Bot] and 25 guests