Skip to content

STL contaners items not visible in VARIABLES view #189

Description

@handymandorel

Environment

  • CDT GDB Debug Adapter Extension: version 2.4.1
  • VSCodium version: 1.105.17075
  • Launch configuration
  {
            "name": "run",
            "type": "gdb",
            "request": "launch",
            "program": "test",
            "arguments": "TSAN_OPTIONS=second_deadlock_stack=1",
            "cwd": "test_dir",
            "environment": {},
            "initCommands": [
                "-gdb-set disassembly-flavor intel",
                "-enable-pretty-printing",
            ],
            "openGdbConsole": true,
            "preLaunchTask": "Build",
  }

Steps

  • A minmal C++ code that uses STL containers (eg. std::vector)
  • Add a breakpoint after container initialization
  • launch the debug session (see the Environment section)
  • Observe the "VARIABLES" pane and look for "Local" variables

Outcome

  • The STL containers are listed but their details is minimal (some metadata but not details about items)
  • Printing the variables in the gdb console shows the same metadata plus items details, it looks like the variables view truncates the output of gdb print
  • See attached pictures
    • Variables view: Image
    • gdb console: Image
    • Code: Image

Expected

  • Variables view should also show container items

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions