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

Auto completion adds closing brackets twice

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Not Evaluated Not Evaluated
    • None
    • Qt Creator 4.9.0
    • C/C++/Obj-C++ Support
    • None

      Since the 4.7 release (I think, not entirely sure when it started, but it's here for the latest few versions) the C++ code completion has a very annoying issue.

      Typing this:

          if () {
          } else {

      Will propose to automatically add the closing bracket upon pressing enter. However, doing so, it will add two of them and also break indentation. You'll end up with:

          if () {
          } else {
      
      }}

      instead of the expected outcome of:

          if () {
          } else {
      
          }

        1. narf.mp4
          258 kB
          Michael Zanetti
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            kosjar Nikolai Kosjar
            mzanetti2 Michael Zanetti
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes