Skip to content

"part of" declarations do not support file links #3970

Closed

Description

@gskinner

Is your feature request related to a problem? Please describe.
Most declarations that reference other files (ex. import, part) support command-clicking the path to jump to that file. This currently does not work for part of. This is even weirder since it's supported in part, so you can nav to the part, but not back from it.

Describe the solution you'd like
Cmd-clicking the path (ex. "file_name.dart" below) in a part of statement should jump to that file.

part of 'file_name.dart'

Activity

  1. added
    is enhancementAn enhancement or improvement that should be listed in release notes but is not a bug fix.
    on May 18, 2022
  2. DanTup commented on May 23, 2022

    @DanTup
    Member

    Working on a fix at https://dart-review.googlesource.com/c/sdk/+/245701/.

    Btw, I don't know the details but on this page it recommends:

    Note: You may have heard of the part directive, which allows you to split a library into multiple Dart files. We recommend that you avoid using part and create mini libraries instead.

    It's not a reason not to report/fix issues with part, but I thought it was worth noting. Thanks!

  3. added this to the v3.42.0 milestone on May 23, 2022
  4. added
    in editorRelates to code editing or language features
    in lsp/analysis serverSomething to be fixed in the Dart analysis server
    and removed
    is enhancementAn enhancement or improvement that should be listed in release notes but is not a bug fix.
    on May 23, 2022
  5. DanTup commented on May 24, 2022

    @DanTup
    Member

    Fixed in dart-lang/sdk@2591ed8. Since the change is in the analysis server, it will show up in an SDK release (rather than a VS Code extension 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 bug

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions