Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-21064

Code folds incorrectly with #ifdef

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P2: Important P2: Important
    • Qt Creator 15.0.0
    • Qt Creator 4.7.0, Qt Creator 4.14.0-beta1
    • C/C++/Obj-C++ Support
    • None
    • Linux/X11
    • 2bfa16daa (master)

      int main() {
      #ifdef NOT_DEFINED
      	if (true) {
      		//...
      	}
      	else {
      		//...
      	}
      #else
      	if (true) {
      		//...
      	}
      #endif
      }

      In this file, the main function only folds the first line. The comments in the if/else blocks in the NOT_DEFINED region can fold to the next line, and the else block can fold to the end of the function.

        1. foldedclass.h
          0.2 kB
          Robert Löhning
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            kandeler Christian Kandeler
            tguen tguen
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes