Skip to content

2022-12-01

@oxalica oxalica tagged this 01 Dec 01:32
Features:

- Code actions.
  - `foo = foo;` => `inherit foo;`
  - `foo.bar = 1; foo.bux = 2;` => `foo = { bar = 1; bux = 2; };`
  - `foo = { bar = 1; bux = 2; };` => `foo.bar = 1; foo.bux = 2;`
  Currently comments and whitespaces (including indentations) are preserved.

- Highlight related texts.

  Highlight texts related to the one under the cursor.
  Don't be confused with semantic highlighting.

  - Highlight definitions and references when cursor's on identifiers.
  - Highlight all (attribute) references when cursor's on `with`.
  - Highlight all effective `with`s when cursor's on attributes from `with`.

- Add configuration `nil.diagnostics.excludedFiles` to disable diagnostics for
  some file paths, like generated ones.

- Configurations are now fully documented in `docs/configuration.md`.

Fixes:

- Don't emit debuginfo for the default release profile. This is somehow
  introduced accidentally. Nix builds are not affected due to `strip`.

- Semantic highlighting is optimized and should work fluently with big files.

- Semantic highlighting now ignores string literal inners, to integrate better
  with language injections (eg. `nvim-treesitter`). They would still be
  rendered as default string color if there is no injection.

Internal changes:

- More syntax desugaring code are moved into `syntax` crate and are made more
  portable.

- More tests and optimizations for `syntax`.
Assets 2
Loading