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

[REG 12.0.1 -> 13.0] "Extract Function" inserts pointless white space characters

XMLWordPrintable

    • 02de46110 (13.0)

      1. Have a block using braces in your code, e.g.:
            int x = 0;
            if (argc > 3) {
                ++x;
                
            }
        

        Please note that when you type in that code and press Return after "++x;", Creator inserts white space characters in the next line so you could go on typing with the expected indentation.

      2. Select "if".
      3. Right-click on the selection and select "Refactor" -> "Extract Function" from the context menu.
      4. Enter some name for the new function and click "OK".
        The code is moved to a new function, but the line below "++x;" now contains twice as many white space characters as before.

      The number of white spaces should not change. This worked correctly in Qt Creator 12.0.1.

      Found and tested by Squish test tst_CSUP03.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            kandeler Christian Kandeler
            rlohning Robert Löhning
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes