MagicStack / MagicPython

Cutting edge Python syntax highlighter for Sublime Text, Atom and Visual Studio Code. Used by GitHub to highlight your Python code!

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Built-in keywords on dataclasses

TylerYep opened this issue · comments

  • Editor name and version: VS Code July 1.48.1 (latest)
  • Platform: OS X
  • Color scheme: One Dark Pro
  • MagicPython version: VS Code's version
  • 5-10 lines of surrounding code:
@dataclass
class SkipListNode(Generic[KT, VT]):
    key: KT
    value: VT
    next: List[SkipListNode[KT, VT]] = field(default_factory=list)
  • A screenshot:

Screen Shot 2020-08-20 at 1 51 02 PM

In the screenshot, next is highlighted as a keyword. However, I don't believe that it should be, as it will only ever be accessed as self.next or SkipListNode.next.