Skip to content

Go to Definition on package name in call to package function opens package name, not function #16

Open
@dklilley

Description

@dklilley

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Create the following files, one of which is in a package directory: somepath/+plot/doThing.m
    • somepath/+plot/doThing.m
    • somepath/sample.m
  2. In sample.m, make the following call: plot.doThing()
  3. Go-to-Definition on doThing - doThing.m opens correctly
  4. Go-to-Definition on plot - plot.m opens instead

Expected behavior
In the above example, it is expected that doThing.m will open.

Additional context
Will need to determine how to handle cases like the following: pkg.ClassName.funcName(). If Go-to-Definition is triggered on the class name, do we want to open the class definition? Going to the function definition would often go to the same file, unless it is implemented in a class folder.

Internal tracking number: g2885285

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions