Skip to content

Commit

Permalink
Support extending Python API from other crates
Browse files Browse the repository at this point in the history
- Allow subclassing for some Python classes
- Prevent unnecessary copying for transformers
- Add execute function for Transformer
- Rename PythonPattern to PythonTransformer
  • Loading branch information
benruijl committed Sep 3, 2024
1 parent 80313c2 commit d52d61e
Show file tree
Hide file tree
Showing 6 changed files with 166 additions and 140 deletions.
2 changes: 2 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ faster_alloc = ["tikv-jemallocator"]
full_fn_cmp = []
mathematica_api = ["wolfram-library-link"]
python_api = ["pyo3", "bincode"]
# do not create a Python module but allow other crates to do so
python_no_module = ["python_api"]
# build a module that is independent of the specific Python version
python_abi3 = ["pyo3/abi3", "pyo3/abi3-py37"]

Expand Down
2 changes: 1 addition & 1 deletion build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ fn main() {
let git_desc = String::from_utf8(output.stdout).unwrap();
println!("cargo:rustc-env=SYMBOLICA_VERSION={}", git_desc);
println!("cargo:rerun-if-changed=.git/HEAD");
println!("cargo:rerun-if-changed=build.rs")
println!("cargo:rerun-if-changed=build.rs");
}
Loading

0 comments on commit d52d61e

Please sign in to comment.