PerlNavigator icon indicating copy to clipboard operation
PerlNavigator copied to clipboard

Correctly Parse Subroutines Following Fat Commas

Open bscan opened this issue 3 years ago • 0 comments

When a user clicks or hovers on a word, the language server needs to parse out the relevant symbol underneath the cursor. There's a bug when a subroutine name is preceded by =>. The language server is picking this up as part of the symbol. The following code reproduces this issue and "world" returns no results for hover or go-to definition. The function getSymbol in utils.ts needs to be fixed.

sub world {
    return "world";
}

my $foo = {"Hello"=>world};

bscan avatar Jun 17 '22 01:06 bscan