-
-
Notifications
You must be signed in to change notification settings - Fork 155
/
Cargo.toml
148 lines (116 loc) · 3.89 KB
/
Cargo.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
[package]
name = "chumsky"
version = "1.0.0-alpha.7"
description = "A parser library for humans with powerful error recovery"
authors = ["Joshua Barretto <[email protected]>", "Elijah Hartvigsen <[email protected]", "Jakob Wiesmore <[email protected]>"]
repository = "https://github.com/zesterer/chumsky"
license = "MIT"
keywords = ["parser", "combinator", "token", "language", "syntax"]
categories = ["parsing", "text-processing"]
edition = "2021"
exclude = [
"/misc/*",
"/benches/samples/*",
]
build = "build.rs"
[features]
default = ["std", "stacker"]
# Integrate with the standard library.
std = [
"regex-automata?/std",
"serde?/std"
]
# Enable nightly-only features like better compiler diagnostics and a Parser impl for ! (the never type).
nightly = []
# Allows deeper recursion by dynamically spilling stack state on to the heap.
stacker = ["dep:stacker", "std"]
# Allows parser memoization, speeding up heavily back-tracking parsers and allowing left recursion.
memoization = []
# Allows extending chumsky by writing your own parser implementations.
extension = []
# Enable support for parser labelling
label = []
# Make builtin parsers such as `Boxed` use atomic instead of non-atomic internals.
sync = ["spin"]
# Enable Pratt parsing combinator
pratt = ["unstable"]
# Allow the use of unstable features (aka features where the API is not settled)
unstable = []
# Allows use of the `Number` parser, which is backed by the `lexical` crate
lexical-numbers = ["lexical", "unstable"]
# Adds impl of Parser for either::Either
either = ["dep:either"]
# Enables regex combinators
regex = ["dep:regex-automata"]
# Enable serde serialization support
serde = ["dep:serde"]
# Enable dependencies only needed for generation of documentation on docs.rs
docsrs = ["dep:vergen-gix"]
# An alias of all features that work with the stable compiler.
# Do not use this feature, its removal is not considered a breaking change and its behaviour may change.
# If you're working on chumsky and you're adding a feature that does not require nightly support, please add it to this list.
_test_stable = ["std", "stacker", "memoization", "extension", "label", "sync"]
[package.metadata.docs.rs]
all-features = true
rustdoc-args = ["--cfg", "docsrs"]
[dependencies]
hashbrown = "0.14"
stacker = { version = "0.1", optional = true }
regex-automata = { version = "0.3", default-features = false, optional = true, features = ["alloc", "meta", "perf", "unicode", "nfa", "dfa", "hybrid"] }
spin = { version = "0.9", features = ["once"], default-features = false, optional = true }
lexical = { version = "6.1.1", default-features = false, features = ["parse-integers", "parse-floats", "format"], optional = true }
either = { version = "1.8.1", optional = true }
serde = { version = "1.0", default-features = false, optional = true, features = ["derive"] }
unicode-ident = "1.0.10"
unicode-segmentation = "1"
[build-dependencies]
vergen-gix = { version = "1.0", optional = true, features = ["emit_and_set"] }
[dev-dependencies]
ariadne = "0.2"
pom = "3.2"
nom = "7.1"
winnow = "0.6.0"
serde_json = { version = "1.0", features = ["preserve_order"] }
ciborium = { version = "0.2" }
criterion = "0.4.0"
pest = "2.5"
pest_derive = "2.5"
sn = "0.1"
logos = "0.13"
lasso = "0.7"
slotmap = "1.0"
[target.'cfg(unix)'.dev-dependencies]
pprof = { version = "0.11", features = ["flamegraph", "criterion"] }
[profile.bench]
debug = true
[[bench]]
name = "json"
harness = false
required-features = ["std"]
[[bench]]
name = "lex"
harness = false
[[bench]]
name = "parser"
harness = false
[[bench]]
name = "backtrack"
harness = false
[[bench]]
name = "cbor"
harness = false
[[example]]
name = "nano_rust"
required-features = ["label"]
[[example]]
name = "json"
required-features = ["std"]
[[example]]
name = "io"
required-features = ["std"]
[[example]]
name = "foo"
required-features = ["std"]
[[example]]
name = "mini_ml"
required-features = ["pratt", "label"]