Skip to content

Autocomplete for symbols from package:charcode ends up with duplicated dollar ($) characters #3943

@jamesderlin

Description

@jamesderlin

Describe the bug
When I attempt to autocomplete the generated symbols from package:charcode that start with a $ character, the autocompleted symbol ends up with $$.

To Reproduce

  1. Add import 'package:charcode/charcode.dart'; to some .dart file.
  2. Start typing $ba. The autocomplete list appears, listing $backquote, $backslash, ...
  3. Press Tab.

$ba gets autocompleted to $$backquote.

Expected behavior
$ba should have been autocompleted to $backquote.

Other notes
Strangely, if I define my own variable (e.g. var $foo = 'bar';), then that seems to autocomplete fine. I'm not sure why the symbols from package:charcode are autocompleting differently.

Versions

  • Operating System and version: Ubuntu 20.04.4 LTS (x64)
  • VS Code version: 1.66.2
  • Dart extension version: 3.38.2
  • Dart/Flutter SDK version: Dart 2.16.2

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