Commit Graph

5234 Commits

Author SHA1 Message Date
Nikolai Kosjar
dbe08fda37 Format clang-format example project with clang 6/7
Change-Id: Icc690e5f8293bd07dc0d0e0b76a6cefb11d3a684
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2019-01-07 12:45:42 +00:00
Eike Ziller
04a4bacbf9 Merge remote-tracking branch 'origin/4.8'
Conflicts:
	src/plugins/coreplugin/dialogs/externaltoolconfig.ui

Change-Id: Ie38e9028cee599578c59b22325d85c097335243e
2019-01-07 13:24:12 +01:00
Nikolai Kosjar
4cc32d411a Clang: Fix highlighting lambda captures
This fixes the basic case, but e.g. captures with initializers, e.g.
[foo=bar] are not properly reported by libclang and thus "bar" is still
not highlighted for this case.

Task-number: QTCREATORBUG-15271
Change-Id: I1a2d465f71b0ae1a0406ef9e77d88898e8637958
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2019-01-03 10:31:05 +00:00
Marco Benelli
51f93c0dfc qmljs: basic ECMAscript 7 test suite
Change-Id: Ib313ba1be60265784fc6f699b5aa6990277fa33f
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2018-12-20 15:19:19 +00:00
Ivan Donchevskii
167150396d Clang: Fix CompilerOptionsBuilder test
Amends commit f6b8302efd.

Change-Id: Ia4041fcf590e5b85b9422047afa91d4d98837121
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-12-20 12:47:34 +00:00
Christian Kandeler
78bea41239 SSH: Fix manual tests
Change-Id: Ia796bb9ad2f3440d98b60229ddc43971dd35f810
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-12-19 11:05:51 +00:00
hjk
2a67a86c2f Debugger: Add fallback when gdb.Value.cast() fails for typedefs
Fixes: QTCREATORBUG-18450
Change-Id: I9239beb7e1879a284e28a30579129fe487eb2dd2
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-12-17 13:21:02 +00:00
Marco Bubke
ef8de6a384 CppTools: Introduce HeaderPathFilter
We went the filtering of the header path outside of the compiler options
builder so merge the PCHs.

Task-number: QTCREATORBUG-21693
Change-Id: Ia1126813a5049e39d7c6e7d60bf449aa17012d02
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-12-17 11:06:14 +00:00
hjk
5a8b198b9a Debugger: Fix display of multidimensional C arrays
Fixes: QTCREATORBUG-19356
Fixes: QTCREATORBUG-20639
Fixes: QTCREATORBUG-21677
Change-Id: Ie28b51c6caf526e125234959cbf11503d0683dc7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-12-17 09:42:56 +00:00
Eike Ziller
2529b36b40 Merge remote-tracking branch 'origin/4.8'
Change-Id: Id1484d611d457d8e4598fb53975b2288690b64bb
2018-12-17 10:05:11 +01:00
Christian Stenger
bff51f9e2a Squish: Fix default settings test
QC ships a valid usable clang that gets detected as compiler.

Change-Id: Iddf94ed6c563367289a1f5418ab222e14c05f81c
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2018-12-13 16:42:43 +00:00
Christian Kandeler
d7178b88c4 SSH: Use OpenSSH tools
... instead of our own SSH library.

Advantages:
    - Full compatibility with OpenSSH behavior guaranteed.
    - Minimal maintenance effort.
    - Less code to build.
    - Big chunk of 3rd party sources can be removed from our repository.

One the downside, Windows users now need to install OpenSSH for
RemoteLinux support. Hoewever, people doing embedded development
probably have it installed anyway.

[ChangeLog] Switched SSH backend to OpenSSH

Fixes: QTCREATORBUG-15744
Fixes: QTCREATORBUG-15807
Fixes: QTCREATORBUG-19306
Fixes: QTCREATORBUG-20210
Change-Id: Ifcfefdd39401e45ba1f4aca35d2c5bf7046c7aab
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2018-12-13 15:10:11 +00:00
Robert Loehning
c6e09c0c80 Squish: Un-skip searching for missing output
Cannot reproduce the issue anymore.

This reverts commit df2b2f1a17.

Change-Id: I10487eb0036195835d2bd0abe75c5b458a13cf36
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-12-13 10:35:22 +00:00
Robert Loehning
e48436d7c5 Squish: Expect some more compilers
Change-Id: I00dcd2334ff8d545450e923c28fcc6cf4efd570a
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-12-13 10:33:05 +00:00
Robert Loehning
06898f0ae7 Squish: Add note about required clang version
With clang 6.0 from Ubuntu's repositories, tst_memberoperator will fail.

Change-Id: I4cbd4f13e849816e70934312d67c079a88ba89a8
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-12-13 10:32:47 +00:00
Eike Ziller
9084ca73df Merge remote-tracking branch 'origin/4.8'
Conflicts:
	qbs/modules/qtc/qtc.qbs
	qtcreator.pri
	src/plugins/cpptools/compileroptionsbuilder.cpp

