Commit Graph

40457 Commits

Author SHA1 Message Date
Nikolai Kosjar
352e916498 CppEditor: Use Qt::UniqueConnection
Change-Id: Id5a2237b64e4b3c944dc1e83ab7631a25cff5daf
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-02-02 13:29:04 +00:00
Nikolai Kosjar
69bc252e9d ProjectExplorer: Rearrange some statements
There is no need to set up an environment before the cache check.

Change-Id: Ie3cd7b470d364a318624745c9a9c491ec78470cc
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-02-02 13:28:57 +00:00
David Schulz
0a5ac41b23 Debugger: Add debug output for parseAndEvaluate
Change-Id: If5ed128d32c2dff6880a78cc9a5ee535e094da7d
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-02-02 13:06:59 +00:00
David Schulz
bb76740691 Debugger: Use GetOffsetByName for staticMetaObject lookup
Halves the lookup time compared to parse and evaluate.

Change-Id: I8beda23f444c73816a93e38154d2ca502b701fe8
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-02-02 13:06:52 +00:00
David Schulz
1b5d8a84f8 Debugger: Let the python bridge handle reference types
Create pointer and array types in the python code. Uses
the type cache which leads to less type lookup calls.

Change-Id: I970bbb04da2e8051ed66b4b12dfb62076d7f214d
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-02-02 13:06:44 +00:00
Marco Bubke
8f93ec3020 Clang: Use PathString in more cases
Change-Id: I7bee469256a79b384bf7b8c1d5355f1df11c7b24
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-02-02 12:46:51 +00:00
Marco Bubke
01a96537a8 Utils: Move forward declaration of SmallString in an extra header
Change-Id: I6da1cc60d425f654a31570373eb3b4f660d5f975
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-02-02 12:46:44 +00:00
Marco Bubke
76713d6d26 Clang: Use " instead of <> for includes
Change-Id: Ife6ab8b89221dc336b93c1dba3804ba240c3e52e
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-02-02 12:46:29 +00:00
Marco Bubke
5c7f49f278 Clang: Use the whole path in the IncludeCollector
Change-Id: I406f0050b0c244b6c0d1352b5889d4e65a43fa33
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-02-02 12:46:20 +00:00
Marco Bubke
bdfb466cd2 Utils: Add replace for characters
It is much more performant to have a overload of char instead of providing
a string all the time.

Change-Id: I1a4ed82bf056f6af0c1f91c236b3fc30afa7f5d8
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-02-02 12:46:14 +00:00
Tim Jenssen
63e7e83e22 Clang: Filter exception flags and move some more
Change-Id: I3ef6a6bb2297d6965c5c1d457cfe2b354ee3dcdb
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-02-01 14:02:06 +00:00
Marco Bubke
4d9dfc79e1 Clang: Fix warning
Change-Id: Ia12569265b344ea6eacb9c3f54889854a31f0924
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-02-01 13:35:03 +00:00
Marco Bubke
b860d46579 Clang: Handle generated files
We don't handled generated files so we got internal parse errors.

Change-Id: If75e202f93fe3f71f43e3b1d15c0fb77e20c2248
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-02-01 13:11:15 +00:00
Eike Ziller
55400d5bec Merge remote-tracking branch 'origin/4.2'
Change-Id: I8896af66cf8af7436cf3946ddb013742260d50a9
2017-02-01 14:07:43 +01:00
Ulf Hermann
9fc79c43d8 QmlProfiler: Optimize loop over event types
Change-Id: I656ff49a9e62f128c4eed84882245aa490e2960e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2017-02-01 12:56:40 +00:00
Christian Stenger
2a0f70fd75 ClangPchManagerBackend: Fix linking on macOS
Change-Id: I9aad09ca3ef9e6e938cb3ea6041501dc6e89594f
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-02-01 12:14:32 +00:00
David Schulz
228e53aab1 Debugger: Add dumper for unordered_multi(set/map)
Change-Id: Ie1badb0cab0331c35e3094ab121a1a1170cc2bcf
Reviewed-by: hjk <hjk@qt.io>
2017-02-01 10:19:03 +00:00
Filippo Cucchetto
6b8cbb5a63 Nim: Force regular expression optimization on first usage
Change-Id: I33fb19ee04740de78eaa810f7263cbf133a8541f
Reviewed-by: hjk <hjk@qt.io>
2017-02-01 09:13:06 +00:00
Filippo Cucchetto
5a7ba9a541 Nim: Removed useless QLatin1String and QLatin1Char
Change-Id: Id4f5cbd8c9ba515ec1e4acf4c7cbd19f7c3bb519
Reviewed-by: hjk <hjk@qt.io>
2017-02-01 09:12:54 +00:00
hjk
b8c0801e0a Debugger: Run extra post-attach commands as "native" gdb commands
Change-Id: I5c3fac1e03b400f837a090b136ff8aa0ce8e21de
Task-number: QTCREATORBUG-17659
Reviewed-by: Kari Oikarinen <kari.oikarinen@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-02-01 08:10:54 +00:00
David Schulz
763330030f Revert "Cdb: Use decimal prefix for frame number"
This reverts commit ab1b631d76.

