Commit Graph

271 Commits

Author SHA1 Message Date
Friedemann Kleint
278c0fef74 CDB: Start all CDB breakpoint IDs at 1000.
Avoid clashes with breakpoints resulting from options
(break at functions from options, potentially using bm).

Change-Id: I3746f5a246d7bbeea36df412460edf3f2a90e2c0
Reviewed-by: hjk <qthjk@ovi.com>
2012-12-20 15:34:05 +01:00
Orgad Shaneh
a44aa55502 Add whitespace after control keywords
find -name \*.cpp -o -name \*.h | \
  xargs sed -Ei 's/ (for|foreach|if|switch|while)\(/ \1 (/g'

Change-Id: I9efdff4bf0c8c01a52baaaeb75198483c77b0390
Reviewed-by: hjk <qthjk@ovi.com>
2012-11-28 20:20:46 +01:00
David Schulz
eb39b57e24 Debugger: Dont use win64interrupt.exe in some case
If everything is built with 32 bitness there is no need
to call win64interrupt.exe

Task-number: QTCREATORBUG-7891

Change-Id: I1981b0dfd0ff08ff8acce0e5b81858b00f536ded
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Reviewed-by: hjk <qthjk@ovi.com>
2012-11-19 10:18:49 +01:00
Eike Ziller
fe74a9a722 Merge remote-tracking branch 'origin/2.6'
Conflicts:
	qtcreator.pri
	qtcreator.qbs
	src/plugins/fakevim/fakevimhandler.cpp
	src/plugins/qtsupport/baseqtversion.cpp
	tests/auto/cplusplus/cxx11/cxx11.pro
	tests/auto/cplusplus/cxx11/tst_cxx11.cpp
	tests/auto/icheckbuild/icheckbuild.pro

Change-Id: I3c8351ad35617f56d15b788c8a46d8a6f453ef70
2012-11-09 11:20:10 +01:00
Friedemann Kleint
518b6fcebc CDB: Add setting to ignore first-chance exceptions.
- Add setting for command line option -x.

Task-number: QTCREATORBUG-8141

Change-Id: Id53b9d7d207e2e2c86886db9d0a8c9f5348b659b
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-11-06 12:29:02 +01:00
Friedemann Kleint
41a5461cf2 Debugger: Log exceptions in build pane.
- Introduce constants for task categories, add "RunTime".
- Log exceptions under "RunTime".
- Clear pane on debugger start.
- Add 'first chance'

Task-number: QTCREATORBUG-8141
Change-Id: Icf68def06c42a0f3bb86dcc2ae74750b5397ca52
Reviewed-by: hjk <qthjk@ovi.com>
2012-11-02 16:22:12 +01:00
Friedemann Kleint
2e40c54ea3 Debugger: Remove #ifdef Q_OS_WIN from hostutils.
- Provide stubs for Non-Windows
- Reduce #ifdefs, check Abi if possible.
- Remove unused winGetCurrentProcessId().

Task-number: QTCREATORBUG-8141
Change-Id: I80558ca4e52e87c7371597ea07c091af08097b34
Reviewed-by: hjk <qthjk@ovi.com>
2012-11-02 15:40:41 +01:00
Friedemann Kleint
e3e8cc4386 CDB: Quote executable in debugger launch.
Task-number: QTCREATORBUG-8125
Change-Id: Iaed1a7a4d68c50f8f06dc6be4b9a73933e835988
Reviewed-by: hjk <qthjk@ovi.com>
2012-11-02 08:36:06 +01:00
hjk
0d9a56ab3f Debugger: Rework thread data aquisition
Listen to gdb/MI notifications when possible. This is more
granular, gives access to the thread group id and takes
care of thread changes at any time.

Change-Id: I8c67f6f19b204059deefdf7e07fe3b4ce13ed963
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2012-10-23 19:35:14 +02:00
Eike Ziller
70b5e1f64d Merge remote-tracking branch 'origin/2.6'
Conflicts:
	src/plugins/qt4projectmanager/qt4buildconfiguration.cpp
	src/plugins/qtsupport/baseqtversion.cpp

Change-Id: Id870f70aa35c232dbbd455f83429bab80f266c2d
2012-10-16 17:42:10 +02:00
Erik Verbruggen
f3faef5a1e C++: Fix outdated macro usage info in documents.
Record revisions of documents in macro definitions and usages. Then,
when searching for usages, check the revision of the documents against
the revision of the macros. If they are out-of-sync, repreprocess the
documents to get up-to-date info.

Task-number: QTCREATORBUG-7872
Change-Id: I846bb52ec660024728ab117a9fb7e43382a50e63
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
2012-10-15 10:58:07 +02:00
Eike Ziller
6fd252b0a5 Merge remote-tracking branch 'origin/2.6'
Conflicts:
	share/qtcreator/qml/qmlpuppet/commands/endpuppetcommand.cpp
	share/qtcreator/qml/qmlpuppet/commands/endpuppetcommand.h
	src/plugins/debugger/qtmessageloghandler.cpp
	src/plugins/debugger/qtmessageloghandler.h
	src/plugins/debugger/qtmessagelogwindow.cpp
	src/plugins/madde/maemodeployconfigurationwidget.cpp
	src/plugins/madde/maemodeployconfigurationwidget.h
	src/plugins/remotelinux/deployablefilesperprofile.cpp
	src/plugins/remotelinux/deployablefilesperprofile.h
	src/plugins/remotelinux/deploymentinfo.cpp
	src/plugins/remotelinux/deploymentinfo.h
	src/plugins/remotelinux/deploymentsettingsassistant.cpp
	src/plugins/remotelinux/profilesupdatedialog.cpp
	src/plugins/remotelinux/remotelinuxdeploymentdatamodel.h
	tests/auto/icheckbuild/ichecklib.cpp
	tests/auto/icheckbuild/ichecklib_global.h
	tests/auto/icheckbuild/parsemanager.cpp
	tests/auto/icheckbuild/parsemanager.h
	tests/manual/ssh/tunnel/tunnel.h

Change-Id: I04d7761df6bd936ad00e0547974284c967d39580
2012-10-05 21:20:50 +02:00
hjk
386ca7c8dd Adjust license headers
Change-Id: Ice592c6de9951ee3b2c4cb52ed0bb3b6770e0825
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2012-10-05 17:12:56 +02:00
Christian Kandeler
89fa7823b3 Replace all remaining functions deprecated in Qt 5, if possible.
These are:
    - QInputDialog::getInteger() [-> getInt()]
    - QKeySequence::operator QString() [-> toString()]
    - QRegion::intersect() [-> intersected()]
    - qVariantCanConvert() [-> QVariant::canConvert()]

Plus some left-over occurrences of qFindChild() and
QAbstractItemModel::reset() that were missed by the
respective earlier patches.

All deprecated features still left are not trivially
replaceable, i.e. the code using them cannot be made
to compile with both Qt 4 and Qt 5.

Change-Id: I32541681bbf66b0fef78f5c7025521f9ff84f463
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-25 11:01:04 +02:00
Christian Kandeler
3d9e492860 Do not use the fromAscii() and toAscii() functions.
They are deprecated in Qt 5. Use fromLatin1() and toLatin1() instead. In
Qt 5, these always do the same thing as their "Ascii" counterparts. The
same goes for Qt 4, provided QTextCodec::setCodecForCStrings has not
been set, which it hasn't.

Change-Id: I04edeb376762b6671eff8156094f0d5e2cb8e1ea
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
2012-09-21 21:03:48 +02:00
Christian Kandeler
1b3d637c1b Replace qVariantValue() with qvariant_cast().
qVariantvalue() is deprecated in Qt 5. qvariant_cast() does
the same thing and works in Qt 4 and Qt 5.

Change-Id: I922329d3a47fe394669f5d97a25f0825d3d2dea5
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-20 09:41:37 +02:00
Friedemann Kleint
6886e485de Handle watching/tooltips of C++ editor tokens consistently.
For editor tooltips and the editor context menu
'Watch expression', always try to find a local variable first
and use its expression.

