Skip to content

Hovering over a for loop variable does not show its type #4627

Closed

Description

@incendial

Describe the bug

Screen.Recording.2023-07-04.at.09.53.36.mov

Please complete the following information:

  • Operating System and version: macOS
  • VS Code version: 1.79.2
  • Dart extension version: 3.66.0
  • Dart/Flutter SDK version: Dart SDK version: 3.1.0-163.1.beta (beta)

Activity

  1. incendial commented on Jul 4, 2023

    @incendial
    Author

    Feels like it's related to #4626

  2. added this to the v3.70.0 milestone on Jul 5, 2023
  3. added
    in editorRelates to code editing or language features
    in lsp/analysis serverSomething to be fixed in the Dart analysis server
    relies on sdk changesSomething that requires changes in the Dart/Flutter SDK to ship before it will become available
    on Jul 5, 2023
  4. DanTup commented on Jul 5, 2023

    @DanTup
    Member

    I suspect same cause, but different code. Opened a fix for this one at https://dart-review.googlesource.com/c/sdk/+/312441

  5. incendial commented on Jul 5, 2023

    @incendial
    Author

    Ah, these DeclaredIdentifier's ... 🥲
    Recently discovered that several rules in DCM were not covering them at all. Honestly, I'm really surprised it's a separate type of node (and not a variable declaration or it's variance).

  6. DanTup commented on Jul 5, 2023

    @DanTup
    Member

    I don't know all the details, but there seem to be some differences between the classes (for ex. VariableDeclaration has things like an initializer and is documented as always being a child of VariableDeclarationList, so it doesn't have keyword because that's on the list).

    I don't know if something changed here recently though, I feel like I've seen a few issues related to this recently (such as the one you linked above - which had a similar fix) - although for loops are definitely not new!

  7. DanTup commented on Jul 5, 2023

    @DanTup
    Member

    This is fixed by dart-lang/sdk@28ea45c. It's in the server so will show up in a future SDK release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    in editorRelates to code editing or language featuresin lsp/analysis serverSomething to be fixed in the Dart analysis serveris bugrelies on sdk changesSomething that requires changes in the Dart/Flutter SDK to ship before it will become available

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions