Skip to content

Commit

Permalink
Migrate to the new PDL rust generator
Browse files Browse the repository at this point in the history
  • Loading branch information
hchataing committed Aug 2, 2024
1 parent 5367a4f commit 69be4e9
Show file tree
Hide file tree
Showing 7 changed files with 204 additions and 223 deletions.
35 changes: 16 additions & 19 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ default = ["web"]
web = ["hyper", "tokio/rt-multi-thread"]

[build-dependencies]
pdl-compiler = "0.3.0"
pdl-compiler = "0.3.1"

[dependencies]
anyhow = "1.0.56"
Expand All @@ -55,7 +55,7 @@ log = "0.4.20"
env_logger = "0.11.1"
num-derive = "0.3.3"
num-traits = "0.2.17"
pdl-runtime = "0.3.0"
pdl-runtime = "0.3.1"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
thiserror = "1.0.49"
Expand Down
2 changes: 1 addition & 1 deletion build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ fn generate_module(in_file: &Path) {
)
.expect("PDL parse failed");
let analyzed_file = pdl_compiler::analyzer::analyze(&parsed_file).expect("PDL analysis failed");
let rust_source = pdl_compiler::backends::rust_legacy::generate(&sources, &analyzed_file);
let rust_source = pdl_compiler::backends::rust::generate(&sources, &analyzed_file, &[]);
out_file
.write_all(rust_source.as_bytes())
.expect("Could not write to output file");
Expand Down
Loading

0 comments on commit 69be4e9

Please sign in to comment.