1. 09 Dec, 2015 2 commits
  2. 02 Dec, 2015 1 commit
    • Nikolai Kosjar's avatar
      Clang: Fix recovering on clangbackend crash · 475b11aa
      Nikolai Kosjar authored
      
      
      The translation unit was updated, but not re-registered.
      
      Handle the editor documents this way:
        1. Reset all ClangEditorDocumentProcessors (this will send an
           unregister message, but that's not problematic).
        2. For the visible editor documents, run their processors so that the
           translation units will be re-registered.
        3. For the invisible editor documents, mark them dirty. Once the user
           makes an invisible document visible again, the processor will run
           and also re-register the translation unit.
      
      Change-Id: I23693ac197bd34a183f3a0020eb5372268636599
      Reviewed-by: default avatarMarco Bubke <marco.bubke@theqtcompany.com>
      475b11aa
  3. 01 Dec, 2015 1 commit
  4. 26 Nov, 2015 2 commits
  5. 23 Nov, 2015 1 commit
  6. 19 Nov, 2015 1 commit
    • Nikolai Kosjar's avatar
      C++: Revert lookup to 3.4.2 · 0498fb68
      Nikolai Kosjar authored
      ...which was least buggy.
      
      The bugs fixed by the changes we revert here (highlighting/completion
      for code involving templates) were minor compared to ones we currently
      have. Those bugs will be addressed by the clang code model anyway.
      
      Relevant commits were collected via:
      
        $ cd ${QTC}/src/libs/cplusplus
        $ git log \
         --no-merges \
         --format=oneline \
         v3.4.2..HEAD \
         -- LookupContext.* ResolveExpression.* TypeResolver.* TypeOfExpression.* \
            ../../plugins/cpptools/cppcompletion_test.cpp
      
      From this list the following were skipped due to irrelevance:
      
        88c5b47e # CppTools: Minor cleanup in completion tests
        e5255a1f # CppTools: Add a test for ObjC not replacing dot with arrow
        5b12c8d6 # CppTools: Support ObjC in member access operator tests
        9fef4fb9
      
       # CPlusPlus: Fix warnings about overriding visit(...) methods
      
      There were only minor conflicts while reverting those.
      
      This changes touches so many files because there were quite some
      cleanups and renames after the 3.4.2 release.
      
      Task-number: QTCREATORBUG-14889
      Task-number: QTCREATORBUG-15211
      Task-number: QTCREATORBUG-15213
      Task-number: QTCREATORBUG-15257
      Task-number: QTCREATORBUG-15264
      Task-number: QTCREATORBUG-15291
      Task-number: QTCREATORBUG-15329
      Change-Id: I01f759f8f35ecb4228928a4f22086e279c1a5435
      Reviewed-by: default avatarMarco Bubke <marco.bubke@theqtcompany.com>
      0498fb68
  7. 16 Nov, 2015 3 commits
  8. 12 Nov, 2015 1 commit
  9. 11 Nov, 2015 3 commits
  10. 09 Nov, 2015 1 commit
  11. 06 Nov, 2015 2 commits
  12. 23 Oct, 2015 1 commit
  13. 20 Oct, 2015 1 commit
  14. 14 Oct, 2015 2 commits
    • Tobias Hunger's avatar
      AbstractEditorSupport: Simplify licenseheader handling · a4476454
      Tobias Hunger authored
      
      
      Change-Id: I6bad3870b14066716fff5adc2a03b18f1840b6c7
      Reviewed-by: default avatarDavid Schulz <david.schulz@theqtcompany.com>
      a4476454
    • Nikolai Kosjar's avatar
      CppTools: Fix dead lock on project unloading · 77270648
      Nikolai Kosjar authored
      
      
      ...with the clang code model.
      
      In updateProjectInfo() we lock the project mutex and emit a signal.
      However, the correspondig slot in the clang code model will call back
      into a function that needs to lock the mutex, too:
      
          CppTools::CppModelManager::workingCopy // dead locks here
          CppTools::BaseEditorDocumentParser::InMemoryInfo::InMemoryInfo
          ClangCodeModel::Internal::ClangEditorDocumentProcessor::run
          ClangCodeModel::Internal::ModelManagerSupportClang::unregisterTranslationUnitsWithProjectParts
          ClangCodeModel::Internal::ModelManagerSupportClang::onProjectPartsRemoved
           ...
          CppTools::CppModelManager::projectPartsRemoved
          CppTools::CppModelManager::updateProjectInfo // emits here
      
      Fixed by emitting the signal after releasing the mutex.
      
      Change-Id: Id3f3cd22b0604f343ada56ea13c26f0dc1a75bd6
      Reviewed-by: default avatarMarco Bubke <marco.bubke@theqtcompany.com>
      77270648
  15. 13 Oct, 2015 1 commit
  16. 12 Oct, 2015 2 commits
    • Nikolai Kosjar's avatar
      CppTools: Make FollowSymbol respect projects · 6b6ad446
      Nikolai Kosjar authored
      
      
      Finding the class definition for a forward declaration or finding the
      function definition from its declaration is mostly determined by the
      file iteration order. Documents with the most common path prefix are
      checked first.
      
      This works fine as long as the files of your project have a common
      ancestor. If that's not the case, FollowSymbol might take you to the
      definition within another project.
      
      Fix that issue by considering the project part id when constructing the
      file iteration order. Since the cached file iteration order now depends
      on the projects, ensure to clear it if projects are added, changed or
      removed.
      
      Task-number: QTCREATORBUG-15116
      Change-Id: I529166bac363959c9fee0b946747fd0370a88809
      Reviewed-by: default avatarMarco Bubke <marco.bubke@theqtcompany.com>
      6b6ad446
    • Nikolai Kosjar's avatar
      CppEditor: Move static symbol finder instance to CppTools · 6ced48ea
      Nikolai Kosjar authored
      
      
      ...to it can be reused by other clients more easily. Also, in a
      follow-up change it will have a project part dependency that can be
      cleared inside the CppModelManager more easily.
      
      Change-Id: Ic9f2ce5212a94fd05ab0571e9ad99d0a25f5bc5c
      Reviewed-by: default avatarMarco Bubke <marco.bubke@theqtcompany.com>
      6ced48ea
  17. 09 Oct, 2015 1 commit
  18. 06 Oct, 2015 1 commit
  19. 29 Sep, 2015 1 commit
    • Nikolai Kosjar's avatar
      Clang: Integrate clang's fixits as refactoring actions · a7928b4b
      Nikolai Kosjar authored
      
      
      They are invokable by the usual means (Alt+Enter, editor's context menu
      > Refactor) plus by the context menu of the editor's left margin for the
      related line.
      
      The fixit text comes directly from libclang and is thus not translated.
      We modify the text slighty by stripping the diagnostic category prefix
      ("note:", "error:", ...) and capitalizing the first letter.
      
      A follow-up change should properly indicate available refactorings with
      a refactoring icon in the editor's left margin.
      
      Task-number: QTCREATORBUG-14868
      Change-Id: I86157c9f824d2a9dedf19087476d02ad1e6cc854
      Reviewed-by: default avatarMarco Bubke <marco.bubke@theqtcompany.com>
      a7928b4b
  20. 28 Sep, 2015 2 commits
    • Marco Bubke's avatar
      Clang: Add revision and completion management · b412eb81
      Marco Bubke authored
      
      
      Reparsing a document is expensive so we should avoid it by all means. In
      this patch we prevent that the same document is send again. It isn't send
      too in advance of a code completion if there was no changes before the
      the completion position.
      
      Change-Id: I0bb786ba1d4e7ce08611a518cb32f8cf8f4d0037
      Reviewed-by: default avatarNikolai Kosjar <nikolai.kosjar@theqtcompany.com>
      b412eb81
    • Nikolai Kosjar's avatar
      C++: Comment out a flaky test · e241444b
      Nikolai Kosjar authored
      The test relied on logic that was reverted with change
      915f68de
      
      .
      
      LookupScopePrivate::findSpecialization() gets a "TemplateNameIdTable
      &specializations" with a non-deterministic order. Without the extra
      logic, the very first entry will be chosen as the found specialization.
      
      The non-deterministic order comes from the TemplateNameId::Compare,
      which calls std::lexicographical_compare() with the template arguments,
      which are FullySpecifiedTypes. The result of
      FullySpecifiedType::operator<() might depend on a pointer comparison.
      
      Change-Id: I8d69d1bb5831145b1c21a5ea848c0043f17ec415
      Reviewed-by: default avatarChristian Stenger <christian.stenger@theqtcompany.com>
      e241444b
  21. 24 Sep, 2015 1 commit
  22. 23 Sep, 2015 3 commits
  23. 22 Sep, 2015 2 commits
  24. 16 Sep, 2015 2 commits
  25. 14 Sep, 2015 1 commit
  26. 10 Sep, 2015 1 commit