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

Auto-indent with lambda returning a type is broken

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Not Evaluated
    • None
    • Qt Creator 3.6.0
    • C/C++/Obj-C++ Support
    • None
    • Mac OS X 10.8

    Description

      The following is a result when using ->QVector<float> returns from a lambda. If ->QVector<float> is omitted, the indention works correctly. Otherwise indention after the lambda expression is all messed up.

          qDebug() << "Before!";
          
          auto contourData = [this]()->QVector<float> {
                  QVector<float> data;
                  return data;           
      };
                  
                  qDebug() << "I get here";
      

      I expected the indention to look something like this:

          qDebug() << "Before!";
          
          auto contourData = [this]()->QVector<float> {
              QVector<float> data;
              return data;           
          };
                  
          qDebug() << "I get here";
      

      Attachments

        Issue Links

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

          Activity

            People

              kosjar Nikolai Kosjar
              vpicaver Philip Schuchardt
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes