diff options
| author | Soispha Peetz <soispha@b-peetz.de> | 2026-11-28 17:21:33 +0100 |
|---|---|---|
| committer | Soispha Peetz <soispha@b-peetz.de> | 2026-11-28 17:21:33 +0100 |
| commit | a0834356366ca27cd18db43632baa06b04094db2 (patch) | |
| tree | 8826092b2461b2c45a349d39a01391e956db5571 /tree-sitter-yts/bindings/rust | |
| parent | chore(treewide): Update licenses headers (diff) | |
| download | yt-a0834356366ca27cd18db43632baa06b04094db2.zip | |
chore(treewide): Format
Diffstat (limited to 'tree-sitter-yts/bindings/rust')
| -rw-r--r-- | tree-sitter-yts/bindings/rust/build.rs | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/tree-sitter-yts/bindings/rust/build.rs b/tree-sitter-yts/bindings/rust/build.rs index e815dde..0a04e0a 100644 --- a/tree-sitter-yts/bindings/rust/build.rs +++ b/tree-sitter-yts/bindings/rust/build.rs @@ -19,12 +19,16 @@ fn main() { if std::env::var("TARGET").unwrap() == "wasm32-unknown-unknown" { let Ok(wasm_headers) = std::env::var("DEP_TREE_SITTER_LANGUAGE_WASM_HEADERS") else { - panic!("Environment variable DEP_TREE_SITTER_LANGUAGE_WASM_HEADERS must be set by the language crate"); + panic!( + "Environment variable DEP_TREE_SITTER_LANGUAGE_WASM_HEADERS must be set by the language crate" + ); }; let Ok(wasm_src) = std::env::var("DEP_TREE_SITTER_LANGUAGE_WASM_SRC").map(std::path::PathBuf::from) else { - panic!("Environment variable DEP_TREE_SITTER_LANGUAGE_WASM_SRC must be set by the language crate"); + panic!( + "Environment variable DEP_TREE_SITTER_LANGUAGE_WASM_SRC must be set by the language crate" + ); }; c_config.include(&wasm_headers); @@ -48,11 +52,15 @@ fn main() { c_config.compile("tree-sitter-yts"); println!("cargo:rustc-check-cfg=cfg(with_highlights_query)"); - if !"queries/highlights.scm".is_empty() && std::path::Path::new("queries/highlights.scm").exists() { + if !"queries/highlights.scm".is_empty() + && std::path::Path::new("queries/highlights.scm").exists() + { println!("cargo:rustc-cfg=with_highlights_query"); } println!("cargo:rustc-check-cfg=cfg(with_injections_query)"); - if !"queries/injections.scm".is_empty() && std::path::Path::new("queries/injections.scm").exists() { + if !"queries/injections.scm".is_empty() + && std::path::Path::new("queries/injections.scm").exists() + { println!("cargo:rustc-cfg=with_injections_query"); } println!("cargo:rustc-check-cfg=cfg(with_locals_query)"); |
