Sysprogs forums › Forums › VisualGDB › dear developers… please add this major functionality
- This topic has 9 replies, 2 voices, and was last updated 5 years, 8 months ago by support.
-
AuthorPosts
-
February 22, 2019 at 16:12 #23932b.timofteParticipant
Dear developers
Can you please make the Advanced cmake project support Regular VC++ intellisense ? I am using boost libraries and clang hangs and for example cannot detect STL std:: namespace vector. It works perefectly fine with regular VC++ intellisense. In toy projects of a few lines regular clang and C++ STL works fine , but if the project gets bigger then the intellisense hangs or refuse to work on STL or BOOST templates
February 22, 2019 at 17:45 #23935supportKeymasterHi,
Unfortunately this is not possible, as the regular VC++ IntelliSense is closely tied to the regular VC++ project engine and hence will not work with the Advanced CMake engine that is completely different.
That said, if you could share the exact repro steps of the problem you mentioned and we could reproduce it on our side, we should be able to understand why does Clang IntelliSense get slow and either fix it, or suggest a setting (e.g. IntelliSense-only precompiled header) that will radically improve the performance.
February 25, 2019 at 10:59 #23967b.timofteParticipantI have a .hpp file who includes
#include <boost/log/core.hpp> #include <boost/log/trivial.hpp> #include <boost/log/expressions.hpp> #include <boost/log/sinks/text_file_backend.hpp> #include <boost/log/utility/setup/file.hpp> #include <boost/log/utility/setup/common_attributes.hpp> #include <boost/log/sources/severity_logger.hpp> #include <boost/log/sources/record_ostream.hpp> namespace logging = boost::log; namespace src = boost::log::sources; namespace sinks = boost::log::sinks; namespace keywords = boost::log::keywords; namespace common { class my_class { bool foo(std::string filename); } }
In the function foo if i type std::str and then ctrl+space it doesnt expand to anything. In fact intellisense is dead in this header file or any .cpp file who includes this header file
The function foo() is implemented in a .cpp file who includes this header file. If i select function foo() and select go to definition , nothing happens .
The .cpp file is
#include "logger.hpp" using namespace std; namespace common { bool myclass::foo(std::string filename) { return; } }
This is an advanced cmake project with mingw.
Both the .cpp and the .hpp are protected by an
#ifdef name #endif
The name after #ifdef is defined like this in the cmakefilelist.txr
if(variable_in_cmake) add_definitions(-Dname) endif()
February 25, 2019 at 19:28 #23981supportKeymasterThanks for the detailed description. Since this could be caused by a specific version of Boost, could you please share an archive with your MinGW toolchain (including the boost version you are using)?
You can upload the archive to any file sharing service (e.g. Dropbox) and either share a link here, or report it via our support form.
February 26, 2019 at 14:44 #23994b.timofteParticipantI am using MinGW
Thread model: win32
gcc version 8.1.0 (i686-win32-sjlj-rev0, Built by MinGW-W64 project)Boost: 1.67
February 27, 2019 at 07:22 #24005supportKeymasterThanks for the update. Unfortunately it looks like the latest MinGW-W64 toolchain does not include boost as a pre-built package, so in order to reproduce this we would need to build it from scratch (that might result in different results due to slightly different configuration).
We have tried reproducing the problem you described using a Linux VM after installing boost as a package, however we could not get the behavior you described. It also looks like the code you pasted is not from an actual project (it had a missing semicolon and a typo in the class name). Unfortunately problems like this one are often triggered by a rare combination of small factors and a rough description of the setup without the exact repro setup will not be sufficient.
You don’t need to share any production code, you could simply try reproducing the problem on a newly created project with the dummy classes, ensure that it behaves the same way and send us a link to the archive containing the project along with all dependencies (e.g. the toolchain and boost). There will be a high chance we will manage to reproduce the behavior on our side and fix it or suggest a workaround.
P.S. If you are using boost, please consider copying the boost includes to a separate header file and setting it as an IntelliSense-only precompiled header (VisualGDB Project Properties -> IntelliSense Settings). This will dramatically improve IntelliSense performance as VisualGDB will be able to cache the boost headers instead of reparsing them each time you change one of your own headers.
February 27, 2019 at 12:45 #24012b.timofteParticipantHello
I can confirm , under linux there is no issue . I have the same project with the same files + cmake and works fine ….
I added the .hpp file who includes all the boost headers as PCH (strangely it accepts only .h files so i added * and then added the .hpp file)
Intellisense worked for a bit with regard to boost templates then the intellisense is blocked since 5 minutes when i selected
in this code :
logging::core::get()->set_filter(logging::trivial::severity >= logging::trivial::debug);
the get() and then go to definition …. Probably i will have to forcibly shut down vs2017 from task manager 🙁
- This reply was modified 5 years, 9 months ago by b.timofte.
February 28, 2019 at 03:01 #24023supportKeymasterThanks for the update. If the problem is not reproduced on Linux, it is likely caused by some specific combination of settings related to your MinGW setup and the only way for us to help you with this would be if you could share your environment as a single ready to use package.
You could also try reinstalling MinGW from scratch, building another copy of boost inside it and checking if that resolves the issues. If the problem is caused by some leftovers from previous experiments in your current environment, creating another one from scratch will fully solve it.
March 4, 2019 at 14:06 #24069b.timofteParticipantOk as a side note
If i add precompiled header .hpp file and i make an error in a .c file by adding for example a character “x” in the file randomly then i get compiler error at build but then the linker says it passed -_-
If i build again i get no compile error and the linker says again passed -_-”
Is this a bug ?
March 4, 2019 at 18:58 #24071supportKeymasterSorry, this doesn’t look like any known issue. If you could provide the exact repro steps for the problem, we should be able to tell what is going on.
-
AuthorPosts
- You must be logged in to reply to this topic.