Reputation: 75
When I right click a function, there's no 'Show Call Hierarchy' or 'Peek Call Hierarchy' option whatsoever. My popup menu looks like this
Then I tried Typing 'Show All Hierarchy' in command palette. This command does exist, but only gives a 'No Result' window after hitting enter.
So I went to Keyboard Shortcuts page, and it looks like this
My questions are,
Addtional info: VSCode version 1.60, having C/C++ and Emacs Keymap extensions installed. Tried VSCode on both MacOS and Ubuntu, issue remains the same. The code base I'm currently viewing is configured with CMake.
Any help is appreciated, thanks.
Upvotes: 4
Views: 11395
Reputation: 424
For me, clangd
vscode extension grants that capability and it seems integrated well enough to replace the basic intellisense. You will need to disable the default intellisense for that feature.
But as was mentioned here in the comments, "Show Hierarchy" support is listed in their backlog and expected to work with deafult c++ intellisense in the future.
It may be annoying to work with clangd
while compiling with a gcc
- some warnings and errors are not actually synced. This is very obvious with c++2a features support
Upvotes: 1
Reputation: 63183
When a feature like that is added to VSCode release notes or any other documentation, you should assume that it is initially only available for JavaScript/TypeScript,
Visual Studio Code show call hierarchy
That's very commmon because VSCode is just an editor providing the infrastructure (context menus and other visual elements), but the actual language feature is provided by the individual language extensions and their language servers.
In your case, the C++ extension and its language server might fall far behind to support such features.
Upvotes: 4