Change the tooltip manager/widgets not to rely on the debugger
model enum and obscure expression, filter by complete iname
instead. Remove obsolete enumeration.

Change gdb's handling of tooltips such that local variables
are displayed immediately without creating additional tooltip
items.

Change-Id: I9b55823428029ba50d84d3a8cab55eb58942e72b
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-03 09:02:56 +02:00
Friedemann Kleint
e67e58378d Debugger: Use gdb's tooltip expression fixup for CDB and editor.
Factor out to watchutils.

Change-Id: I8cf316be819d765dcea964ac6405bfa9b075de59
Reviewed-by: hjk <qthjk@ovi.com>
2012-08-31 08:56:22 +02:00
Friedemann Kleint
5409d2d1d3 CDB: Add setting to add breakpoint at CrtDbgReport().
- Factor out message/tooltips for breakpoints on functions.
- Add stringlist of break functions to CdbOptions.
- Set breakpoints with module, ignore response.

Change-Id: If5cf7647b190057c18d8499b9f4862696610e4f6
Reviewed-by: hjk <qthjk@ovi.com>
2012-08-29 08:18:16 +02:00
hjk
60de95aff6 debugger: Remove dead code
Change-Id: Id59c9df315f7b19cd8a705e4283e749fb71b4dce
Reviewed-by: hjk <qthjk@ovi.com>
2012-08-16 12:35:10 +02:00
hjk
8184d8e703 debugger: simplify DebuggerEngine construction
The master engine pointer can be given later.

Change-Id: I4d72679dcbd5fe7291067a5e78c984d26cc187aa
Reviewed-by: hjk <qthjk@ovi.com>
2012-08-16 11:56:10 +02:00
hjk
081fb1f062 debugger: simplify parameter guessing
With profiles we have more reliable information, no need for some
of the guessing anymore.

Change-Id: I1818fbb112d44c99ef96c8643256432805a1b97b
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
Reviewed-by: hjk <qthjk@ovi.com>
2012-08-16 11:27:16 +02:00
hjk
776fd73e30 debugger: don't store active languages twice
Change-Id: I6517b42b4cfd0d2d919fa2971c3ea0995443cbf3
Reviewed-by: hjk <qthjk@ovi.com>
2012-08-15 13:30:51 +02:00
Tobias Hunger
b8120f29fd Fix support for MSVC2012.
Change-Id: I0ecf6f2d93f1911c8a243f8159e64f7d014bd036
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-07-30 23:31:24 +02:00
Eike Ziller
e0e8cf3ada Contact -> qt-project.org
Change-Id: I7134d7de30bcf9f9dcfad42520dd45ee083a852d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-07-19 13:23:21 +02:00
Friedemann Kleint
7c7e6bd6c4 Debugger: Fix compilation.
Breakage introduced by ded2dd12b8.

Change-Id: I2293024c42c0b237960ad0a1dee06a01dd777ba8
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-06-28 16:32:29 +02:00
hjk
ded2dd12b8 debugger: adjust to profile changes
This replaces the debugger command, sysroot and target abi fields
with a profile id.

Change-Id: I831c42ff8624fcfa520c2f28f6f06d73191b2680
Reviewed-by: Tobias Hunger <tobias.hunger@nokia.com>
2012-06-28 15:30:15 +02:00
hjk
e11a3a7697 debugger: rework WatchModel
It's one model for all locals, watch, return, tooltip and inspector
data. This allows more streamlined code paths and better isolation
of the model data from the WatchHandler. WatchItems are now registered
in a hash indexed by iname, so inames can be used as the primary
handle to watch data in the WatchHandler interface.

Change-Id: Idac0a808b5d785307496d1de4198a1f2e9ce3880
Reviewed-by: Aurindam Jana <aurindam.jana@nokia.com>
2012-05-24 14:33:34 +02:00
Thiago Macieira
ca4a5e7f03 Fix the rest of the warnings about integer sign change with ICC
None of these change the code in any way. The solutions applied are:
 - change the type to a more appropriate one, if possible
 - use ~0 instead of -1 when flags were intended
 - cast a -1 to the proper type otherwise

