The reasoning in 1b4766e26c did not take into account that the scope
of QT_NO_JAVA_STYLE_ITERATORS may change over time, as done with
f70905448f6 in Qt base.
Change-Id: Ib1966ff26c4d36d5f62e149d6b45baa4aecf825d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
The path to the serialized diagnostics log is the main parameter, so put
it first.
Change-Id: I8865aad302b0e5d3008dab606ab774167cebda3c
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
Accept diagnostics from files that are known to the project
(Project::files()) instead of checking whether they are below the
project root directory (Project::projectDirectory()).
Fixes: QTCREATORBUG-22213
Change-Id: I2f96374d6de3f53b1bd42be875dfe44b25a55fb1
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
...if the analysis ends with errors.
Task-number: QTCREATORBUG-22382
Change-Id: I59f99947e80f7f4d0e2cac4df2e00f68e385ee01
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
The string is passed further on as char * anyway, no need for
templates here.
Change-Id: I9305225f96111c0e9228d372e1231846099a9ecc
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
More in line with QFileInfo terminonlogy which appears to be
best-of-breed within Qt.
Change-Id: I1d051ff1c8363ebd4ee56376451df45216c4c9ab
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
The name "KitInformation" does not properly convey the fact that it
represents a certain *aspect* of a kit. The same goes for
"KitConfigWidget", which in addition was inconsistent with
"KitInformation".
We now use "KitAspect" and "KitAspectWidget".
Change-Id: I9804ee4cedc4d61fad533ea1dd4e4720e67fde97
Reviewed-by: hjk <hjk@qt.io>
The known cases provide enough flags not to require
toolchain defines.
Change-Id: Ia7e08a90eca6ea9474db40683ac1e63236f8643d
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
...for clang code model and clang tools use case.
This means that compiler detection code will see clang now instead of
the toolchain that is configured in the kit. While providing the
toolchain macros worked fine for the general case, it always was
problematic for compiler detection code.
By not providing the toolchain macros we are more close to the real
clang compiler invocation. That is, rely on clang to do the right thing.
Allow to go back to old behavior with QTC_CLANG_USE_TOOLCHAIN_MACROS=1
as this will be useful checking differences for debugging.
Fixes: QTCREATORBUG-19543
Change-Id: I23ffd761d83f35ca1a22269c3ef07a2dc62358bd
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
...for clarity.
No behavior change.
Change-Id: Id0334bc79b97a8ff53b37089e337530c9a01b1d4
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
No behavior change.
Sometimes we use "SkipX, sometimes "UseX". Unify to "UseX" as this is
more natural to read.
Change-Id: Ib08bdb4cde93ed55fdb9c855566b10a3933cae37
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
No behavior change.
* Remove virtual from methods that are not overridden
* Move constant member functions that do no access any members into
source file as static functions
* Remove QLatin1String where possible
* Make variable names a bit more consistent
* Other minor stuff
Change-Id: I34a582d5a468489e11365507b283e9aee157664f
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Instead, set the default level of all logs to QtWarningMsg.
The call to setFilterRules overrides the user preferences in qtlogging.ini.
Change-Id: Id5f6cd550d14ff7f45ae04c5d3110e0bafb0f072
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: hjk <hjk@qt.io>
For the indexing we need all tool chain macros. Originally it was a fix
because the C++ version of the project part and __cplusplus could be
different but now they should be the same. They will be now removed in the
compiler options builder.
Change-Id: I7ae8721a29632473e76ecedb411a6c9001e5e199
Task-number: QTCREATORBUG-21265
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
C++ include paths should come before Clang include
folder. Therefore parse all options for include/c++/v1,
include/c++/{version}, include/g++ and /usr/local/include.
Task-number: QTCREATORBUG-20231
Change-Id: I22c41f07d241e1e564069bb192d4fe637ff05e87
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
It has been an obsolete alias for setId for a while and downstream
uses have been adapted.
Change-Id: I467370aa67054599c7771e8275d28e62ddc461fa
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
The user does not usually need the whole command line.
Task-number: QTCREATORBUG-20707
Change-Id: I30cd395cd85eb0a3dd19b9d5f1b34a1c7a4b95a5
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
Only libclang has issues with the include directory
search therefore undefining include folders makes sense
only for libclang options builder.
Change-Id: Ie3f62f5f3a89503e6e0ab59e18889e92425c3abc
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
These functions require core plugin so they can't go
to utils library. At the same time to use them in
ProjectExplorer plugin there are not too many choices
where to put them without introducing new dependencies.
Change-Id: I3cccccffaae8ac4bbce924fd809b5423da5dc503
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
Diagnostic configuration Id was already there but
not the checkbox whether to build project or not.
Change-Id: Icb5fc15bda5eed5e375cd90df1a96060b30bf57e
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
...when a new run is triggered instead of on Qt Creator shutdown.
There is no reason to keep them around for longer than needed.
Change-Id: Ida7698843cc2f8822ffd662679cf5da2c4ece05c
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Serialized diagnostics consume quite a lot of space.
Remove these files after they are read by QtC.
Change-Id: I4b257e44ee182484726ebd808069198443992016
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
Now selection is only consists of combobox and
a "Manage" button to diagnostic configurations.
Diagnostic configurations are moved to the modal dialog
which is shown by clicking the mentioned "Manage" button.
Change-Id: I607fb923c97e8730448548708f3aaf32ce1983c8
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
...since it's superseded by the tidy integration.
Change-Id: Idafa5e1fb5129b1af8e42231a664684d4b90821f
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
If the run button is clicked, the user is prompted to select the files
for analysis.
Change-Id: I21e4ee6b7c14392a8c1a901ac7aa1c9c16e30f0d
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
All Clang tools get support for running project build
before themselves or skipping that step.
Before this change static analyzer always ran it and
ClangTidy+Clazy tool always skipped.
Change-Id: Idb9fbc27f0589472abb0f9d207857eb79c0079fd
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
We use custom clang executable and it does not make
sense anymore to give a choice of changing it.
Change-Id: Icf86042ac3fcd08c320ef2bbdaabef1102b023b5
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
... over the whole project.
Generate and read serialized files to get diagnostics.
Change-Id: Iafc25fc70443107a040a995efc038aed35102bbf
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
To reuse it for other clang-based tools.
Change-Id: I6c0d8e9eee543fa08faf3bf93c9fac33e43c6820
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>