std::unordered_map values display as "(,)" in hover/variables panel with cppvsdbg debugger
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 52/100
Hướng nghiên cứu
Tái hiện vấn đề với thiết lập MSVC/cppvsdbg được cung cấp, sau đó kiểm tra cách xử lý natvis của trình gỡ lỗi mở rộng các mục std::unordered_map và đánh giá các biểu thức std::pair::DisplayString. So sánh đầu ra khi di chuột và trong bảng Variables với các biểu thức Watch đang hoạt động; hoàn tất khi mỗi mục hiển thị khóa và giá trị của nó thay vì (, ).
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
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.
- Ngôn ngữ chính
- TypeScript
- Star
- 6.2k
- Fork
- 1.7k
- Merge trung bình
- 1 ngày 4 giờ
- Pull request đã merge (30 ngày)
- 58
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của microsoft/vscode-cpptools
-
bug Language Service regression
microsoft/vscode-cpptools#14795 · 1 bình luận · 1 người được giao ·
-
bug Language Service parser
microsoft/vscode-cpptools#14794 · 1 bình luận · 1 người được giao ·
-
more info needed
microsoft/vscode-cpptools#14793 · 2 bình luận · 1 người được giao ·
-
more info needed
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
microsoft/vscode-cpptools#14787 · 1 bình luận · 1 người được giao ·
-
[Bug] cpptools fails to start on Ubuntu ARM64 due to missing execute permissions on shared libraries Đang mởbug fixed Language Service regression
microsoft/vscode-cpptools#14779 · 1 bình luận · 1 người được giao ·
Tất cả issue của microsoft/vscode-cpptools
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
mksglu/context-mode#1200 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
jaegertracing/jaeger-ui#4506 ·
-
area:desktop area:ui bug platform:macos
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
anthropics/claude-code#96687 ·
-
good first issue
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 95/100
AOSSIE-Org/DebateAI#582 · 2 bình luận ·