I'm currently not sure when to use which prefix and the documentation
isn't clear about that either. Currently reverting this change until it
is known what prefix we have to use here.

Change-Id: I906dcffa1b35e462bb6ed9713405d00d342c8a39
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-02-01 06:21:41 +00:00
Marco Bubke
a0c69c517c Utils: Fix long small string
We used only 6 bit to save the short size but for SmallString with a size
over 64 it is not enough. So we have now to use a uint16 instead of a
uint8 if the size if over 64.

Change-Id: I53558e492b6cb40b739b23a8af83d192a2e11bd2
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-31 16:12:18 +00:00
Marco Bubke
729c535376 Utils: Add intializer_list constructor in SmallString
You can now write

SmallString text = {"Oh ", women[4], " how much I miss you"};

if it can be casted to SmallStringView.

Change-Id: I86b69ee8d735017cac4391e7c4e68355eb5f227b
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-31 16:06:33 +00:00
Marco Bubke
9b4afa01a1 Utils: Improve and fix operators in SmallString
Change-Id: I51f4e647cbd3ada0c3a86d16f40fd8044acead33
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-31 16:06:28 +00:00
Marco Bubke
c02df443a2 Utils: Change SmallString::at from const reference to value
A char is smaller than a pointer.

Change-Id: Icc34b4cb3ccd4bad22e944d1e236d60f51086cfa
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-31 16:06:21 +00:00
Tobias Hunger
01c06c4e84 QMake: Disable "Build File" action when opening Qt Creator
Change-Id: I99e7c7eb04a02a49881e1b465b1d1098511bc8eb
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-31 15:28:37 +00:00
Tobias Hunger
895d2eaa2d QMakeProjectManager: Keep more actions visible in the menu
They are disabled if not applicable.

Change-Id: I4ef150c39272c6e8842678b418581ff399068d47
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-31 15:28:25 +00:00
Tobias Hunger
b139b057a1 QmakeProject: Polish class
Use final, get rid of some useless headers and debug code

Change-Id: Icb1110f6eda4e17d143d8bdf17167d6c3046b884
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-31 15:28:17 +00:00
Marco Bubke
ea4141ee14 Clang: Add Process Generator
So far we only compiled the precompiled headers only sequentially. The
process generator is creating, managing a queue of processes to compile
the PCHs parallel.

Change-Id: I8075def4ef9e6b0191bbd51b3631d1c51ec7b361
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-31 14:18:38 +00:00
Alessandro Portale
54578a5509 QtSupport: Add Qt 5.8 specific versions to the feature system
Qt.Quick 2.8
QtQuick.Controls 2.1

This enables wizards which require Qt 5.8+ specific Qt versions to show
the Qt 5.8+ kits in the kit selection page.

Change-Id: If46090bd240106c197c67f9c2b1908d89c608881
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Michal Klocek <michal.klocek@qt.io>
2017-01-31 13:52:09 +00:00
Marco Bubke
2c55a9c569 Clang: Add timer based path notification compression
QFileWatcher is only reporting one path per signal which is suboptimal if
you change many files at once. This patch is introducing a timer which is
waiting some time time to see if more path changes are reported and is
collecting them in a vector.

Change-Id: I50f7c21186353b199634e7b3cd5a41f8d581a31d
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-31 13:27:24 +00:00
hjk
9678c09355 ProjectExplorer: Remove some unneeded declarations
Change-Id: I7a73db3f01efb66a9de404c5da332e4d9bfbf672
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-01-31 13:04:56 +00:00
hjk
ec77e4030b ProjectExplorer: Also sort list of top level projects (again)
Change-Id: I21dd5ad8c698809d61fc4c94ddcabd5262485f98
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-01-31 13:01:24 +00:00
Orgad Shaneh
3ceb4c5c7a Git: Fix result check on reset
Choosing Discard on Pull, when there are uncommitted changes, fails
when it tries to execute git reset --hard.

This broke in ca7a924a06:
if (!rc) was replaced by if (resp.result == Finished).

Change-Id: I19e080ee08eb52bf2156da7c27ade4b77cf2ece0
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-01-31 10:41:10 +00:00
Marco Benelli
1134c097e2 QmlJs: reformatter for multiline-comments
Fix a reformatter bug that causes wrog indentation of multiline
comments.

