summaryrefslogtreecommitdiff
path: root/src/libs/clangbackendipc
Commit message (Collapse)AuthorAgeFilesLines
* Clang: Fix warningNikolai Kosjar2016-06-231-1/+1
| | | | | | | | readmessageblock.cpp:95:36: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] Change-Id: I24c5125f2116e5538b7d0e2389e66bf5d318640a Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
* Clang: Fix aliasingMarco Bubke2016-06-2211-56/+58
| | | | | | | Task-number: QTCREATORBUG-15888 Change-Id: I0f2e28e9e0da53481c03707ab0a9abf728c7419f Reviewed-by: hjk <hjk@theqtcompany.com> Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
* Clang: Fix incorrect size check of message reader.David Schulz2016-06-211-1/+1
| | | | | Change-Id: Ia734c5234d899e71da46d8111299cf8f86dc67c2 Reviewed-by: Marco Bubke <marco.bubke@qt.io>
* qbs build: Remove some differences to qmake build results.Christian Kandeler2016-05-171-0/+1
| | | | | | | | | | | - Install library symlinks. - Do not create symlinks for plugins. - Skip some translations. - Rename some binaries. - Do not install the ptracepreload library. Change-Id: I0faa98034154e3840cd2695cab14b72c34cfc5c3 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Merge remote-tracking branch 'origin/4.0'Eike Ziller2016-05-032-0/+2
|\ | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/debugger/debuggerruncontrol.cpp src/plugins/projectexplorer/projectwizardpage.cpp src/plugins/projectexplorer/xcodebuildparser.h src/plugins/qmldesigner/qmldesignerplugin.cpp src/tools/clangbackend/ipcsource/translationunits.cpp Change-Id: Ibf0857cf8dbf95fc9ac13d5c2112b3f4a2ca7de6
| * Fix compileBogDan Vatra2016-05-022-0/+2
| | | | | | | | | | | | Change-Id: I5c8889639c61ff11c8b159c3bd1ef63246664922 Reviewed-by: hjk <hjk@theqtcompany.com> Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
* | Fix compiler warnings on windows.David Schulz2016-04-221-1/+1
| | | | | | | | | | | | | | | | | | | | | | Ignore some warnings inside 3rd party code and fix a lot of conversion warnings. Change-Id: I909f2f31a4639015bf7dd028d2d435ff1d1167bc Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com> Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com> Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
* | Merge remote-tracking branch 'origin/4.0'Eike Ziller2016-04-201-2/+2
|\ \ | |/ | | | | | | | | | | | | Conflicts: src/plugins/projectexplorer/session.cpp src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp Change-Id: I6946139f5e5fa3a9cdbb322fd50be248e2c0133f
| * Clang: Forward clangbackend output to qDebug instead of stdout/stderrNikolai Kosjar2016-04-151-2/+2
| | | | | | | | | | | | | | | | | | | | Now the output of the clangbackend can be viewed with DebugView on Windows. Downside is that qDebug() will append newlines. This can't be turned off easily. We accept that. Change-Id: I7d68bfcf05780c8bcb4a05a538d2d1542a6a6f22 Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
* | Wholesale conversion to #pragma oncehjk2016-03-3041-163/+42
| | | | | | | | | | | | | | Kudos to cgmb and https://github.com/cgmb/guardonce Change-Id: Ifa8970734b8d43fd08c9260c645bdb0228633791 Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
* | Clang: Add Declaration highlightingMarco Bubke2016-03-075-19/+89
| | | | | | | | | | | | | | | | | | We are adding declaration detection for function to the highligher on user request. Other declaration will follow in separate patches. Task-number: QTCREATORBUG-15564 Change-Id: I54e97c26425f8d6e9854547d50a9ac8fa076b4e8 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* | Clang: Rename HighlightingInformation to HighlightingMarkMarco Bubke2016-03-071-4/+1
|/ | | | | Change-Id: I3954c7c9abe593ea04092337f48ac2b153e883ba Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* UnitTests: Rename CLANGBACKEND_TESTS in UNIT_TESTSMarco Bubke2016-02-171-2/+2
| | | | | Change-Id: I26635a0c85edcc90cdffb93d3f9ae4ad4c8cb98e Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
* ClangBackend: Fix warning about unused member variableTobias Hunger2016-02-121-1/+0
| | | | | Change-Id: I0608eb32f77bb677f1fecc1c75082ecf29ff1aa8 Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
* Clang: Use MessageEnvelop instead of QVariantMarco Bubke2016-02-0871-655/+311
| | | | | | | | | | QVariant has unwanted dependencies so we provided our own simpler solution. We want to support move only types and calling the copy constructor as you move the value in and outside. This copying is adding unwanted overhead too. Change-Id: I2e27a7924868efe81e8b8ff3415499c9fa22c2bc Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Update License according to agreement with Free Qt FoundationTobias Hunger2016-01-1984-1429/+1010
| | | | | | | * Update remaining files in src Change-Id: I1896f17fcf34f71c3310c87899fb5171b8e4afb1 Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
* Clang: Correct member access operator if possibleNikolai Kosjar2016-01-193-5/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1 struct Foo { int member; }; 2 void f(Foo *foo) 3 { 4 foo.<REQUEST COMPLETION> // correct '.' to '->' and provide results 5 } The preferred approach would be to check if "foo" in line 4 is of pointer type, but there is no suitable cursor (only CompoundStmt) at that position since the code is usually not yet parsed and thus invalid. Thus, just run the completion as is. If there are not any results for a dot completion, re-run the completion with "." exchanged by "->". This approach is inherently slower than the preferred approach implemented in the built-in code model. The following rare cases are not handled: 1) Requesting completion after white space: Works: foo.<COMPLETE HERE> Fails: foo. <COMPLETE HERE> 2) Opening a file and requesting completion (ctrl+space) without prior editing. No editing before triggering completion means that no unsaved file is generated on the backend side, which is a requirement for the correction. Task-number: QTCREATORBUG-11581 Change-Id: I6bc8e8594778774ab342755fdb01a8a3e5c52ba0 Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* Clang: Clangbackendipc build fixYuchen Deng2016-01-051-3/+1
| | | | | Change-Id: I750521cca5e101e679b79cf45f995f5cca8f07bb Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Flatten code completion chunksMarco Bubke2015-12-162-44/+23
| | | | | | | | Avoid the sub vector for performance reason and use an flag for every optional argument because there can be no recursion. Change-Id: Iae1eaa1f164e4129e30358a1719582e5231f0385 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Show type icon for usings/typedefsNikolai Kosjar2015-12-082-0/+2
| | | | | | | | ...in the completion widget. Task-number: QTCREATORBUG-15078 Change-Id: I1309b628e1f060fa68bdcf13838037728207b035 Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* Clang: Use line and column instead of offset for diagnosticsMarco Bubke2015-12-072-13/+15
| | | | | | | | Offsets can be get wrong because of the utf8 <-> utf16 differences. Line and columns are not that sensitive to it. Change-Id: I2e3e8c000621b6d694a4ada6df176f29427794f5 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Fix slowness of code completion after opening the fileMarco Bubke2015-12-022-6/+44
| | | | | | Task-number: QTCREATORBUG-15429 Change-Id: I9a8a582fb3c59a960425f83eb8e7b436f15d1c1a Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Change temporary directory for clangbackendMarco Bubke2015-12-012-1/+27
| | | | | | | | | | | | | | This is meant to 1. Work around a libclang bug on Windows (not deleting preamble files) 2. Delete left-over preamble files in case of a clangbackend crash The temporary diretory will be removed on Qt Creator exit. Task-number: QTCREATORBUG-10988 Change-Id: Ia5837c2a6ab2d55366d167dd591d87faaededf3e Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com> Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Integrate highlighting results from backendMarco Bubke2015-11-2618-3/+658
| | | | | Change-Id: I2c3fb69aabfe075bde76d63eafc2ca370f17493c Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* Clang: Enable not exporting symbolsNikolai Kosjar2015-11-262-3/+3
| | | | | | | | Having a dllexport in the sources for a TEMPLATE=app project (e.g. unittest.pro) will create a library on Windows, which is not needed. Change-Id: I1ebdd8b5ada06965c3dd89074ac2bc6dff09299c Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* Clang: Add current and visible editor messageMarco Bubke2015-11-259-3/+209
| | | | | Change-Id: Ifd88bc032388ae7a8d3dbc0f1f5746665074cc18 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Extract highlighting informationMarco Bubke2015-11-171-0/+23
| | | | | | | | | Prepare the move of the semantic highlighting to the clang back end. We have it under tests too so it should be quite easy to make changes or corrections. Change-Id: I5706a8a06fde5a9ba2eba3a8ba62782102ac0bd3 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Report only diagnostics that can be shown in the editorNikolai Kosjar2015-11-162-1/+9
| | | | | Change-Id: I9c258159d240c6ba7eeff34702d8512d9220b3af Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* Clang: Provide the language option to the backendNikolai Kosjar2015-11-062-0/+15
| | | | | | | | | Provide the language option (e.g. "-x c++-header") when registering a translation unit for the editor. Task-number: QTCREATORBUG-14787 Change-Id: Ie06f9fdab302f1b21ba72cdb65b6aabf9f7bc04c Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
* Clang: De-duplicate in Messages::registerMessages()Nikolai Kosjar2015-10-191-79/+32
| | | | | Change-Id: Id3c73249f562abd89de8e76290ea712c2fe7fae1 Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* Clang: Add UpdateTranslationUnitsForEditorMessageMarco Bubke2015-10-1310-3/+190
| | | | | | | | | If an editor is changing all translation units independent of their project part they must be updated too. So we introduce a new message to update all translation units with the same file path. Change-Id: I70d0ea2bbca9fa880111ff7219573e54f3277026 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Strip BOM from filesNikolai Kosjar2015-10-015-5/+5
| | | | | Change-Id: I9167c016760fe1e8378cdf84144c4bed5cd4e57c Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* Clang: Add environment variable to disable alive timerMarco Bubke2015-09-211-2/+6
| | | | | Change-Id: I558ff0fe83cce9ee921819c6fd9c18534fad9bcf Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Fix compilation on OS X / clangEike Ziller2015-09-016-0/+12
| | | | | Change-Id: I7cc5738971b00dfcf012584d4b51f86914ec874b Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Add QDataStream includes to ipc container.David Schulz2015-09-012-0/+2
| | | | | Change-Id: I6f73a1daa3e8b934896ceb6fd0c1185e24d60236 Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* Clang: Add unsaved files messagesMarco Bubke2015-08-3111-3/+380
| | | | | | | | We have auto generated buffers from ui files which are not open but have no file representation. So we need to provide them as unsaved files only. Change-Id: I48a426c18e06eeda2fa707864f32f293e17ac651 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Rename ForCodeCompletion in ForEditorMarco Bubke2015-08-3117-178/+178
| | | | | | | | It reflects that the translation units and projects have a tied relationship with an editor. Change-Id: I3c01d5776980fe079af1fdef82feded83fdf5463 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Reparse only if files are changedMarco Bubke2015-08-317-43/+45
| | | | | | | | | | Includes are now watched by a file watcher. Unsaved file changes are watched too. If they are changed the translation units which depend on them are set to a state which require a reparse. Later the diagnostics of this units are collected and send back to creator. Change-Id: I2fb5c7dd6644687f22399edd8d18edd6215c9505 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Add brief comment supportMarco Bubke2015-08-312-0/+16
| | | | | Change-Id: I5af23b6694d3d0bf45ed0a30b4d91b350f0515df Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Add diagnosticsMarco Bubke2015-08-3125-3/+1267
| | | | | | | | Diagnostics are now moved to the clang backend process. Fixits are supported too. Change-Id: I20faacf466bbf78dec479220c3d7b336a47bc453 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Rename command in messageMarco Bubke2015-08-2546-685/+685
| | | | | Change-Id: I1e2671d15b0db3c670b86dd0d4bed5ee09e866f1 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Clarify stdout/stderr prefix of backendNikolai Kosjar2015-07-291-2/+2
| | | | | Change-Id: I936e75ddc26b812c4570859e6a61c2a09590ed98 Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
* Clang: Allow to time high-level functionsNikolai Kosjar2015-07-293-0/+39
| | | | | | | | | ...by enabling the logging rule: qtc.clangbackend.timers=true Change-Id: I085c6bbebc0343b74bcb90119d1ebb80ad49518d Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
* Clang: Typedef some often used typesNikolai Kosjar2015-07-236-15/+22
| | | | | | | | using CodeCompletions = QVector<CodeCompletion>; using CodeCompletionChunks = QVector<CodeCompletionChunk>; Change-Id: Id729a43566c23dc000e44d79ccf4a49e4f235f51 Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* Clang: Shorten debug outputNikolai Kosjar2015-07-205-6/+163
| | | | | | | | ...by writing unsaved file content and project part arguments to temporary dirs. Change-Id: Ic411700cb3da756788bbb315851ff38b0100fe71 Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* Clang: Fix command name for QDebugNikolai Kosjar2015-07-171-2/+2
| | | | | Change-Id: If29a41aaefeda725965a85f0c7ff47124e2a23c7 Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
* Clang: Remove the hint and snippet field from the CodeCompletionMarco Bubke2015-07-162-28/+0
| | | | | | | It is not used and is producing overhead. Change-Id: I1398b18a40c0f5c0b90fe4c058996d7eb109f9f2 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Rename filePaths in idsMarco Bubke2015-07-152-12/+12
| | | | | | | | UnregisterProjectPartsForCodeCompletionCommand is using them as ids and not as file paths. Change-Id: I13a82c1995c60bdb60c72f4fd794aa354fcbb4ef Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
* Clang: Fix potential infinite loopNikolai Kosjar2015-07-021-2/+2
| | | | | Change-Id: I373a652db8811b0ebb416f5914aa4af12a23a3c9 Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
* ClangBackendIPC: Fix qbs build on Windows.Christian Kandeler2015-06-301-1/+1
| | | | | Change-Id: I3dee9256cf9b49b3a5651d8534aec630c2d1ae5d Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>