Change-Id: Ifcc125528f32b8c8f9ab20bea103e2a693045bf8
Reviewed-by: hjk <qthjk@ovi.com>
2012-05-22 18:51:32 +02:00
Eike Ziller
0a0de08efb Merge remote-tracking branch 'origin/2.5'
Conflicts:
	qtcreator.pri
	qtcreator.qbp
	src/plugins/find/treeviewfind.cpp

Change-Id: Iaae61c98938df24bda5521a923303db89eb7f8fe
2012-05-10 08:14:36 +02:00
hjk
dd66fe6c48 Revert "debugger: improve expansion behaviour of pinned tooltips."
This reverts commit 89cee4313c,
as part of the patch breaks QTCREATORBUG-7277.

The GDB case should not filter the Locals model, but the Tooltip model
to display tooltips. CDB has no choice, as the tooltips are expressions,
i.e. cannot be handled, so using the Locals as fall back there is ok.

Change-Id: I196bc683e06f68301bd86aa6fcce14ad2e8c5774
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-05-09 14:11:20 +02:00
hjk
5b0bf61640 qtcassert: move actual printing to separate function and enforce style
This also allows simple setting of breakpoints on failed asserts.

Change-Id: I6dd84cbfaf659d57e39f3447386cebc0221b2b84
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
2012-04-17 09:53:44 +02:00
Aurindam Jana
459f00642b QmlDebugger: Refactor QML Signal Handler
Refactor QML Signal Handler to QML Signal Emit. This is because the
debugger breaks when a matching signal is emitted irrespective of
whether there is a handler connected to the signal.

Change-Id: I852ace75c1962290717ed127ac5938d7505b9a7e
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: hjk <qthjk@ovi.com>
2012-04-16 12:40:59 +02:00
Aurindam Jana
3d32f42b7d Debugging: Pass a DebuggingLanguage arg in executeDebuggerCommand()
Change-Id: I99eedc86c987615072b7400051b61700b98ebab3
Reviewed-by: hjk <qthjk@ovi.com>
2012-04-10 13:12:10 +02:00
Erik Verbruggen
f1b2100e34 Move the ModelManagerInterface out of the CPlusPlus library.
Change-Id: Iffaa18f848a22f6961b49dff048672b194570df6
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
2012-03-14 11:46:24 +01:00
Robert Loehning
9988c471fe Replaced one-char-strings
Change-Id: I0bf982b508a237e5b1e6ba3279cb589bae1b1c1d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-03-07 09:18:15 +01:00
Denis Mingulov
87b1dc25a1 Debugger: use QString::fromLatin1 instead of QString::fromAscii
By source - latin1 is really expected as there is no any check
or usage of QTextCodec::setCodecForCStrings() currently.

QString::fromAscii() might break 'Latin1' input in some cases.

A quote from documentation about QString::fromAscii():

"Note that, despite the name, this function actually uses the
codec defined by QTextCodec::setCodecForCStrings() to convert str
to Unicode. Depending on the codec, it may not accept valid
US-ASCII (ANSI X3.4-1986) input. If no codec has been set, this
function does the same as fromLatin1()."

Change-Id: I49cf047ca674d2ec621b517c635d1927bb2e796f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: hjk <qthjk@ovi.com>
2012-02-16 10:27:04 +01:00
Erik Verbruggen
3fa55b7ab9 Removed module names from #include directives.
Getting the #include directives ready for Qt5. This includes the
new-project wizards.

Change-Id: Ia9261f1e8faec06b9285b694d2b7e9a095978d2b
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
2012-02-15 16:24:46 +01:00
Friedemann Kleint
38510a482d Debugger: Fix interrupting code.
- Windows: Always use DebugBreakProcess if Qt Creator is compiled
  64bit. Else always use win64interrupt.exe if Qt Creator
  is a WOW64 application.
- Remove redundant code (procinterrupt/hostutils, gdb adapters).
- Give interruptProcess an errorMessage parameter such that it can
  be used by all C++ engines and a proper error is displayed.
- Improve error messages.
- Build win64interrupt if target architecture is 64 bit (clean tools
  profile, add a profile), borrowing the check from
  qtcreatorcdbext.pro.

Change-Id: I2a6caf98e46051c49c84e1f3aac4c8d2aba66e8b
Reviewed-by: David Schulz <david.schulz@nokia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-02-02 16:25:42 +01:00
Friedemann Kleint
c27a463fe7 Debugger: Add Disassembling of functions.
- Add "Disassemble function..." action with dialog for name
  to stack window.
- Add "Disassemble" with function name from code model to
  the Editor context menu.
- Change the engines to be able to disassemble a function without
  address.

Change-Id: I812f4672d97d9a866ee7f5a38dbd18b2876bccfa
Reviewed-by: hjk <qthjk@ovi.com>
2012-02-01 17:57:43 +01:00
hjk
2931a499e6 Long live the king!
Change-Id: I2b72b34c0cfeafc8bdbaf49b83ff723544f2b6e2
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
2012-01-26 19:55:36 +01:00
David Schulz
e7e74db758 Edit debugger so win64interrupt is called
when trying to debug a 64bit application under windows.

Task-number: QTCREATORBUG-2521
Change-Id: I38922a6bed09640ce88184e6913a9fbb1d7433de
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
Reviewed-by: hjk <qthjk@ovi.com>
2012-01-25 12:16:00 +01:00
hjk
4a21f0c3c8 Use new static ICore interface.
Change-Id: I9b690d9b150c8d162b15370f9f8986267c9128f1
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
2012-01-24 18:48:47 +01:00
hjk
7201923562 debugger: move isCppBreakpoint to Breakpoint
Change-Id: I241401fa010166982e5a95a699c99fbaa87188ef
Reviewed-by: hjk <qthjk@ovi.com>
2012-01-24 17:10:28 +01:00
hjk
e8598fa3dd debugger: compile fix
Un-breaks cdb engine after 24177e67dea.

Change-Id: Ibf99e1de4178a3d92a213266ecae490db437ca7a
Reviewed-by: hjk <qthjk@ovi.com>
2012-01-16 17:37:18 +01:00
Leandro Melo
3b67e5dd37 Merge remote-tracking branch 'origin/2.4'
Conflicts:
	src/plugins/projectexplorer/gcctoolchain.cpp

Change-Id: I516c496175afe94c57b8a1dd978d9c5cccc44610
2011-12-21 17:17:14 +01:00
Friedemann Kleint
a92e38f47f Debugger: Compile with QT_NO_CAST_FROM_ASCII.
(except gdbmi.cpp, name_demangler.cpp). Remove some unneeded
conversions, change some maps to take QByteArray keys.

Change-Id: I010f1251998a441fe5c8c87901b1e0c277c0391c
Reviewed-by: hjk <qthjk@ovi.com>
2011-12-21 14:07:12 +01:00
Friedemann Kleint
d5b655131b Debugger[CDB]: selectThread(): Remove call to resetLocation().
It is unneeded and causes the thread window to become disabled.

Change-Id: I9a3621bc574cf6774b401de7eb925741db3b9f35
Reviewed-by: hjk <qthjk@ovi.com>
2011-12-21 10:44:18 +01:00
hjk
89cee4313c debugger: improve expansion behaviour of pinned tooltips.
Task-number: QTCREATORBUG-6554
Change-Id: I26ea4e5eb5826baaa6fd3bd4b199dd34e88703e0
Reviewed-by: hjk <qthjk@ovi.com>
2011-12-13 20:53:08 +01:00
Kai Koehne
66949f2b45 Debugger: Hide memory related actions in context menus for QML only
Change-Id: I29f09f983146fff3301426703db0b93090c6507c
Reviewed-by: hjk <qthjk@ovi.com>
2011-12-01 16:34:51 +01:00