Task-number: QTCREATORBUG-17426
Change-Id: I05493638dda0a353f5901fd95f06dc2e8e020237
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
2017-01-31 09:55:37 +00:00
Marco Bubke
58639a4a18 Utils: Fix compile
Change-Id: Idb2c3b8123d9c34259dbb1e9089a14c251c5777d
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-30 15:49:45 +00:00
Ulf Hermann
c70b689526 Unify projectexplorer language IDs
We don't need two IDs for C++ and the QmlJS ID should look the same as
as the others.

Change-Id: Ib9747f6b36a90bb652951d85eec69666615670c4
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-01-30 15:34:46 +00:00
Tim Jenssen
1dd407736a Utils: compile work around for MSVC 2015 update 3
Seems to be a compiler bug and can be removed if fixed in the compiler.

Change-Id: I5c1aad3b135298ced0a9b706f2aab483b04abc56
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-01-30 14:32:47 +00:00
Marco Bubke
c072cdfb88 Clang: Add ClangPchManager
Compiling every header file again and again is quite time comsuming. There
are technics to improve this like preambles(a kind of automated
precompiled header) but they don't share their data between translation
units. This approach provides an automatically generated precompiled
header for every project and subproject to improve the loading time.

Change-Id: I34f5bd4db21951175920e2a9bbf6b97b1d705969
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-30 13:55:58 +00:00
hjk
cbfedd4328 ProjectExplorer: Fix display of .qrc contents
Change-Id: I2779e12daa8a7972380f51b72a56de3466d453a5
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-01-30 13:43:31 +00:00
Tobias Hunger
e8b4e180cd RunConfiguration: Introduce buildSystemTarget()
Introduce a method that maps a RunConfiguration to the build system target
that created the executable.

Implement the method in all RunConfigurations where that makes sense (e.g.
no CustomExecutables).

Change-Id: Ifaac859c2cd9b2806a0d7c185b2239312a67752a
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-01-30 13:27:16 +00:00
Tobias Hunger
836252990a DiffEditor: Fix warning about unused constant
Change-Id: I5a2fbf4e91319d2da41fb364f60688e81498b708
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-01-30 13:17:33 +00:00
Tobias Hunger
cccfcfff2f Nim: Finalize toolchain related classes
Change-Id: Ic4fdcdad0f3f886efbf673d0cb4c165cece21a8f
Reviewed-by: Filippo Cucchetto <filippocucchetto@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-01-30 12:29:39 +00:00
Kari Oikarinen
1e827206f3 ProjectExplorer: Adapt to ProcessHandle move
ProcessHandle was moved to utils in 3e8a1ea7ad,
but 6bcc657adb which was merged to master still
used it from ProcessExplorer.

Change-Id: Iaef3bf4d9415b0ba7411e00d58a2cc25eae6d2df
Reviewed-by: Filipe Azevedo <filipe.azevedo@kdab.com>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-01-30 11:58:31 +00:00
Nikolai Kosjar
dca904e632 Nim: Fix build with qbs
First error is:

    nimtoolchainfactory.cpp:28:26: fatal error: nimconstants.h: No such
    file or directory

Change-Id: I4d440f66dcfe84a492020b5a9ec681de38b050aa
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Filippo Cucchetto <filippocucchetto@gmail.com>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2017-01-30 11:02:31 +00:00
Orgad Shaneh
0aca7561aa ProjectExplorer: Use QEnableSharedFromThis for IDevice
Change-Id: I26d2648f9991fe05f29446ac89109bba3bb77997
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2017-01-30 10:52:46 +00:00
Eike Ziller
f840c6ea56 Use std::(make_)index_sequence
Available in C++14 with GCC>=4.9

Change-Id: I2243ebc7ecda172d5b3233fb0346a062f4d6d759
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-01-30 10:46:35 +00:00
Eike Ziller
af8812b248 Algorithm: Use decltype(auto)
Avoids some code duplication. Available with C++14 / GCC>=4.9.

Change-Id: Iae90466ec9620ffc84b7a45a55490f5fbc8c5b74
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-01-30 10:46:30 +00:00
Eike Ziller
63f66f28ac Use _t versions of various type traits
Available now after switching to C++14 and GCC>=4.9

Change-Id: I44e9859a6abe66db16d77b228466b65eadced8ae
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-01-30 10:46:22 +00:00
Eike Ziller
b299ff19ec Merge remote-tracking branch 'origin/4.2'
Conflicts:
	src/shared/qbs

Change-Id: Ic39fd1c411632f56312fae31c0c88ebc1098b5a4
2017-01-30 10:55:40 +01:00