summaryrefslogtreecommitdiff
path: root/src/libs/cplusplus/LookupContext.h
Commit message (Collapse)AuthorAgeFilesLines
* C++: Remember the class a ClassOrNamespace is based onNikolai Kosjar2013-11-121-1/+7
| | | | | Change-Id: I0d333ff9489e46c4fa1923d70ca950f67ffa3f44 Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* C++: add support for local typesPrzemyslaw Gorszkowski2013-06-181-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change addes support for class, enum definition inside blocks({}) or functions, e.g.: void f() { struct S { int bar; }; S s; s.bar; } It fixes: * code completion * highlighting * follow symbol * marking * find usages It fixes also problem with namespace aliases inside blocks or functions. This change can have also impact on performance(there are additional processing) Task-number: QTCREATORBUG-166 (namespace aliases inside function/block) Task-number: QTCREATORBUG-3620 Task-number: QTCREATORBUG-6013 Task-number: QTCREATORBUG-8020 Change-Id: Iaea6c6dfe276f1d7b2279b50bdd2e68e375d31eb Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* C++: Handle recursive using/typedef declarationsNikolai Kosjar2013-06-111-1/+3
| | | | | | | | Remember using/typedef declarations we have already looked up and stop if we try it again. Change-Id: I91bf0aef4df18539a47d015f0113543aef1f692a Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* C++: instantiate template functionsPrzemyslaw Gorszkowski2013-05-241-0/+3
| | | | | | | Task-number: QTCREATORBUG-9170 Change-Id: I4cac9124558c1d4f0722192246f3fbeea61d3d7d Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* Merge branch '2.7'Oswald Buddenhagen2013-05-151-6/+3
|\ | | | | | | | | | | | | | | | | | | | | | | Conflicts: doc/src/qtquick/qtquick-components.qdoc doc/src/qtquick/qtquick-designer.qdoc qtcreator.pri qtcreator.qbs src/plugins/cppeditor/cppinsertdecldef.cpp src/plugins/qnx/qnxruncontrolfactory.cpp Change-Id: I0a37a07c42719bc0d9ef5b3ac4641d01a63c0d88
| * C++: Fix crash in code completion.Erik Verbruggen2013-05-031-6/+3
| | | | | | | | | | | | | | | | | | | | Caused by a dangling pointer of a template instantiation which had been cloned into the wrong control. The fix is to remove that control and refer to the control of the bindings (which is the correct one). Change-Id: I951a60f2e613aae1e4ac901ce99c820212018709 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com> Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* | C++: fix highlighting type when there is using Namespace::ClassPrzemyslaw Gorszkowski2013-05-021-0/+2
| | | | | | | | | | | | | | | | | | If type is not found we try to find 'using' declaration for this type. Task-number: QTCREATORBUG-7903 Change-Id: I569db9e1a8504a5da3115ebbed2e823d5924f6ca Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* | Revert "C++: fix support for typedef of templated typedefs"Nikolai Kosjar2013-04-231-5/+0
| | | | | | | | | | | | | | | | | | | | Still crashes when opening the Qt Creator project, g++ (Ubuntu/Linaro 4.7.2-2ubuntu1) 4.7.2 (Ubuntu 12.10). This reverts commit 564c9b2842663062658a0febdcc5787098d871b2. Change-Id: Ief5c0aad463d245f68805f747d277ac298796c3d Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
* | C++: fix support for typedef of templated typedefsPrzemyslaw Gorszkowski2013-04-221-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | Fix: * code completion * follow symbols * find usages Task-number: QTCREATORBUG-8375 Change-Id: Ia40273fec3dead76acad4695b852a9e53065d8a7 Reviewed-by: Petar Perisin <petar.perisin@gmail.com> Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* | Revert "C++: fix support for typedef of templated typedefs"Erik Verbruggen2013-04-191-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Infinite recursion in the lookup of: struct common_type { public: typedef typename common_type<typename common_type<_Tp, _Up>::type, V>::type type; }; This reverts commit 9a56ce4e85bec81c521258f44e9076d0bc9cce92 Change-Id: I675fe39018789cd04127d105eb983d2cb7798ca5 Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* | C++: fix support for typedef of templated typedefsPrzemyslaw Gorszkowski2013-04-191-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | Fix: * code completion * follow symbols * find usages Task-number: QTCREATORBUG-8375 Change-Id: I6f35e809ba15f224c5a6d9b2fcfc18dbfba55411 Reviewed-by: Sergey Shambir <sergey.shambir.auto@gmail.com> Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* | C++: improve support for anonymous classesPrzemyslaw Gorszkowski2013-04-191-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix: * highlighting * find usages * follow symbol * code completion Task-number: QTCREATORBUG-6497 Task-number: QTCREATORBUG-8963 Task-number: QTCREATORBUG-3610 Task-number: QTCREATORBUG-7579 Change-Id: I3dcaf1c515d0199c3e6bee72284fbb40064686ee Reviewed-by: Petar Perisin <petar.perisin@gmail.com> Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com> Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* | Merge remote-tracking branch 'origin/2.7'Eike Ziller2013-04-111-1/+1
|\ \ | |/ | | | | | | | | | | | | Conflicts: src/plugins/cpptools/cppchecksymbols.h src/plugins/qmldesigner/components/formeditor/resizecontroller.cpp Change-Id: I887ba071fa637ad44e39bcae581738fa078a6612
| * C++: fixed operator arrow of nested class of enclosing templatePrzemyslaw Gorszkowski2013-04-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Fixed: * code completion * highlighting * find usage * follow symbol Task-number: QTCREATORBUG-9005 Change-Id: I3fcc2638482ca1071c1aa7b6aab0d4dd128595bb Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* | fix include style relating to cplusplus librariesOswald Buddenhagen2013-04-031-6/+9
|/ | | | | | | | | | | ... and adjust INCLUDEPATH accordingly. while i'm at messing with include statements, also re-order the include blocks according to policy and sort them within bigger blocks. Change-Id: I7762abfd7c4ecf59432b99db2f424e4fa25733a5 Reviewed-by: Tobias Hunger <tobias.hunger@digia.com> Reviewed-by: Eike Ziller <eike.ziller@digia.com>
* C++: cache fully qualified name lookupus in scopes.Erik Verbruggen2013-03-051-1/+16
| | | | | | | | Task-number: QTCREATORBUG-8724 Change-Id: I00b0712cf5514bcec04b674052ad4b5b66cca506 Reviewed-by: Przemyslaw Gorszkowski <pgorszkowski@gmail.com> Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
* C++: performance improvement for template instantiationPrzemyslaw Gorszkowski2013-02-271-0/+1
| | | | | | | Add cache for instantiated instantiations in base template class. Change-Id: I5c457ea4dfeab72cc3910f0092ca1bc14b8aa1ac Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* C++: fix instantiation of template special. with pointer argumentPrzemyslaw Gorszkowski2013-02-211-4/+5
| | | | | | | | | | | | | | | | Fixed code completion for instantiation of template specialization with argument as pointer, e.g.: template <typename T> struct Template { T variable; }; template <typename T> struct Template<T *> { T *pointer; }; Template<int*> templ; templ.pointer; Change-Id: I7c79fe0cd7119b1208f064aece0cafdf50e1a012 Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* Merge remote-tracking branch 'origin/2.6'Oswald Buddenhagen2013-01-311-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/autotoolsprojectmanager/AutotoolsProjectManager.pluginspec.in src/plugins/debugger/qtmessageloghandler.cpp src/plugins/debugger/qtmessagelogwindow.cpp src/plugins/madde/maemodeployconfigurationwidget.cpp src/plugins/qmldesigner/components/integration/designdocumentcontroller.cpp src/plugins/qmldesigner/designercore/include/widgetqueryview.h src/plugins/qmldesigner/designercore/metainfo/metainfoparser.cpp src/plugins/qmldesigner/designercore/model/modelnodecontextmenu.cpp src/plugins/qmldesigner/designercore/model/modelnodecontextmenu.h src/plugins/qmlprojectmanager/qmlprojectapplicationwizard.cpp src/plugins/qnx/bardescriptormagicmatcher.h src/plugins/qt4projectmanager/profilekeywords.cpp src/plugins/remotelinux/deployablefilesperprofile.cpp src/plugins/remotelinux/deployablefilesperprofile.h src/plugins/remotelinux/deploymentinfo.cpp src/plugins/remotelinux/deploymentsettingsassistant.cpp src/plugins/remotelinux/profilesupdatedialog.cpp tests/auto/icheckbuild/ichecklib.cpp tests/auto/icheckbuild/parsemanager.cpp tests/auto/icheckbuild/parsemanager.h Change-Id: Ie465a578446a089e1c502d1cb1096e84ca058104
| * Incremented year in copyright infov2.6.2Robert Loehning2013-01-291-1/+1
| | | | | | | | | | Change-Id: Ic6a9ff0359625021ebc061d22db6811814534205 Reviewed-by: Kai Koehne <kai.koehne@digia.com>
| * Fix: no scope walking for name resolving after MemAccess operatorErik Verbruggen2012-11-221-0/+1
| | | | | | | | | | | | | | | | | | | | | | Change-Id: Ic093079fa65d8d749911fd9f5b0f629e9fe68a1e Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com> Conflicts: tests/auto/cplusplus/findusages/tst_findusages.cpp Change-Id: I87d305e2d68582aa00b92f9599368615cd76ec74 Reviewed-by: Eike Ziller <eike.ziller@digia.com>
* | C++: Fix code compl. for instantiation of template specializationPrzemyslaw Gorszkowski2013-01-301-1/+2
| | | | | | | | | | | | | | | | | | | | | | It works for full specialization. Instantiate of the partial specialization has to be implemented(finding appropriate partial specialization-on going) Added unit test. Change-Id: I8ef5ea963e7c665e0d67d390b3a833486773dab0 Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* | C++ editor: support nested class of enclosing templatePrzemyslaw Gorszkowski2013-01-221-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | Fixing: * highlighting * tooltips * find usage * selecting Task-number: QTCREATORBUG-8245 Change-Id: I6e900799e43126706125b7e424567fca2b2c223e Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
* | C++: Fix code completion for nested classesPrzemyslaw Gorszkowski2012-12-201-4/+39
| | | | | | | | | | | | | | | | | | | | Fix code completion for nested classes when enclosing is template class. Unit tests Task-number: QTCREATORBUG-8245 (only standalone) Change-Id: Ib31ad4b799db927b56debd4dc3e7403404c1839d Reviewed-by: hjk <qthjk@ovi.com>
* | Fix: no scope walking for name resolving after MemAccess operatorErik Verbruggen2012-11-211-0/+1
| | | | | | | | | | Change-Id: Ic093079fa65d8d749911fd9f5b0f629e9fe68a1e Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
* | Refactoring LookupContext.hPrzemyslaw Gorszkowski2012-11-191-35/+1
| | | | | | | | | | | | | | Extracting class AlreadyConsideredClassContainer to separate file Change-Id: If3bb89df5ce0bae87723ad4ecab7118337df0655 Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* | Merge remote-tracking branch 'origin/2.6'Eike Ziller2012-11-091-1/+1
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | 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
| * Fix crashes while parsing template parameters in C++ codePrzemyslaw Gorszkowski2012-10-311-1/+1
| | | | | | | | | | | | | | | | | | | | | | AlreadyConsideredClassContainer has to be cleared when there is no base class Task-number: QTCREATORBUG-8128 Change-Id: Iad82f2efc361aeb38c88a751c86aa572d373557a Reviewed-by: Cristian Tibirna <tibirna@kde.org> Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: David Schulz <david.schulz@digia.com>
* | C++11: Correct scoping for scoped enums.Christian Kamm2012-10-311-2/+2
|/ | | | | | | Fixes completion, highlighting and find usages. Change-Id: I1ea12c6a9c7a4f8ba0f9d55e31d6b7986233e7d8 Reviewed-by: hjk <qthjk@ovi.com>
* Fix crashes when cyclic inheritancePrzemyslaw Gorszkowski2012-10-241-1/+9
| | | | | | | | | | More complex situation. Base class is a template and derived class is a template. Task-number: QTCREATORBUG-8072 Task-number: QTCREATORBUG-7962 Change-Id: I7e8aa727fccd2bd4a779e6fe781553cd12196682 Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* C++: Fix typedef resolving when templates are involved.Erik Verbruggen2012-10-191-0/+4
| | | | | | | | Task-number: QTCREATORBUG-7978 Change-Id: I27e6ebe56e410d509580a1e00f8986642cacc5ba Reviewed-by: David Schulz <david.schulz@digia.com> Reviewed-by: Eike Ziller <eike.ziller@digia.com> Reviewed-by: Christian Stenger <christian.stenger@digia.com>
* C++: fix member rewriting when doing template instantiation.Erik Verbruggen2012-10-111-6/+12
| | | | | | Task-number: QTCREATORBUG-7964 Change-Id: Icc7d87bb4f2d1ab0560a6c06187d9c23da9fe3e9 Reviewed-by: David Schulz <david.schulz@digia.com>
* Adjust license headershjk2012-10-051-21/+20
| | | | | Change-Id: Ice592c6de9951ee3b2c4cb52ed0bb3b6770e0825 Reviewed-by: Eike Ziller <eike.ziller@digia.com>
* Fix crashes when cyclic inheritancePrzemyslaw Gorszkowski2012-10-021-0/+30
| | | | | | | Task-number: QTCREATORBUG-7933 Change-Id: I98469a092ff3ff0acc69800e9aade4ebb268332a Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* C++: Fix crash when deducing auto (with invalid ids)Leandro Melo2012-09-041-0/+1
| | | | | | | Task-number: QTCREATORBUG-7801 Change-Id: I61436148ed1428a50a6840ba9109310a57dabaa4 Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
* C++: Improve lookup - collect more valid itemsLeandro Melo2012-09-041-0/+4
| | | | | | | | | | | | | | | | There was a fix for QTCREATORBUG-7730 in the case of nested forward declarations in commit 74a458bca09b5bd170b64e04bb68c8d958c61932. However, it introduced regressions and actually didn't solve the issue, since the behavior was hidden by another error fixed later. The patch should properly fix the issue and the regression pointed in QTCREATORBUG-7777. Task-number: QTCREATORBUG-7730 Task-number: QTCREATORBUG-7777 Change-Id: I27397fefdc7cc9a60111761df1f76a01407886f7 Reviewed-by: Christian Kamm <christian.d.kamm@nokia.com> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* C++: Completion for templates as base classesLeandro Melo2012-08-231-1/+2
| | | | | | | | | | This fixes a variety of issues regarding class completion when templates are used as base classes. The test cases show examples. Task-number: QTCREATORBUG-4357 Change-Id: I764d5ce817a78e1b19336e5beab758ca9e10f34b Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
* Contact -> qt-project.orgEike Ziller2012-07-191-3/+1
| | | | | Change-Id: I7134d7de30bcf9f9dcfad42520dd45ee083a852d Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Removed module names from #include directives.Erik Verbruggen2012-02-151-1/+1
| | | | | | | | Getting the #include directives ready for Qt5. This includes the new-project wizards. Change-Id: Ia9261f1e8faec06b9285b694d2b7e9a095978d2b Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
* Long live the king!hjk2012-01-261-1/+1
| | | | | Change-Id: I2b72b34c0cfeafc8bdbaf49b83ff723544f2b6e2 Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
* all: s/info@qt.nokia.com/qt-info@nokia.com/hjk2011-11-031-2/+2
| | | | | Change-Id: If18afb5d4665924e7d9250dccbc60a65e6daa75e Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
* C++ insert def: Fix bug when minimizing name.Christian Kamm2011-10-311-2/+1
| | | | | | | | | | Constructors would not get the correct name before. Now rewriting the function's name is not done by going through the 'rewrite type' func- tionality but rather by minimizing the symbol's name directly. Task-number: QTCREATORBUG-6223 Change-Id: I3c25e414337937f5dd0f54570c899ca2ca21d2ef Reviewed-by: Leandro T. C. Melo <leandro.melo@nokia.com>
* C++: Fix completion for typedefs for templates in namespaces.Christian Kamm2011-08-191-3/+6
| | | | | | Change-Id: Ib96551388c94731d97eb8f9728613b120b0b86a9 Reviewed-on: http://codereview.qt.nokia.com/3262 Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
* Fix/add copyright headersTobias Hunger2011-05-061-1/+1
| | | | Change-Id: I8b73d583be1ee7183f4074bce49d5390e38631a2
* Update license.hjk2011-04-131-14/+13
|
* s:// end of namespace :// namespace :g for consistencyhjk2011-02-041-1/+1
| | | | We use the latter style everywhere else to signify the end of a namespace block.
* It's 2011 now.con2011-01-121-1/+1
| | | | Reviewed-by: hjk
* License headers.con2010-12-171-7/+11
|
* Merge CPlusPlus::NameId and CPlusPlus::Identifier.Roberto Raggi2010-09-021-3/+3
|
* Get rid of the prefix findOrInsert for the functions in CPlusPlus::Control.Roberto Raggi2010-08-111-0/+1
|