Commit Graph

7307 Commits

Author SHA1 Message Date
Nikolai Kosjar
de5cbacae5 Clang: Rename JobRequest::Requirements to ExpirationsReasons
...to avoid ambiguity in regard to a new enum in a follow-up change.

Change-Id: I4f732b5200ed674b6708510ac8de0a795afe52da
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-06-14 11:48:54 +00:00
Marco Bubke
43d6726c70 Clang: Add equal operators for ClangString
Converting them in a Utf8String in an inner loop can be quite heavy.

Change-Id: I4f2ccde47a6e3ca08ed054462eb7772ded9e55c9
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-06-14 10:14:07 +00:00
Nikolai Kosjar
e6bf399003 Clang: Stop highlighting keywords in preprocessor directives
Task-number: QTCREATORBUG-15516
Change-Id: I30046ae7c1a73144985639800227012bf5a4e357
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-06-14 10:00:02 +00:00
Robert Loehning
6c6c4c72c6 Squish: Add expected project tree for cmake >= 3.7
Change-Id: I5a47e5c3da4bfd9db531957212b0f29815b1eb1a
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-06-12 12:16:40 +00:00
Orgad Shaneh
a9145e67ba Debugger: Prettify values for enum bitfields
Change-Id: I55329bba1864c9ebbbcb3b3bf1b940346507f8cd
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-06-12 10:40:46 +00:00
Orgad Shaneh
6b0e1bc5f8 Merge remote-tracking branch 'origin/4.3' into master
Change-Id: I83af635dcac98e4fd78b21d8dd9dc3a27a4fdf94
2017-06-12 10:01:16 +03:00
Robert Loehning
78ab3c61f5 Squish: Don't try building with cmake < 3.7
Task-number: QTCREATORBUG-18290
Change-Id: I5b14d781e7e5382605d7e931d0461efa1b317397
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-06-09 10:18:34 +00:00
Ivan Donchevskii
9a0eca15c5 Clang: fix completion after forward-declared class
Do not complete -> and . with global completions if
foo is a ptr/ref to forward-declared class.

Change-Id: I41e6745ffb07be1d973fe6a8132824f1b3bf7fb1
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-06-09 07:05:25 +00:00
Ivan Donchevskii
78db7d7ed2 Clang: turn off delayed template parsing
Fix templates highlight and completion on Windows
Add UI to turn on/off delayed parsing (off by default)

Task-number: QTCREATORBUG-17222
Change-Id: I0cd5e0bcfff2789cd938e4096829f777ff15957a
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-06-08 10:53:31 +00:00
Robert Loehning
7a068e494e Squish: Update speedcrunch's tree in tst_openqt_creator
Change-Id: I8f834a807f2dd10bed87829bf41c02e40913cd74
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-06-08 10:48:29 +00:00
Robert Loehning
600dd3a585 Squish: Update expected project trees when opening qtcreator
- Update Creator's sources to v4.2.2
- Update project trees to what Creator 4.3 shows

If needed, two separate changes are in codereview.

Change-Id: I16ee341653c8b916b15208f16699c0d4cbf6df05
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-06-07 13:27:24 +00:00
Robert Loehning
feaff29b78 Squish: Use cdb with Creator's bitness
Normal builds of Creator can only use cdb with the same bitness.
In the official packages this is being solved by sharing
qtcreatorcdbextXX between 32- and 64-bit builds.

Change-Id: Ib31e4d71789065bef908bf13569de4284ae20de9
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-06-07 10:20:57 +00:00
Orgad Shaneh
89057b552b Merge remote-tracking branch 'origin/4.3'
Change-Id: I56004e3ec9dc9d92d33bdae438c4f7e069eccc45
2017-06-02 15:13:51 +03:00
Nikolai Kosjar
a3a62e78f7 Clang: Fix highlighting of function in using declaration
Change-Id: I0f646ce22cdc95e5932650a3fb2fe34b8d4a89a3
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-06-01 13:33:07 +00:00
Nikolai Kosjar
e6c8fbfd92 Clang: Fix highlighting for partial specialization
Change-Id: I53f6a87064d45a3a68394d1b3bc0d767b91a9d11
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-06-01 13:33:00 +00:00
Robert Loehning
84907a7d65 Squish: Fix __handeColorTips__ for Qt >= 5.8
Explicitly selecting the right overloading for setNamedColor

