MCPcopy Create free account
hub / github.com/douglance/devsql / import_query

Function import_query

crates/devsql/src/providers/tree_sitter.rs:336–344  ·  view source on GitHub ↗

Return the import query for a language, if one exists.

(lang: TsLanguageKind)

Source from the content-addressed store, hash-verified

334
335/// Return the import query for a language, if one exists.
336pub fn import_query(lang: TsLanguageKind) -> Option<&'static Query> {
337 match lang {
338 TsLanguageKind::Rust => Some(&*RUST_IMPORT_QUERY),
339 TsLanguageKind::TypeScript | TsLanguageKind::Tsx => Some(&*TS_IMPORT_QUERY),
340 TsLanguageKind::JavaScript | TsLanguageKind::Jsx => Some(&*JS_IMPORT_QUERY),
341 TsLanguageKind::Python => Some(&*PY_IMPORT_QUERY),
342 TsLanguageKind::Go => Some(&*GO_IMPORT_QUERY),
343 }
344}

Callers 1

extract_ts_like_importsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected