How can i view content of shared pointers

Sysprogs forums Forums VisualGDB How can i view content of shared pointers

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #12560
    roy111
    Participant

    Hi,

    I’m using VisualGDB from a local machine with VisualStudio 2017 to debug a CMake project on a remote Linux, Ubuntu 16.04 machine.

    The source code is on the local windows, and build on the remote machine, using the remote machine toolchain.

    I did not succeed in viewing the content of shared pointers ( e.g. std::shared_ptr<int> ).

    Any ideas ? Should I install some visualizers ?

    Thanks.

    #12579
    support
    Keymaster

    Hi,

    Looks like we missed it with our built-in visualizers. Please try this build: http://sysprogs.com/files/tmp/VisualGDB-5.3.11.1837.msi

    #12617
    roy111
    Participant

    Works great – thanks !

    #12626
    roy111
    Participant

    It turns out that the new version (see link in message above) enables to view the content of shared pointers during runtime, but now the intellisense stopped auto completing their content.

    Any idea?

    #12633
    support
    Keymaster

    Hi,

    IntelliSense should not be related to the fix we added for debug visualizers. Please try double-checking if you can get the same behavior with a minimal “hello, world” project. If yes, please post the code here so that we could check it (we quickly tried it with “std::make_unique<std::string>()->” and it worked as expected).

    #12655
    roy111
    Participant

    Solved the problem by going to “VisualGDB ProjectProperties”, then selected “InteliSense directories” tab, and then clicked on “Reload all directories”.

    It took a while but for some reason this refresh was needed.

    Now it seems to work perfectly.

    Thanks!

    #12681
    roy111
    Participant

    Hi,

    Now during runtime I can view shared pointers, however I cannot view the content boost::optional .

    I do have the visualizers installed for Visual Studio 2017.

    Any ideas ?

     

    #12689
    support
    Keymaster

    Hi,

    VisualGDB doesn’t support visualization of boost types out-of-the-box, however we do support natvis, so you can locate the current Boost visualization files and add them to your project.

    See this tutorial for a detailed example: https://visualgdb.com/tutorials/custom/natvis/

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.