Change-Id: Id5aad47ec84b672d70f393456054d4cd779b7a21
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-06-01 09:09:36 +00:00
Robert Loehning
5ceb390b60 Squish: Update window title
Change-Id: Idff71e0d250b31436a59e10c6ab00f7d459ab89d
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-06-01 09:09:17 +00:00
David Schulz
2e203e868f Debugger: fix regex matching local enum type in dumper test
Change-Id: I2a0002be23bca2d0dc29273428772b38189f18d6
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-06-01 05:33:39 +00:00
Orgad Shaneh
ac2b2d6139 Debugger: Add a test for enum bitfield
Change-Id: I5e11dd39941b5b4fe7d27e329b5268a23e7a72b1
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-31 18:13:05 +00:00
hjk
c34ff88c5a Debugger: Add an auto test for typedefs with unnamed enums
Change-Id: I7ed68c954265d4f25aec98d2d833df01a9ef9153
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2017-05-30 10:38:02 +00:00
David Schulz
2317d06a80 Debugger: Add DumperOptions to the cdb fetch command
Change-Id: Ibe05f82997b57cfffb26bfb5c67681be24419139
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-05-30 08:40:33 +00:00
Orgad Shaneh
8430da3bf7 Merge remote-tracking branch 'origin/4.3' into master
Change-Id: I01ab8c85ea3372b6dce4142ddb9cf92d903ffca6
2017-05-23 23:41:40 +03:00
Nikolai Kosjar
1a9808d393 Clang: Remove unused functions
Change-Id: I66e990dfce5196da48cdf158cf7e5a4050565670
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-23 10:52:41 +00:00
Eike Ziller
db11c01df8 Clang: Fix highlighting of primitive types
libClang categorizes these as keywords, so we need to check
if a keyword is actually a primitive type, and use that.

Task-number: QTCREATORBUG-17867
Change-Id: I354bb0422505ed7732a0799d9c86d3acfdeb0785
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-05-23 08:41:42 +00:00
Eike Ziller
f51fbd68e1 SyntaxHighligher: Remove the need to specify format for spaces
It has all means to know itself.

Change-Id: I464c195c5ee47e5fc58414a280c166e4a332c588
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-23 08:34:53 +00:00
Eike Ziller
cf57965ebc Simplify text format handling in syntax highlighters
Pass the mapping from custom enum to text style in form of a function,
which then can use a switch which is checked by compilers, and
avoids the need to lookup a different enum somewhere else to find
out what the mapping actually is.
That mapping is cached to keep performance as before.

Also, most highlighters created an enum just for the purpose of mapping
to text styles, basically creating duplicated subsets of text style like
enums everywhere. Instead provide a default, identity mapping from text
styles to text styles.

Change-Id: I2ea1ca702b99e36b8742dfda510b1b2753f0a1c2
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-23 07:47:22 +00:00
Eike Ziller
4e35cc2ea8 Fix that raw string literals that close on same line were not terminated
With the built-in model, which affects basic highlighting.

Task-number: QTCREATORBUG-17720
Change-Id: I7369d7288d9c2c8e5ef36fc27549121014527e58
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-05-19 13:50:42 +00:00
Robert Loehning
ae4be183fd Squish: Tune tst_codepasting to working cases
Change-Id: Iaa7ebcbc20f096d1776be13c62978d6851707d39
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-05-18 12:35:42 +00:00
Robert Loehning
d9e1c77c01 Squish: Shorten object names
Change-Id: Ic57dce86bccae23a2edeee42207a872793feffa0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-05-18 12:26:18 +00:00
Orgad Shaneh
6d6c0c81ed Tests: Minor cleanup in debugger/simple_test_app
* Replace double casts with ll suffix, which resolves the warning.
* Replace recurring shifts by using a local variable.

Change-Id: I344fab50619dc27e68a151abb2f3061543c36662
Reviewed-by: hjk <hjk@qt.io>
2017-05-16 14:18:49 +00:00
hjk
99ac955664 Debugger: Fix display of pointers as arrays
Task-number: QTCREATORBUG-18204
Task-number: QTCREATORBUG-17803
Change-Id: I4efe359c206b53ef773127cf29107d3cce720819
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-05-16 11:55:58 +00:00
Eike Ziller
83b8c8fc15 Reduce CPU load of test parsing
Use a thread pool with reduced max thread count.

Task-number: QTCREATORBUG-18185
Change-Id: I18bd3de82365edaf21d8dcf9c89035da1ac74756
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-05-16 10:46:13 +00:00
Eike Ziller
64b19af7dd Merge remote-tracking branch 'origin/4.3'
Conflicts:
	qbs/modules/qtc/qtc.qbs
	qtcreator.pri

Change-Id: I6d89ea588de955f5d878500b59285d3adde6c77d
2017-05-15 15:31:55 +02:00
Robert Loehning
47198b44e4 Squish: Exclude HTML when reading version from dialog
Change-Id: I2e73a27aaa3b8c28cdce93576a8cdfc861e37b8d
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-05-12 11:30:14 +00:00
Nikolai Kosjar
64ec695566 Clang: Show function signature hint for constructors and functors
For "foo(|" [1] we requested a completion from libclang with the cursor
position just before "foo" and then filtered the function declarations
for functions matching the name "foo". This worked fine for ordinary
functions, but obviously not for constructors and functors.

