Commit Graph

14 Commits

Author SHA1 Message Date
Marco Bubke
5dbaf387ba Utils: Move C++ language details from ProjectExplorer to Utils
We want to use them in the backend processes too so it's nice to share them
in Utils. A concrete size was added too because they should be serialized.

Change-Id: Id5eb8f46643d5159f034fc9559f68a08d7e5847a
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2019-01-15 10:37:03 +00:00
Robert Loehning
82a1dc2d66 Cppcheck: Use plural like in other strings
Change-Id: I41031253c1c30e867bd4506a1de82c3400eb0b8e
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-11-29 11:01:29 +00:00
Eike Ziller
7d3686359a Fix missing translation contexts
Change-Id: I4402157e7991ad0050333a34394b87ff3d6f4a1b
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2018-10-25 11:46:57 +00:00
Alessandro Portale
0e2e724dd5 CppCheck: Add a category text and icon to the Option page
All analyzer plugins need to set these for the case that they are the
only loaded analyzer plugin.

Task-number: QTCREATORBUG-21354
Change-Id: Ibb889ef2f4e2c10ebc9927301607b7539066b5ea
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-10-22 08:36:12 +00:00
Leena Miettinen
cacc0bf9e7 Cppcheck: Add missing space to translatable string
Change-Id: I87924a6b8dddf51d7dafae88176686746417acd5
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-10-19 11:55:42 +00:00
Nikolai Kosjar
6aa11eb75e CppTools/ProjectExplorer: Remove enum duplication
... between CppTools::ProjectPart and ProjectExplorer::ToolChain.

Change-Id: I8b448747e454adbed77547460383b8515462cc81
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-10-08 12:34:57 +00:00
Nikolai Kosjar
5900766ecb Toolchains: Detect unspecified language version
We checked the command line from the project manager for "-std=X" and
friends to figure out the language version to use. However, if such a
flag was not provided, we assumed the latest version we support. This
could conflict with the actual version of the compiler and its
predefined macros.

Figure out the version by inspecting __cplusplus/__STDC_VERSION__ in the
predefined macros of the toolchain. The MSVC compiler is an exception to
this, as it does not seem to properly set the value - check for
_MSVC_LANG if possible, otherwise simply assume some versions as before.

While at it, add also support for C17/C18 and the upcoming C++2a.

Task-number: QTCREATORBUG-20884
Task-number: QTCREATORBUG-21188
Change-Id: I464ffcd52d2120c0208275a050e82efda44fae1c
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-10-08 09:07:56 +00:00
Nikolai Kosjar
c7b65c69b1 qbs: Remove pointless ExtensionSystem dependency from plugins
A QtcPlugin depends on ExtensionSystem, so there is no need to restate
the dependency.

Change-Id: I8e0cb5f94858e912f5ce528ee67b683d4d837c27
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-10-08 05:49:44 +00:00
Sergey Morozov
f01ee04f4f Cppcheck: Kill current check process only when needed
Kill only if it processes specified files

Change-Id: I5dee99ec8aeaf3bf4d9dbf6aad195f54176170a2
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-09-30 07:38:40 +00:00
Sergey Morozov
a108a912dd Cppcheck: Fix progress parsing
Change-Id: I14bc5b93b00fee25d9e307606c4fc7b30ca23fe8
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-09-28 15:44:14 +00:00
Orgad Shaneh
7f2bbe9cfb Cppcheck: Reduce uses of auto
Conform to coding rules.

Change-Id: I57600bd450665d5db87710bb2444e39e7ecbf3e3
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-09-26 10:02:32 +00:00
Orgad Shaneh
9644745b3d Cppcheck: Replace another assertion with a condition
Missed in 3f4438e2eb.

Change-Id: Ie0ddeb7aad5dc70aec788b9df1954e884684cba1
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-09-26 10:02:21 +00:00
Orgad Shaneh
3f4438e2eb Cppcheck: Replace assertion with a condition
There are several editor types without path.

Change-Id: Ieb7f3453ae83d6b64488a5f9381b5e7927ff1ece
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-09-25 14:06:58 +00:00
Sergey Morozov
31b595314c Cppcheck: Add cppcheck static analysis tool
Automatically checks currently opened documents and displays results via text marks/annotations.

CppcheckTrigger detects when to check files or clear results.
CppcheckTextMarkManager stores/clears text marks with checks' results.
CppcheckTool generates run arguments and parses output.
CppcheckRunner runs cppcheck binary.
CppcheckOptions configures CppcheckTool.

Task-number: QTCREATORBUG-20418
Change-Id: I8eafeac7af6137d2c9061ae75d4a56c85b3b5a2d
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-09-18 19:07:12 +00:00