[package]
name = "car-ast"
version.workspace = true
edition.workspace = true
license.workspace = true
description = "Tree-sitter AST parsing for code-aware inference"
repository.workspace = true

[features]
default = [
    "rust", "python", "typescript", "javascript", "go", "csharp",
    "java", "c", "cpp", "ruby", "php", "swift", "kotlin", "scala",
    "dart", "zig", "lua", "elixir", "haskell", "r", "bash",
    "html", "css", "json",
]
rust = ["dep:tree-sitter-rust"]
python = ["dep:tree-sitter-python"]
typescript = ["dep:tree-sitter-typescript"]
javascript = ["dep:tree-sitter-javascript"]
go = ["dep:tree-sitter-go"]
csharp = ["dep:tree-sitter-c-sharp"]
java = ["dep:tree-sitter-java"]
c = ["dep:tree-sitter-c"]
cpp = ["dep:tree-sitter-cpp"]
ruby = ["dep:tree-sitter-ruby"]
php = ["dep:tree-sitter-php"]
swift = ["dep:tree-sitter-swift"]
kotlin = ["dep:tree-sitter-kotlin-ng"]
scala = ["dep:tree-sitter-scala"]
dart = ["dep:tree-sitter-dart"]
zig = ["dep:tree-sitter-zig"]
lua = ["dep:tree-sitter-lua"]
elixir = ["dep:tree-sitter-elixir"]
haskell = ["dep:tree-sitter-haskell"]
r = ["dep:tree-sitter-r"]
bash = ["dep:tree-sitter-bash"]
html = ["dep:tree-sitter-html"]
css = ["dep:tree-sitter-css"]
json = ["dep:tree-sitter-json"]

[dependencies]
tree-sitter = "0.26"
serde = { workspace = true }
ignore = { workspace = true }
tracing = { workspace = true }

tree-sitter-rust = { version = "0.24", optional = true }
tree-sitter-python = { version = "0.25", optional = true }
tree-sitter-typescript = { version = "0.23", optional = true }
tree-sitter-javascript = { version = "0.25", optional = true }
tree-sitter-go = { version = "0.25", optional = true }
tree-sitter-c-sharp = { version = "0.23", optional = true }
tree-sitter-java = { version = "0.23", optional = true }
tree-sitter-c = { version = "0.24", optional = true }
tree-sitter-cpp = { version = "0.23", optional = true }
tree-sitter-ruby = { version = "0.23", optional = true }
tree-sitter-php = { version = "0.24", optional = true }
tree-sitter-swift = { version = "0.7", optional = true }
tree-sitter-kotlin-ng = { version = "1.1", optional = true }
tree-sitter-scala = { version = "0.25", optional = true }
tree-sitter-dart = { version = "0.1", optional = true }
tree-sitter-zig = { version = "1.1", optional = true }
tree-sitter-lua = { version = "0.5", optional = true }
tree-sitter-elixir = { version = "0.3", optional = true }
tree-sitter-haskell = { version = "0.23", optional = true }
tree-sitter-r = { version = "1.2", optional = true }
tree-sitter-bash = { version = "0.25", optional = true }
tree-sitter-html = { version = "0.23", optional = true }
tree-sitter-css = { version = "0.25", optional = true }
tree-sitter-json = { version = "0.24", optional = true }

[dev-dependencies]
tempfile = "3"
tracing-test = "0.2"