Recent versions of libclang support proper function call completion with
XCursor_OverloadCandidate, so make use of that.

[1] '|' represents the cursor position

Task-number: QTCREATORBUG-14882
Task-number: QTCREATORBUG-14884
Change-Id: I9d31b3960ccff6a8b9440dbcb7ff9f5ca9f61266
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-05-11 11:54:09 +00:00
Christian Stenger
bae0368034 Squish: Fix switching to build or run settings
If too many kits are present and/or the screen resolution is
too low to have QC having the correct minimum windows size
Squish fails to click on the items as it might be necessary
to scroll to them to have them really (user-) visible.
There is an obvious difference between 'visible' for Squish
and 'visible' for the interacting user.

Change-Id: Id658a323fcf2ae3882b225c6ce9383ed2c876e81
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2017-05-11 05:48:21 +00:00
Robert Loehning
d7f79349ed Squish: Verify project was found when adding file
Change-Id: I313d1ba1b621d45620bf613760cefdf0a2d2341c
Task-number: QTCREATORBUG-17994
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-05-10 14:01:16 +00:00
Robert Loehning
1957c8bc66 Squish: Update tst_opencreator_qbs
Change-Id: I2aac18170ee7d4490852e587b2c016f913b242e0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-05-09 14:21:03 +00:00
Eike Ziller
6e8ee7479e Merge remote-tracking branch 'origin/4.3'
Conflicts:
	src/plugins/debugger/cdb/cdbengine.cpp

Change-Id: Ib9aeccc4162c43e9ee3d85847d96678045625dd0
2017-05-09 15:07:30 +02:00
Robert Loehning
9bb80c0e80 Squish: Increase timeout for cloning in tst_git_clone
Change-Id: Ib894ae05e8049331115ee34514d7638815408065
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-05-08 11:41:47 +00:00
Robert Loehning
d10b9390c8 Squish: Update tst_git_local
Format of .pro file changed slightly

Change-Id: I026057ecc76c082ddac06e81b36c0b3b62629da0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-05-08 09:15:27 +00:00
Orgad Shaneh
279192f17a Dumpers: Fix operator + for pointers
Add an extensive unit test to prevent future regression.

Change-Id: I38b74f9b4f5893285e9afff2ddecaaad106f4114
Reviewed-by: hjk <hjk@qt.io>
2017-05-08 06:58:48 +00:00
Nikolai Kosjar
c1d7f4091e Clang: Rename/remove projectPartId
Change-Id: I91e95acd37152eda4e25c0b8abf46d36523fd2b9
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-05 12:11:01 +00:00
Nikolai Kosjar
cf0e3f2db3 Clang: Fix updating supportive translation unit
...with new project arguments.

Reproduce with:
 1. Open a file with some #ifdef
 2. Edit the file, e.g. type space.
 3. Change the build configuration so that the highlighting flips in the
    editor.
 4. Edit the file again, the configuration flips again [repeat].

Change-Id: Ib97c18fc46538d74c63972e682a348ae2736a4e6
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-05 12:10:56 +00:00
Nikolai Kosjar
ac59e2be40 Clang: Move createJobRequest into Jobs
This simplifies the high level client ClangCodeModelServer and removes
quite some duplication in tests.

Change-Id: I4c6ab8646c8728990ebaca2b920ae514e949c54a
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-05 10:39:39 +00:00
Nikolai Kosjar
b9c76d5218 Clang: Rename reparseNeeded to isDirty
...because the flag can be set for needed parses, too.

Change-Id: I8b328afefb282cb6bd1cf88711af3d08a56808db
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-05 08:18:08 +00:00
Nikolai Kosjar
e811ac4bfe Clang: Use class enum in Document
Change-Id: I754eaf185d10b61db5bd5f622d1912c53f71e79b
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-05 08:17:58 +00:00
Nikolai Kosjar
0e5fdb7fe3 Clang: Tests: Clean up CompletionChunksToTextConverter
* Remove pointless declarations.
* Remove duplicated test.
* Fix whitespace.

Change-Id: I08102f8313b87dc87a44d96ff9c77205ccbb1a01
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-04 10:18:31 +00:00
Nikolai Kosjar
bc9afe3bbb Clang: Tests: Fix test names in ClangCompletionContextAnalyzer
Change-Id: I5a1b322957edb30cd4fe5a50deb50255da18cf8d
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-04 10:18:24 +00:00
Eike Ziller
105b69836c Merge remote-tracking branch 'origin/4.3'
Conflicts:
	tests/auto/debugger/tst_dumpers.cpp

Change-Id: Id8b53b000f94a1b5ab923db79f67bad3276d09dc
2017-05-04 10:03:50 +02:00