Skip to content

Incorrect syntax highlighting on string interpolation in odd casesΒ #29

@winterqt

Description

@winterqt

Take this expression:

let
  a.a = 1;
  bbbbbb = 2;
  b = 3;
in
(a.a "a" {
  a = a;
  b = [
    bbbbbb
    bbbbbb
    bbbbbb
  ];
  c = [
    "${a b}"
  ];
}).a

Zed highlights the a b line like this (note the mismatched color of the open brace):

But another editor that uses tree-sitter-nix (Helix) highlights it correctly:

Zed Helix
Image Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions