Compare commits

...

4 Commits

Author SHA1 Message Date
omahs bfd2c72715
fix: typos (#13505) 2025-05-10 10:36:17 -05:00
Bryce Berger 4c8600967c
verilog: add highlighting for the "var" keyword (#13493) 2025-05-10 08:08:34 -05:00
Jules Wiriath 313ef30f64
bump: tree-sitter-cpp (#13504) 2025-05-10 08:00:05 -05:00
bloxx12 9bb370c91e
chore: clean up grammars.nix (#13506) 2025-05-10 07:58:48 -05:00
6 changed files with 8 additions and 14 deletions

View File

@ -36,7 +36,7 @@
The default Helix build. Uses the latest stable Rust toolchain, and unstable The default Helix build. Uses the latest stable Rust toolchain, and unstable
nixpkgs. nixpkgs.
The build inputs can be overriden with the following: The build inputs can be overridden with the following:
packages.${system}.default.override { rustPlatform = newPlatform; }; packages.${system}.default.override { rustPlatform = newPlatform; };

View File

@ -1,22 +1,13 @@
{ {
stdenv, stdenv,
lib, lib,
runCommandLocal,
runCommand, runCommand,
yj,
includeGrammarIf ? _: true, includeGrammarIf ? _: true,
grammarOverlays ? [], grammarOverlays ? [],
... ...
}: let }: let
# HACK: nix < 2.6 has a bug in the toml parser, so we convert to JSON
# before parsing
languages-json = runCommandLocal "languages-toml-to-json" {} ''
${yj}/bin/yj -t < ${./languages.toml} > $out
'';
languagesConfig = languagesConfig =
if lib.versionAtLeast builtins.nixVersion "2.6.0" builtins.fromTOML (builtins.readFile ./languages.toml);
then builtins.fromTOML (builtins.readFile ./languages.toml)
else builtins.fromJSON (builtins.readFile (builtins.toPath languages-json));
isGitGrammar = grammar: isGitGrammar = grammar:
builtins.hasAttr "source" grammar builtins.hasAttr "source" grammar
&& builtins.hasAttr "git" grammar.source && builtins.hasAttr "git" grammar.source

View File

@ -626,7 +626,7 @@ args = { console = "internalConsole", attachCommands = [ "platform select remote
[[grammar]] [[grammar]]
name = "cpp" name = "cpp"
source = { git = "https://github.com/tree-sitter/tree-sitter-cpp", rev = "670404d7c689be1c868a46f919ba2a3912f2b7ef" } source = { git = "https://github.com/tree-sitter/tree-sitter-cpp", rev = "56455f4245baf4ea4e0881c5169de69d7edd5ae7" }
[[language]] [[language]]
name = "crystal" name = "crystal"

View File

@ -3,7 +3,7 @@
; Constants ; Constants
(this) @variable.builtin (this) @variable.builtin
(nullptr) @constant.builtin (null) @constant.builtin
; Types ; Types

View File

@ -150,6 +150,9 @@
(port_identifier (port_identifier
(simple_identifier) @variable) (simple_identifier) @variable)
(variable_port_header ("var") @type.builtin)
(data_declaration ("var") @type.builtin)
(tf_port_item1 ("var") @type.builtin)
[ [
(net_type) (net_type)
(integer_vector_type) (integer_vector_type)