std::unordered_map values display as "(,)" in hover/variables panel with cppvsdbg debugger
まだ誰も着手していません。
評価
調査の方向性
提供された MSVC/cppvsdbg セットアップで問題を再現し、デバッガーの natvis 処理が std::unordered_map のエントリをどのように展開し、std::pair::DisplayString 式をどのように評価するかを調べます。ホバー時と Variables パネルの出力を、動作する Watch 式と比較します。各エントリに (, ) ではなくキーと値が表示されれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Environment
- VS Code version: 1.115.0
- cpptools extension: ms-vscode.cpptools 1.31.4
- OS: Windows 11
- Compiler: MSVC (Visual Studio Community 2022, amd64)
- CMake Kit: Visual Studio Community 2022 Release - amd64
Bug Description
When debugging a C++ project built with MSVC (VS2022), std::unordered_map<int, float> values are displayed as (,) in both the hover tooltip and the Variables/Watch panel.
Steps to Reproduce
- Declare and populate a
std::unordered_map<int, float>variable. - Start debugging (via CMake Tools, using cppvsdbg).
- Hover over the variable or expand it in the Variables panel.
Expected Behavior
Each entry should display as [key] = value, e.g. [3] = 0.5.
Actual Behavior
Each entry displays as [3] = (, ).
Additional Notes
begin()->firstandbegin()->secondboth evaluate correctly in the Watch panel, so debug info is intact.- The issue appears to be that
std::pair::DisplayStringexpressions ({first},{second}) fail when rendered as part of unordered_map expansion in vsdbg's natvis engine. std::vectordisplays correctly.
- 主要言語
- TypeScript
- スター
- 6.2k
- フォーク
- 1.7k
- 平均マージ
- 1日 4時間
- マージ済み PR(30日)
- 58
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
microsoft/vscode-cpptools のほかの issue
-
bug Language Service regression
microsoft/vscode-cpptools#14795 · コメント 1 件 · 担当者 1 名 ·
-
bug Language Service parser
microsoft/vscode-cpptools#14794 · コメント 1 件 · 担当者 1 名 ·
-
more info needed
microsoft/vscode-cpptools#14793 · コメント 2 件 · 担当者 1 名 ·
-
more info needed
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
microsoft/vscode-cpptools#14787 · コメント 1 件 · 担当者 1 名 ·
-
[Bug] cpptools fails to start on Ubuntu ARM64 due to missing execute permissions on shared libraries オープンbug fixed Language Service regression
microsoft/vscode-cpptools#14779 · コメント 1 件 · 担当者 1 名 ·
microsoft/vscode-cpptools の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
mksglu/context-mode#1200 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
jaegertracing/jaeger-ui#4506 ·
-
area:desktop area:ui bug platform:macos
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
anthropics/claude-code#96687 ·
-
good first issue
難易度 1/5 1時間未満 初心者へのやさしさ 95/100
AOSSIE-Org/DebateAI#582 · コメント 2 件 ·