Skip to content

Commit 14c316e

Browse files
authored
build: compiles build scripts with optimization (#175)
Without this running `lalrpop` runs for a long time unoptimized. This trades off some build time to make the grammar generation much cheaper and makes the build 50% faster on my workstation. Also fixes a minor typo in `partiql-parser/build.rs`.
1 parent 5d8d7cb commit 14c316e

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

Cargo.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,9 @@ exclude = [
1818
"partiql-playground",
1919
]
2020

21+
[profile.dev.build-override]
22+
opt-level = 3
23+
24+
[profile.release.build-override]
25+
opt-level = 3
26+

partiql-parser/build.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ use std::io;
44
fn main() -> io::Result<()> {
55
println!("cargo:rerun-if-changed=src/parse/partiql.lalrpop");
66

7-
let grammer_dir = current_dir()?.join("src").join("parse");
7+
let grammar_dir = current_dir()?.join("src").join("parse");
88
lalrpop::Configuration::new()
9-
.set_in_dir(grammer_dir)
9+
.set_in_dir(grammar_dir)
1010
.process_current_dir()
1111
.expect("lalrpop process");
1212

0 commit comments

Comments
 (0)