Change-Id: I87f47cecbb924064296a002fd9446a0627acad8e
2018-12-12 09:44:13 +01:00
Christian Stenger
b382d83fab Squish: Adapt test to changed behavior
41d68f469a restored (partially) the old behavior which
changes the '.' operator to '->' if all completions need it.

Change-Id: I92c2183e7e7f1c0d839f2340c2abe7a9f7d73af2
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2018-12-11 17:44:10 +00:00
Christian Stenger
a83330ca26 Squish: Drop testing of pastebin.ca
Change-Id: Ideab89362bb839f27f10234d13d4cfa92b1beba6
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2018-12-11 12:45:33 +00:00
Christian Stenger
d0e4f657c9 Squish: Adapt tst_git_local
Committing has been made a 'bit less synchronous'.
So, wait a short amount of time to have the expected
output present, but fail if it does not appear within
that time frame.

Change-Id: I5f6c02dcec42800e876a4bae36e08596bedf0049
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2018-12-11 12:45:05 +00:00
Ivan Donchevskii
aa70799795 Clang: Always force the built-in includes order
C++ includes must always come first, then clang resource
directory and then everything else.
This prevents both c++ standard headers and intrinsics issues.

Change-Id: Ia21bfa2fe99884c9adf58f7ef6beba1bede1724b
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-12-11 07:49:09 +00:00
Marco Bubke
390a227df6 ClangPchManager: Introduce PchTaskQueue
With the PchTaskQueue the pipeline is almost complete.

Task-number: QTCREATORBUG-21346
Change-Id: I5f05d525db1679eb37dd1d462076c1ed42958099
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-12-10 17:09:31 +00:00
Marco Bubke
96eb407266 ClangPchManager: Introduce PchTasksMerger
So far no merging is happening but we will add it after the rest of the
pipeline is in shape.

Task-number: QTCREATORBUG-21381
Change-Id: I610c243eabcb305843ad6339fdc636b0c3966fc1
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-12-10 17:09:02 +00:00
Christian Stenger
0eafe28bd1 Tests: Correct expectation
Broke with 84576d3098.

Change-Id: Ib03a44f9864c1e2072ecd4b98eb3c2ffef5741d3
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: hjk <hjk@qt.io>
2018-12-10 13:03:35 +00:00
Marco Bubke
299a163b18 ClangPchManager: Extend PchTaskGenerator
It's generating now PchTasks for project and system includes and call the
merger directly.

Change-Id: I966a9a72e1b915255d95b713b66e92d36d85d79b
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-12-10 10:58:40 +00:00
Nikolai Kosjar
9e17bd1bf0 Clang: Avoid multi-line display name for completion items
These come directly from clang. If converting for display in the
completion list widget, skip new line chunks.

Fixes: QTCREATORBUG-21600
Change-Id: I83749ed73fa68658ec073d97177768f59a87cebf
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-12-07 13:43:09 +00:00
Eike Ziller
e5c2ee922a Merge remote-tracking branch 'origin/4.8'
Conflicts:
	src/plugins/cpptools/compileroptionsbuilder.cpp

Change-Id: I743ea39480cc5c7b6febcd2e93713d15a3ae6d9c
2018-12-07 08:53:11 +01:00
Nikolai Kosjar
6889f4df80 Clang: Fix tooltip for pointer to class
Detect and dereference pointer to get to the correct class.

Fixes: QTCREATORBUG-21523
Change-Id: I679778b2cfbbce4466294dabdee096686f53f095
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-12-06 08:55:28 +00:00
Nikolai Kosjar
c7c800a73e CppTools: Split CppTools::UseBuiltin in two options
...for clarity.

No behavior change.

Change-Id: Id0334bc79b97a8ff53b37089e337530c9a01b1d4
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-12-04 14:57:20 +00:00
Christian Stenger
39510f5382 Squish: Fix tst_CSUP02
Squish (and therefore the test) "is typing" too fast
which breaks some assumption and the (nowadays?) normal
behavior of the CppEditor.
Fix this by introducing a delayedType() function to
be more realistic when doing this test.
Also removes a workaround for QTCREATORBUG-18769 as
this seems no more valid at all.

Task-number: QTCREATORBUG-18679
Change-Id: Ie43554c5b198bf3dc4a26ad12c8368f43bfd21af
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2018-12-04 07:53:52 +00:00
Nikolai Kosjar
273157c2a1 Clang: Unify CompilerOptionsBuilder options
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>
2018-12-03 15:19:03 +00:00
Christian Kandeler
1fc2b12ffc SSH: Fix autotest
The SshX11InfoRetriever object must not be allocated on the stack, and
the failure signal was potentially emitted too early for the test to
catch it.

Change-Id: Iac53546deee183c8f02bafdcc11a7910f3e392c0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-12-03 13:47:26 +00:00
Nikolai Kosjar
0c38e3aea7 Clang: Clean up CompilerOptionsBuilder
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>
2018-12-03 12:58:31 +00:00
Marco Bubke
ce9f503691 ClangPchManager: Add UsedMacroFilter
The compiler macros are filtered in system and project macros. Not used
ones are removed. The original order of the macros is retained.

Task-number: QTCREATORBUG-21548
Change-Id: Ic9265866bde033e6a9600f9e6439b1697ab73422
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-12-03 12:51:25 +00:00
Nikolai Kosjar
6e75e7f4e4 Clang: Fix failing unit test
...amends 12dce3ef7d.

Change-Id: I93ef9b4dfaf0bbe9f4be1d0f2688eb5726938c81
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-12-03 08:11:55 +00:00
Orgad Shaneh
7096649fc2 Merge remote-tracking branch 'origin/4.8'
Change-Id: I5b18233936e3b2cd674df92a694ba73b5a3ed752
2018-12-03 09:56:07 +02:00
Orgad Shaneh
5e8ec97d69 Do not build QmlDesigner tests when the plugin is disabled
Change-Id: Iaf7e06be6b81040c36726aa76923b285e2402aef
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-12-03 07:40:08 +00:00
Christian Stenger
445b7a6242 Squish: Mark test as expected fail
Task-number: QTCREATORBUG-21335
Change-Id: I54148ecf746362a22bf739ef80930a40bb6da2fe
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2018-11-30 11:19:02 +00:00
Christian Stenger
d3c1086910 Squish: Fix WELP tests
Adapt to new titles of some tutorials.

Change-Id: I18d62d88877b59a51ebfdb19f5fe16ac8d828800
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-11-29 14:45:10 +00:00
Eike Ziller
29c9f8080d Merge remote-tracking branch 'origin/4.8'
Conflicts:
	src/plugins/android/androidrunnerworker.cpp

Change-Id: Ibd8b99435365fb7e7d488313fd1d2b3a75adad1b
2018-11-29 13:36:14 +01:00
Ivan Donchevskii
9eb66a806f Clang: Properly set up warnings for clang-based libraries
Add warning flags to QMAKE_CXXFLAGS_WARN_ON to have them
after default warnings.

Change-Id: Ic94fe36175d3198191251d5b475f8f8ed000bef7
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-11-29 09:27:33 +00:00
Ivan Donchevskii
e5c2b30e90 ClangFormat: Enable BreakStringLiterals in .clang-format
Change-Id: Icbd601c236cb5ad620d1bc7217a8629fe50a0046
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-11-27 10:20:52 +00:00
David Schulz
b25ad292d3 ProjectExplorer: merge AbstractMsvcToolChain into MsvcToolChain
The abstraction was initially done for the WinCE tool chain.
Since we do not support WinCE anymore merge this classes back together.
This reduces the maintenance burden, beacause there was no clear line on
what functionality belongs in which abstraction layer.

Change-Id: I70b75482f83538221789369acea5b8df6d89af75
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-11-27 09:42:50 +00:00
Marco Bubke
15df73a8ba Clang: Fix output arguments highlighting for constructor parameters
The are not any more shown but they are still not shown for constructor
arguments because libClang is providing the wrong argument count.

Task-number: QTCREATORBUG-21543
Change-Id: If9b6140ed4b2dedf71bd94aae0a97669cdd04e67
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-11-27 08:51:35 +00:00
Christian Stenger
217636886c Tests: Fix QmlJs auto tests
Change-Id: Iba5e5e786e8241db120359f95850207021d61c49
Reviewed-by: Marco Benelli <marco.benelli@qt.io>
2018-11-27 08:13:27 +00:00
Nikolai Kosjar
f56ec051b0 Clang: Fix TokenProcessor.Qt* tests
With the upgrade to clang 7 these started to fail on Linux.

Something changed in clang regarding the processing of our
wrappedQtHeaders/QtCore/qobjectdefs.h. Since we can't rely on the
include paths of Qt in the tests anyway, inline the relevant
preprocessor directives into the test file to make the tests
independent of that.

Change-Id: Iba5cdc5483c3007346346d294374598a75fcb5a1
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-11-27 07:34:10 +00:00
Nikolai Kosjar
bc6c65396f Clang: Fix providing snippets for another case
We have to indicate snippet addition for the PassThroughToLibClang case.

This completes

    commit d946ff5403
    Clang: Fix adding completion snippets after {

Change-Id: Ib543c415d4fdcc99d8bbf4815930f3d8481bc810
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-11-27 07:07:18 +00:00
Thomas Hartmann
323136f403 QmlDesigner: Skip failing test
Change-Id: Ie23bef2faa45cd6ac2b96b49bfc02ce6d55d6639
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2018-11-23 09:25:52 +00:00
Christian Stenger
28352173e4 Tests: Adapt qml-ast2dot
Amends 4646acad0d.

Change-Id: I636300c12e882a431ac103231d9356ce11471ec0
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Marco Benelli <marco.benelli@qt.io>
2018-11-23 09:11:19 +00:00
Marco Bubke
30b522892c UnitTests: Fix build
Change-Id: I9527c97ef2a7360df7b347dc779989c6f6a9710b
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-11-22 13:41:14 +00:00
Marco Bubke
e43aa08ebe ClangPchManager: Store collected build dependencies
Task-number: QTCREATORBUG-21289
Task-number: QTCREATORBUG-21377
Change-Id: Idba57ac09bc5a1f1ccef87f5e33f1ceeaccea372
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-11-21 15:05:23 +00:00