Skip to content

'Unknown instance kind: closure' when hovering over some functions #2518

@annagrin

Description

@annagrin

The experimental expression evaluation feature supports evaluating closures, but causes an error displayed in VSCode debug console (see image below).

Repro steps

  • Install flutter
  • Use flutter's example/hello_world, set a breakpoint in
    flutter/packages/flutter/lib/src/widgets/binding.dart:921
  • Add --web-enable-expression-evaluation flag to dart args in launch.json:
   {
       "version": "0.2.0",
       "configurations": [
           {
               "name": "Flutter",
               "request": "launch",
               "type": "dart",
               "args": ["--web-enable-expression-evaluation"],
           }
       ]
   }
  • hover over attachRootWidget

Actual behavior

  • native function text without a body is displayed in pop-up box, and appears to not have a lot of useful information
  • Unknown instance kind: closure error appears in the debug console

Expected behavior

  • some useful representation of the function displayed, for example:
    • maybe full text (if small)
    • or a signature and a few lines
    • or no popup at all
  • no error in display window

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    in debuggingRelates to the debug adapter or process of running debug sessionsis bug

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions