difftreelog
build switch to released gcmodule fork
in: master
38 files changed
Cargo.lockdiffbeforeafterboth81 packageslockfile v3
Might be heavy and slow!
ahash
0.7.6crates.io↘ 3↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47used byannotate-snippets
0.9.1crates.io↘ 2↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc3b9d411ecbaf79885c6df4d75fff75858d5995ff25385657a28af47e82f9c36depends onused byanyhow
1.0.49crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0a03e93e97a28fbc9f42fbc5ba0886a3c67eb637b476dbee711f80a6ffe8223dused byatty
0.2.14crates.io↘ 3↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8depends onused byautocfg
1.0.1crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcdb031dd78e28731d87d56cc8ffef4a8f36ca26c38fe2de700543e627f8a464aused bybase64
0.13.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum904dfeac50f3cdaba28fc6f57fdcddb75f49ed61346676a78c4ffe55877802fdused bybincode
1.3.3crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb1f45e9417d87227c7a56d22e471c6206462cba514c7590c09aff4cf6d1ddcaddepends onused bybitflags
1.3.2crates.io↘ 0↖ 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718aused bycc
1.0.72crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum22a9137b95ea06864e018375b72adfb7db6e6f68cfc8df5a04d00288050485eeused bycfg-if
0.1.10crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822used bycfg-if
1.0.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbaf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fdused byclap
3.1.13crates.io↘ 9↖ 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc4b3ee449efa0c4f95cd48b00539829d3655a98e189a90617246492788d22404depends onclap_complete
3.1.3crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1d7ca9141e27e6ebc52e3c378b0c07f3cea52db46ed1cc5861735fb697b56356depends onused byclap_derive
3.1.7crates.io↘ 5↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma3aab4734e083b809aaf5794e14e756d1c798d2c69c7f7de7a09a2f5214993c1used byclap_lex
0.2.0crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma37c35f1112dad5e6e0b1adaff798507497a18fceeb30cceb3bae7d1427b9213depends onused bycloudabi
0.0.3crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumddfc5b9aa5d4507acaf872de71051dfd0e309860e88966e1051e462a077aac4fdepends onused bydtoa
0.4.8crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum56899898ce76aaf4a0f24d914c97ea6ed976d42fec6ad33fcbb0a1103e07b2b0used bygcmodule
0.3.3github.com/CertainLach/gcmodule↘ 2↖ 7sourcegit+https://github.com/CertainLach/gcmodule?branch=jrsonnet#f72713c24c2b1bf5a78f1d01bee5a0f52bc2a094depends ongcmodule_derive
0.3.3github.com/CertainLach/gcmodule↘ 4↖ 1sourcegit+https://github.com/CertainLach/gcmodule?branch=jrsonnet#f72713c24c2b1bf5a78f1d01bee5a0f52bc2a094used bygetrandom
0.2.6crates.io↘ 3↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9be70c98951c83b8d2f8f60d7065fa6d5146873094452a1008da8c2f1e4205adused byhashbrown
0.11.2crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumab5ef0d4909ef3724cc8cce6ccc8572c5c817592e9285f5464f8e86f8bd3726eused byhashbrown
0.12.1crates.io↘ 1↖ 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumdb0d4cf898abf0081f964436dc980e96670a0f36863e4b83aaacdb65c9d7ccc3depends onheck
0.4.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2540771e65fc8cb83cd6e8a237f70c319bd5c29f78ed1084ba5d50eeac86f7f9used byhermit-abi
0.1.19crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33depends onused byindexmap
1.7.0crates.io↘ 2↖ 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbc633605454125dec4b66843673f01c7df2b89479b32e0ed634e43a91cff62a5depends onitoa
0.4.8crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4used byjrsonnet
0.4.2workspace↘ 8↖ 0jrsonnet-cli
0.4.2workspace↘ 4↖ 1jrsonnet-evaluator
0.4.2workspace↘ 20↖ 3depends on- annotate-snippets
0.9.1 - anyhow
1.0.49 - base64
0.13.0 - bincode
1.3.3 - gcmodule
0.3.3 - hashbrown
0.12.1 - jrsonnet-interner
0.4.2 - jrsonnet-macros
0.4.2 - jrsonnet-parser
0.4.2 - jrsonnet-stdlib
0.4.2 - jrsonnet-types
0.4.2 - md5
0.7.0 - pathdiff
0.2.1 - rustc-hash
1.1.0 - serde
1.0.130 - serde_json
1.0.72 - serde_yaml
0.8.21 - static_assertions
1.1.0 - strsim
0.10.0 - thiserror
1.0.30
- annotate-snippets
jrsonnet-interner
0.4.2workspace↘ 4↖ 2jrsonnet-macros
0.4.2workspace↘ 3↖ 1depends onused byjrsonnet-parser
0.4.2workspace↘ 6↖ 4jrsonnet-stdlib
0.4.2workspace↘ 0↖ 2jrsonnet-types
0.4.2workspace↘ 2↖ 1depends onused byjsonnet
0.4.2workspace↘ 3↖ 0lazy_static
1.4.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646used bylibc
0.2.125crates.io↘ 0↖ 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5916d2ae698f6de9bfb891ad7a8d65c09d232dc58cc4ac433c7da3b2fd84bc2blinked-hash-map
0.5.4crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7fb9b38af92608140b86b693604b9ffcc5824240a484d1ecd4795bacb2fe88f3used bylock_api
0.3.4crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc4da24a77a3d8a6d4862d95f72e6fdb9c09a643ecdb402d754004a557f2bec75depends onused bymd5
0.7.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum490cc448043f947bae3cbee9c203358d62dbee0db12107a74be5c30ccfd09771used bymimalloc-sys
0.1.6crates.io↘ 2↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4aa3cefb626f6ae3d0b2f71c5378c89d2b1d4d7bc246b0ca9a7ee61a4daad291depends onused bymimallocator
0.1.3crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2d44fe4ebf6b538fcf39d9975c2b90bb3232d1ba8e8bffeacd004f27b20c577adepends onused byonce_cell
1.10.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum87f3e037eac156d1775da914196f0f37741a274155e34a0b7e427c35d2a2ecb9used byos_str_bytes
6.0.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8e22443d1643a904602595ba1cd8f7d896afe56d26712531c5ff73a15b2fbf64used byparking_lot
0.10.2crates.io↘ 2↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd3a704eb390aafdc107b0e392f56a82b668e3a71366993b5340f5833fd62505edepends onused byparking_lot_core
0.7.2crates.io↘ 6↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd58c7c768d4ba344e3e8d72518ac13e259d7c7ade24167003b8488e10b6740a3used bypathdiff
0.2.1crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44ddused bypeg
0.8.0crates.io↘ 2↖ 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumaf728fe826811af3b38c37e93de6d104485953ea373d656eebae53d6987fcd2cdepends onpeg-macros
0.8.0crates.io↘ 3↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4536be147b770b824895cbad934fccce8e49f14b4c4946eaa46a6e4a12fcdc16used bypeg-runtime
0.8.0crates.io↘ 0↖ 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf9b0efd3ba03c3a409d44d60425f279ec442bcf0b9e63ff4e410da31c8b0f69fused byproc-macro-error
1.0.4crates.io↘ 5↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumda25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38cused byproc-macro-error-attr
1.0.4crates.io↘ 3↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869used byproc-macro2
1.0.32crates.io↘ 1↖ 11sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumba508cc11742c0dc5c1659771673afbab7a0efab23aa17e854cbab0837ed0b43depends onquote
1.0.10crates.io↘ 1↖ 10sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum38bc8cc6a5f2e3655e0899c1b848643b2562f853f114bfec7be120678e3ace05depends onredox_syscall
0.1.57crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum41cc0f7e4d5d4544e8861606a285bb08d3e70712ccc7d2b84d7c0ccfaf4b05ceused byrustc-hash
1.1.0crates.io↘ 0↖ 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2ryu
1.0.5crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum71d301d4193d031abdd79ff7e3dd721168a9572ef3fe51a1517aba235bd8f86eused byscopeguard
1.1.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cdused byserde
1.0.130crates.io↘ 1↖ 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf12d06de37cf59146fbdecab66aa99f9fe4f78722e3607577a5375d66bd0c913depends onserde_derive
1.0.130crates.io↘ 3↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd7bc1a1ab1961464eae040d96713baa5a724a8152c1222492465b54322ec508bdepends onused byserde_json
1.0.72crates.io↘ 4↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd0ffa0837f2dfa6fb90868c2b5468cad482e175f7dad97e7421951e663f2b527used byserde_yaml
0.8.21github.com/CertainLach/serde-yaml↘ 4↖ 1sourcegit+https://github.com/CertainLach/serde-yaml?branch=feature/old-octals-quirk#4bf0e325243539fdeb419e8d727ed1c161cbe445used bysmallvec
1.7.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1ecab6c735a6bb4139c0caafd0cc3635748bbb3acf4550e8138122099251f309used bystatic_assertions
1.1.0crates.io↘ 0↖ 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543fstrsim
0.10.0crates.io↘ 0↖ 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623syn
1.0.82crates.io↘ 3↖ 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8daf5dd0bb60cbd4137b1b587d2fc0ae729bc07cf01cd70b36a1ed5ade3b9d59synstructure
0.12.6crates.io↘ 4↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210fused bytermcolor
1.1.2crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2dfed899f0eb03f32ee8c6a0aabdb8a7949659e3466561fc0adf54e26d88c5f4depends onused bytextwrap
0.15.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb1141d4d61095b28419e22cb0bbf02755f5e54e0526f97f1e3d1d160e60885fbused bythiserror
1.0.30crates.io↘ 1↖ 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum854babe52e4df1653706b98fcfc05843010039b406875930a70e4d9644e5c417depends onthiserror-impl
1.0.30crates.io↘ 3↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumaa32fd3f627f367fe16f893e2597ae3c05020f8bba2666a4e6ea73d377e5714bdepends onused byunicode-width
0.1.9crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3ed742d4ea2bd1176e236172c8429aaf54486e7ac098db29ffe6529e0ce50973used byunicode-xid
0.2.2crates.io↘ 0↖ 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8ccb82d61f80a663efe1f787a51b16b5a51e3314d6ac365b08639f52387b33f3version_check
0.9.3crates.io↘ 0↖ 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5fecdca9a5291cc2b8dcf7dc02453fee791a280f3743cb0905f8822ae463b3fewasi
0.10.2+wasi-snapshot-preview1crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfd6fbd9a79829dd1ad0cc20627bf1ed606756a7f77edff7b66b7064f9cb327c6used bywinapi
0.3.9crates.io↘ 2↖ 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419winapi-i686-pc-windows-gnu
0.4.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6used bywinapi-util
0.1.5crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178depends onused bywinapi-x86_64-pc-windows-gnu
0.4.0crates.io↘ 0↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183fused byyaml-rust
0.4.5crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum56c1936c4cc7a1c9ab21a1ebb602eb942ba868cbd44a99cb7cdc5892335e1c85depends onused byyansi-term
0.1.2crates.io↘ 1↖ 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfe5c30ade05e61656247b2e334a031dfd0cc466fadef865bdcdea8d537951bf1depends onused by
bindings/jsonnet/Cargo.tomldiffbeforeafterboth--- a/bindings/jsonnet/Cargo.toml
+++ b/bindings/jsonnet/Cargo.toml
@@ -10,7 +10,7 @@
[dependencies]
jrsonnet-evaluator = { path = "../../crates/jrsonnet-evaluator", version = "0.4.2" }
jrsonnet-parser = { path = "../../crates/jrsonnet-parser", version = "0.4.2" }
-gcmodule = { git = "https://github.com/CertainLach/gcmodule", branch = "jrsonnet" }
+jrsonnet-gcmodule = { version = "0.3.4" }
[lib]
crate-type = ["cdylib"]
bindings/jsonnet/src/native.rsdiffbeforeafterboth--- a/bindings/jsonnet/src/native.rs
+++ b/bindings/jsonnet/src/native.rs
@@ -3,7 +3,6 @@
os::raw::{c_char, c_int},
};
-use gcmodule::Cc;
use jrsonnet_evaluator::{
error::{Error, LocError},
function::builtin::{BuiltinParam, NativeCallback, NativeCallbackHandler},
@@ -11,6 +10,7 @@
typed::Typed,
IStr, State, Val,
};
+use jrsonnet_gcmodule::Cc;
type JsonnetNativeCallback = unsafe extern "C" fn(
ctx: *const c_void,
@@ -18,11 +18,11 @@
success: *mut c_int,
) -> *mut Val;
-#[derive(gcmodule::Trace)]
+#[derive(jrsonnet_gcmodule::Trace)]
struct JsonnetNativeCallbackHandler {
- #[skip_trace]
+ #[trace(skip)]
ctx: *const c_void,
- #[skip_trace]
+ #[trace(skip)]
cb: JsonnetNativeCallback,
}
impl NativeCallbackHandler for JsonnetNativeCallbackHandler {
bindings/jsonnet/src/val_make.rsdiffbeforeafterboth--- a/bindings/jsonnet/src/val_make.rs
+++ b/bindings/jsonnet/src/val_make.rs
@@ -5,8 +5,8 @@
os::raw::{c_char, c_double, c_int},
};
-use gcmodule::Cc;
use jrsonnet_evaluator::{val::ArrValue, ObjValue, State, Val};
+use jrsonnet_gcmodule::Cc;
/// # Safety
///
bindings/jsonnet/src/val_modify.rsdiffbeforeafterboth--- a/bindings/jsonnet/src/val_modify.rs
+++ b/bindings/jsonnet/src/val_modify.rs
@@ -4,8 +4,8 @@
use std::{ffi::CStr, os::raw::c_char};
-use gcmodule::Cc;
use jrsonnet_evaluator::{val::ArrValue, State, Thunk, Val};
+use jrsonnet_gcmodule::Cc;
/// # Safety
///
cmds/jrsonnet/Cargo.tomldiffbeforeafterboth--- a/cmds/jrsonnet/Cargo.toml
+++ b/cmds/jrsonnet/Cargo.toml
@@ -23,8 +23,9 @@
jrsonnet-evaluator = { path = "../../crates/jrsonnet-evaluator", version = "0.4.2" }
jrsonnet-parser = { path = "../../crates/jrsonnet-parser", version = "0.4.2" }
jrsonnet-cli = { path = "../../crates/jrsonnet-cli", version = "0.4.2" }
+jrsonnet-gcmodule = { version = "0.3.4" }
+
mimallocator = { version = "0.1.3", optional = true }
thiserror = "1.0"
-gcmodule = { git = "https://github.com/CertainLach/gcmodule", branch = "jrsonnet" }
clap = { version = "3.1", features = ["derive"] }
clap_complete = { version = "3.1" }
cmds/jrsonnet/src/main.rsdiffbeforeafterboth--- a/cmds/jrsonnet/src/main.rs
+++ b/cmds/jrsonnet/src/main.rs
@@ -115,7 +115,6 @@
}
fn main_real(s: &State, opts: Opts) -> Result<(), Error> {
- opts.gc.configure_global();
opts.general.configure(s)?;
opts.manifest.configure(s)?;
crates/jrsonnet-cli/Cargo.tomldiffbeforeafterboth--- a/crates/jrsonnet-cli/Cargo.toml
+++ b/crates/jrsonnet-cli/Cargo.toml
@@ -14,6 +14,6 @@
"explaining-traces",
] }
jrsonnet-parser = { path = "../../crates/jrsonnet-parser", version = "0.4.2" }
-gcmodule = { git = "https://github.com/CertainLach/gcmodule", branch = "jrsonnet" }
+jrsonnet-gcmodule = { version = "0.3.4" }
clap = { version = "3.1", features = ["derive"] }
crates/jrsonnet-cli/src/lib.rsdiffbeforeafterboth--- a/crates/jrsonnet-cli/src/lib.rs
+++ b/crates/jrsonnet-cli/src/lib.rs
@@ -8,6 +8,7 @@
use clap::Parser;
pub use ext::*;
use jrsonnet_evaluator::{error::Result, FileImportResolver, State};
+use jrsonnet_gcmodule::with_thread_object_space;
pub use manifest::*;
pub use tla::*;
pub use trace::*;
@@ -111,15 +112,21 @@
gc_collect_before_printing_stats: bool,
}
impl GcOpts {
- pub fn configure_global(&self) {
- if !self.gc_collect_on_exit {
- gcmodule::set_thread_collect_on_drop(false)
- }
+ pub fn stats_printer(&self) -> (Option<GcStatsPrinter>, Option<LeakSpace>) {
+ (
+ self.gc_print_stats.then(|| GcStatsPrinter {
+ collect_before_printing_stats: self.gc_collect_before_printing_stats,
+ }),
+ (!self.gc_collect_on_exit).then(|| LeakSpace {}),
+ )
}
- pub fn stats_printer(&self) -> Option<GcStatsPrinter> {
- self.gc_print_stats.then(|| GcStatsPrinter {
- collect_before_printing_stats: self.gc_collect_before_printing_stats,
- })
+}
+
+pub struct LeakSpace {}
+
+impl Drop for LeakSpace {
+ fn drop(&mut self) {
+ with_thread_object_space(|s| s.leak())
}
}
@@ -130,9 +137,9 @@
fn drop(&mut self) {
eprintln!("=== GC STATS ===");
if self.collect_before_printing_stats {
- let collected = gcmodule::collect_thread_cycles();
+ let collected = jrsonnet_gcmodule::collect_thread_cycles();
eprintln!("Collected: {}", collected);
}
- eprintln!("Tracked: {}", gcmodule::count_thread_tracked())
+ eprintln!("Tracked: {}", jrsonnet_gcmodule::count_thread_tracked())
}
}
crates/jrsonnet-evaluator/Cargo.tomldiffbeforeafterboth--- a/crates/jrsonnet-evaluator/Cargo.toml
+++ b/crates/jrsonnet-evaluator/Cargo.toml
@@ -30,6 +30,8 @@
jrsonnet-stdlib = { path = "../jrsonnet-stdlib", version = "0.4.2" }
jrsonnet-types = { path = "../jrsonnet-types", version = "0.4.2" }
jrsonnet-macros = { path = "../jrsonnet-macros", version = "0.4.2" }
+jrsonnet-gcmodule = { version = "0.3.4" }
+
pathdiff = "0.2.1"
hashbrown = "0.12.1"
static_assertions = "1.1.0"
@@ -39,7 +41,6 @@
rustc-hash = "1.1"
thiserror = "1.0"
-gcmodule = { git = "https://github.com/CertainLach/gcmodule", branch = "jrsonnet" }
serde = "1.0"
serde_json = "1.0"
crates/jrsonnet-evaluator/src/ctx.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/ctx.rs
+++ b/crates/jrsonnet-evaluator/src/ctx.rs
@@ -1,11 +1,10 @@
use std::fmt::Debug;
-use gcmodule::{Cc, Trace};
+use jrsonnet_gcmodule::{Cc, Trace};
use jrsonnet_interner::IStr;
use crate::{
- cc_ptr_eq, error::Error::*, gc::GcHashMap, map::LayeredHashMap, ObjValue, Pending, Result,
- Thunk, Val,
+ error::Error::*, gc::GcHashMap, map::LayeredHashMap, ObjValue, Pending, Result, Thunk, Val,
};
#[derive(Trace)]
@@ -136,6 +135,6 @@
impl PartialEq for Context {
fn eq(&self, other: &Self) -> bool {
- cc_ptr_eq(&self.0, &other.0)
+ Cc::ptr_eq(&self.0, &other.0)
}
}
crates/jrsonnet-evaluator/src/dynamic.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/dynamic.rs
+++ b/crates/jrsonnet-evaluator/src/dynamic.rs
@@ -1,6 +1,6 @@
use std::cell::RefCell;
-use gcmodule::{Cc, Trace};
+use jrsonnet_gcmodule::{Cc, Trace};
#[derive(Clone, Trace)]
pub struct Pending<V: Trace + 'static>(pub Cc<RefCell<Option<V>>>);
crates/jrsonnet-evaluator/src/error.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/error.rs
+++ b/crates/jrsonnet-evaluator/src/error.rs
@@ -1,6 +1,6 @@
use std::{fmt::Debug, path::PathBuf};
-use gcmodule::Trace;
+use jrsonnet_gcmodule::Trace;
use jrsonnet_interner::IStr;
use jrsonnet_parser::{BinaryOpType, ExprLocation, Source, UnaryOpType};
use jrsonnet_types::ValType;
@@ -125,7 +125,7 @@
ImportSyntaxError {
path: Source,
source_code: IStr,
- #[skip_trace]
+ #[trace(skip)]
error: Box<jrsonnet_parser::ParseError>,
},
crates/jrsonnet-evaluator/src/evaluate/destructure.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/evaluate/destructure.rs
+++ b/crates/jrsonnet-evaluator/src/evaluate/destructure.rs
@@ -1,4 +1,4 @@
-use gcmodule::Trace;
+use jrsonnet_gcmodule::Trace;
use jrsonnet_interner::IStr;
use jrsonnet_parser::{BindSpec, Destruct, LocExpr, ParamsDesc};
crates/jrsonnet-evaluator/src/evaluate/mod.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/evaluate/mod.rs
+++ b/crates/jrsonnet-evaluator/src/evaluate/mod.rs
@@ -1,6 +1,6 @@
use std::{cmp::Ordering, rc::Rc};
-use gcmodule::{Cc, Trace};
+use jrsonnet_gcmodule::{Cc, Trace};
use jrsonnet_interner::IStr;
use jrsonnet_parser::{
ArgsDesc, AssertStmt, BindSpec, CompSpec, Expr, FieldMember, FieldName, ForSpecData,
@@ -151,7 +151,7 @@
value,
}) => {
#[derive(Trace)]
- struct UnboundValue<B> {
+ struct UnboundValue<B: Trace> {
uctx: B,
value: LocExpr,
name: IStr,
@@ -201,7 +201,7 @@
..
}) => {
#[derive(Trace)]
- struct UnboundMethod<B> {
+ struct UnboundMethod<B: Trace> {
uctx: B,
value: LocExpr,
params: ParamsDesc,
@@ -247,7 +247,7 @@
Member::BindStmt(_) => {}
Member::AssertStmt(stmt) => {
#[derive(Trace)]
- struct ObjectAssert<B> {
+ struct ObjectAssert<B: Trace> {
uctx: B,
assert: AssertStmt,
}
@@ -299,7 +299,7 @@
Val::Null => {}
Val::Str(n) => {
#[derive(Trace)]
- struct UnboundValue<B> {
+ struct UnboundValue<B: Trace> {
uctx: B,
value: LocExpr,
}
crates/jrsonnet-evaluator/src/function/arglike.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/function/arglike.rs
+++ b/crates/jrsonnet-evaluator/src/function/arglike.rs
@@ -1,6 +1,6 @@
use std::collections::HashMap;
-use gcmodule::Trace;
+use jrsonnet_gcmodule::Trace;
use jrsonnet_interner::IStr;
use jrsonnet_parser::{ArgsDesc, LocExpr};
crates/jrsonnet-evaluator/src/function/builtin.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/function/builtin.rs
+++ b/crates/jrsonnet-evaluator/src/function/builtin.rs
@@ -1,6 +1,6 @@
use std::borrow::Cow;
-use gcmodule::Trace;
+use jrsonnet_gcmodule::Trace;
use super::{arglike::ArgsLike, parse::parse_builtin_call, CallLocation};
use crate::{error::Result, gc::TraceBox, Context, State, Val};
crates/jrsonnet-evaluator/src/function/mod.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/function/mod.rs
+++ b/crates/jrsonnet-evaluator/src/function/mod.rs
@@ -1,7 +1,7 @@
use std::fmt::Debug;
pub use arglike::{ArgLike, ArgsLike, TlaArg};
-use gcmodule::{Cc, Trace};
+use jrsonnet_gcmodule::{Cc, Trace};
use jrsonnet_interner::IStr;
pub use jrsonnet_macros::builtin;
use jrsonnet_parser::{ExprLocation, LocExpr, ParamsDesc};
@@ -91,7 +91,7 @@
/// Plain function implemented in jsonnet
Normal(Cc<FuncDesc>),
/// Standard library function
- StaticBuiltin(#[skip_trace] &'static dyn StaticBuiltin),
+ StaticBuiltin(#[trace(skip)] &'static dyn StaticBuiltin),
/// User-provided function
Builtin(Cc<TraceBox<dyn Builtin>>),
}
crates/jrsonnet-evaluator/src/function/parse.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/function/parse.rs
+++ b/crates/jrsonnet-evaluator/src/function/parse.rs
@@ -1,4 +1,4 @@
-use gcmodule::Trace;
+use jrsonnet_gcmodule::Trace;
use jrsonnet_interner::IStr;
use jrsonnet_parser::{LocExpr, ParamsDesc};
crates/jrsonnet-evaluator/src/gc.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/gc.rs
+++ b/crates/jrsonnet-evaluator/src/gc.rs
@@ -6,8 +6,8 @@
ops::{Deref, DerefMut},
};
-use gcmodule::{Trace, Tracer};
use hashbrown::HashMap;
+use jrsonnet_gcmodule::{Trace, Tracer};
use rustc_hash::{FxHashSet, FxHasher};
/// Replacement for box, which assumes that the underlying type is [`Trace`]
@@ -92,7 +92,7 @@
where
V: Trace,
{
- fn trace(&self, tracer: &mut gcmodule::Tracer) {
+ fn trace(&self, tracer: &mut jrsonnet_gcmodule::Tracer) {
for v in &self.0 {
v.trace(tracer);
}
@@ -133,7 +133,7 @@
K: Trace,
V: Trace,
{
- fn trace(&self, tracer: &mut gcmodule::Tracer) {
+ fn trace(&self, tracer: &mut jrsonnet_gcmodule::Tracer) {
for (k, v) in &self.0 {
k.trace(tracer);
v.trace(tracer);
crates/jrsonnet-evaluator/src/lib.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/lib.rs
+++ b/crates/jrsonnet-evaluator/src/lib.rs
@@ -57,9 +57,9 @@
pub use evaluate::*;
use function::{builtin::Builtin, CallLocation, TlaArg};
use gc::{GcHashMap, TraceBox};
-use gcmodule::{Cc, Trace, Weak};
use hashbrown::hash_map::RawEntryMut;
pub use import::*;
+use jrsonnet_gcmodule::{Cc, Trace};
use jrsonnet_interner::IBytes;
pub use jrsonnet_interner::IStr;
pub use jrsonnet_parser as parser;
@@ -704,32 +704,4 @@
pub fn set_max_stack(&self, trace: usize) {
self.settings_mut().max_stack = trace;
}
-}
-
-pub fn cc_ptr_eq<T>(a: &Cc<T>, b: &Cc<T>) -> bool {
- let a = a as &T;
- let b = b as &T;
- std::ptr::eq(a, b)
-}
-
-fn weak_raw<T>(a: Weak<T>) -> *const () {
- unsafe { std::mem::transmute(a) }
-}
-fn weak_ptr_eq<T>(a: Weak<T>, b: Weak<T>) -> bool {
- std::ptr::eq(weak_raw(a), weak_raw(b))
-}
-
-#[test]
-fn weak_unsafe() {
- let a = Cc::new(1);
- let b = Cc::new(2);
-
- let aw1 = a.clone().downgrade();
- let aw2 = a.clone().downgrade();
- let aw3 = a.clone().downgrade();
-
- let bw = b.clone().downgrade();
-
- assert!(weak_ptr_eq(aw1, aw2));
- assert!(!weak_ptr_eq(aw3, bw));
}
crates/jrsonnet-evaluator/src/map.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/map.rs
+++ b/crates/jrsonnet-evaluator/src/map.rs
@@ -1,10 +1,10 @@
-use gcmodule::{Cc, Trace};
+use jrsonnet_gcmodule::{Cc, Trace};
use jrsonnet_interner::IStr;
use crate::{GcHashMap, Thunk, Val};
#[derive(Trace)]
-#[force_tracking]
+#[trace(tracking(force))]
pub struct LayeredHashMapInternals {
parent: Option<LayeredHashMap>,
current: GcHashMap<IStr, Thunk<Val>>,
crates/jrsonnet-evaluator/src/obj.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/obj.rs
+++ b/crates/jrsonnet-evaluator/src/obj.rs
@@ -5,18 +5,17 @@
ptr::addr_of,
};
-use gcmodule::{Cc, Trace, Weak};
+use jrsonnet_gcmodule::{Cc, Trace, Weak};
use jrsonnet_interner::IStr;
use jrsonnet_parser::{ExprLocation, Visibility};
use rustc_hash::FxHashMap;
use crate::{
- cc_ptr_eq,
error::{Error::*, LocError},
function::CallLocation,
gc::{GcHashMap, GcHashSet, TraceBox},
operator::evaluate_add_op,
- throw, weak_ptr_eq, weak_raw, LazyBinding, Result, State, Thunk, Unbound, Val,
+ throw, LazyBinding, Result, State, Thunk, Unbound, Val,
};
#[cfg(not(feature = "exp-preserve-order"))]
@@ -26,7 +25,7 @@
clippy::unused_self,
)]
- use gcmodule::Trace;
+ use jrsonnet_gcmodule::Trace;
#[derive(Clone, Copy, Default, Debug, Trace)]
pub struct FieldIndex;
@@ -57,7 +56,7 @@
mod ordering {
use std::cmp::Reverse;
- use gcmodule::Trace;
+ use jrsonnet_gcmodule::Trace;
#[derive(Clone, Copy, Default, Debug, Trace, PartialEq, Eq, PartialOrd, Ord)]
pub struct FieldIndex(u32);
@@ -122,7 +121,7 @@
#[allow(clippy::module_name_repetitions)]
#[derive(Trace)]
-#[force_tracking]
+#[trace(tracking(force))]
pub struct ObjValueInternals {
sup: Option<ObjValue>,
this: Option<ObjValue>,
@@ -134,18 +133,20 @@
}
#[derive(Clone, Trace)]
-pub struct WeakObjValue(#[skip_trace] pub(crate) Weak<ObjValueInternals>);
+pub struct WeakObjValue(#[trace(skip)] pub(crate) Weak<ObjValueInternals>);
impl PartialEq for WeakObjValue {
fn eq(&self, other: &Self) -> bool {
- weak_ptr_eq(self.0.clone(), other.0.clone())
+ Weak::ptr_eq(&self.0, &other.0)
}
}
impl Eq for WeakObjValue {}
impl Hash for WeakObjValue {
fn hash<H: Hasher>(&self, hasher: &mut H) {
- hasher.write_usize(weak_raw(self.0.clone()) as usize);
+ // Safety: usize is POD
+ let addr = unsafe { *std::ptr::addr_of!(self.0).cast() };
+ hasher.write_usize(addr);
}
}
@@ -454,7 +455,7 @@
}
pub fn ptr_eq(a: &Self, b: &Self) -> bool {
- cc_ptr_eq(&a.0, &b.0)
+ Cc::ptr_eq(&a.0, &b.0)
}
pub fn downgrade(self) -> WeakObjValue {
WeakObjValue(self.0.downgrade())
@@ -463,7 +464,7 @@
impl PartialEq for ObjValue {
fn eq(&self, other: &Self) -> bool {
- cc_ptr_eq(&self.0, &other.0)
+ Cc::ptr_eq(&self.0, &other.0)
}
}
crates/jrsonnet-evaluator/src/stdlib/format.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/stdlib/format.rs
+++ b/crates/jrsonnet-evaluator/src/stdlib/format.rs
@@ -1,7 +1,7 @@
//! faster std.format impl
#![allow(clippy::too_many_arguments)]
-use gcmodule::Trace;
+use jrsonnet_gcmodule::Trace;
use jrsonnet_interner::IStr;
use jrsonnet_types::ValType;
use thiserror::Error;
crates/jrsonnet-evaluator/src/stdlib/mod.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/stdlib/mod.rs
+++ b/crates/jrsonnet-evaluator/src/stdlib/mod.rs
@@ -4,7 +4,7 @@
use std::collections::HashMap;
use format::{format_arr, format_obj};
-use gcmodule::Cc;
+use jrsonnet_gcmodule::Cc;
use jrsonnet_interner::{IBytes, IStr};
use serde::Deserialize;
use serde_yaml::DeserializingQuirks;
crates/jrsonnet-evaluator/src/stdlib/sort.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/stdlib/sort.rs
+++ b/crates/jrsonnet-evaluator/src/stdlib/sort.rs
@@ -1,4 +1,4 @@
-use gcmodule::{Cc, Trace};
+use jrsonnet_gcmodule::{Cc, Trace};
use crate::{
error::{Error, LocError, Result},
crates/jrsonnet-evaluator/src/typed/conversions.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/typed/conversions.rs
+++ b/crates/jrsonnet-evaluator/src/typed/conversions.rs
@@ -1,6 +1,6 @@
use std::ops::Deref;
-use gcmodule::Cc;
+use jrsonnet_gcmodule::Cc;
use jrsonnet_interner::{IBytes, IStr};
pub use jrsonnet_macros::Typed;
use jrsonnet_types::{ComplexValType, ValType};
crates/jrsonnet-evaluator/src/typed/mod.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/typed/mod.rs
+++ b/crates/jrsonnet-evaluator/src/typed/mod.rs
@@ -2,7 +2,7 @@
mod conversions;
pub use conversions::*;
-use gcmodule::Trace;
+use jrsonnet_gcmodule::Trace;
pub use jrsonnet_types::{ComplexValType, ValType};
use thiserror::Error;
@@ -16,7 +16,7 @@
#[error("expected {0}, got {1}")]
ExpectedGot(ComplexValType, ValType),
#[error("missing property {0} from {1}")]
- MissingProperty(#[skip_trace] Rc<str>, ComplexValType),
+ MissingProperty(#[trace(skip)] Rc<str>, ComplexValType),
#[error("every failed from {0}:\n{1}")]
UnionFailed(ComplexValType, TypeLocErrorList),
#[error(
@@ -119,7 +119,7 @@
#[derive(Clone, Debug, Trace)]
enum ValuePathItem {
- Field(#[skip_trace] Rc<str>),
+ Field(#[trace(skip)] Rc<str>),
Index(u64),
}
impl Display for ValuePathItem {
crates/jrsonnet-evaluator/src/val.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/src/val.rs
+++ b/crates/jrsonnet-evaluator/src/val.rs
@@ -1,11 +1,10 @@
use std::{cell::RefCell, fmt::Debug, rc::Rc};
-use gcmodule::{Cc, Trace};
+use jrsonnet_gcmodule::{Cc, Trace};
use jrsonnet_interner::{IBytes, IStr};
use jrsonnet_types::ValType;
use crate::{
- cc_ptr_eq,
error::{Error::*, LocError},
function::FuncVal,
gc::{GcHashMap, TraceBox},
@@ -21,7 +20,7 @@
}
#[derive(Trace)]
-enum ThunkInner<T> {
+enum ThunkInner<T: Trace> {
Computed(T),
Errored(LocError),
Waiting(TraceBox<dyn ThunkValue<Output = T>>),
@@ -30,7 +29,7 @@
#[allow(clippy::module_name_repetitions)]
#[derive(Clone, Trace)]
-pub struct Thunk<T>(Cc<RefCell<ThunkInner<T>>>);
+pub struct Thunk<T: Trace>(Cc<RefCell<ThunkInner<T>>>);
impl<T> Thunk<T>
where
@@ -78,6 +77,7 @@
pub struct CachedUnbound<I, T>
where
I: Unbound<Bound = T>,
+ T: Trace,
{
cache: Cc<RefCell<GcHashMap<CacheKey, T>>>,
value: I,
@@ -113,14 +113,14 @@
}
}
-impl<T: Debug> Debug for Thunk<T> {
+impl<T: Debug + Trace> Debug for Thunk<T> {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "Lazy")
}
}
-impl<T> PartialEq for Thunk<T> {
+impl<T: Trace> PartialEq for Thunk<T> {
fn eq(&self, other: &Self) -> bool {
- cc_ptr_eq(&self.0, &other.0)
+ Cc::ptr_eq(&self.0, &other.0)
}
}
@@ -185,9 +185,10 @@
}
#[derive(Debug, Clone, Trace)]
-#[force_tracking]
+// may contrain other ArrValue
+#[trace(tracking(force))]
pub enum ArrValue {
- Bytes(#[skip_trace] IBytes),
+ Bytes(#[trace(skip)] IBytes),
Lazy(Cc<Vec<Thunk<Val>>>),
Eager(Cc<Vec<Val>>),
Extended(Box<(Self, Self)>),
@@ -434,8 +435,8 @@
pub fn ptr_eq(a: &Self, b: &Self) -> bool {
match (a, b) {
- (Self::Lazy(a), Self::Lazy(b)) => cc_ptr_eq(a, b),
- (Self::Eager(a), Self::Eager(b)) => cc_ptr_eq(a, b),
+ (Self::Lazy(a), Self::Lazy(b)) => Cc::ptr_eq(a, b),
+ (Self::Eager(a), Self::Eager(b)) => Cc::ptr_eq(a, b),
_ => false,
}
}
crates/jrsonnet-evaluator/tests/builtin.rsdiffbeforeafterboth--- a/crates/jrsonnet-evaluator/tests/builtin.rs
+++ b/crates/jrsonnet-evaluator/tests/builtin.rs
@@ -1,6 +1,5 @@
mod common;
-use gcmodule::Cc;
use jrsonnet_evaluator::{
error::Result,
function::{builtin, builtin::Builtin, CallLocation, FuncVal},
@@ -8,6 +7,7 @@
typed::Typed,
State, Val,
};
+use jrsonnet_gcmodule::Cc;
#[builtin]
fn a() -> Result<u32> {
crates/jrsonnet-interner/Cargo.tomldiffbeforeafterboth--- a/crates/jrsonnet-interner/Cargo.toml
+++ b/crates/jrsonnet-interner/Cargo.toml
@@ -11,7 +11,8 @@
serde = ["dep:serde"]
[dependencies]
+jrsonnet-gcmodule = { version = "0.3.4" }
+
serde = { version = "1.0", optional = true }
rustc-hash = "1.1"
-gcmodule = { git = "https://github.com/CertainLach/gcmodule", branch = "jrsonnet" }
hashbrown = { version = "0.12.1", features = ["inline-more"] }
crates/jrsonnet-interner/src/lib.rsdiffbeforeafterboth--- a/crates/jrsonnet-interner/src/lib.rs
+++ b/crates/jrsonnet-interner/src/lib.rs
@@ -13,8 +13,8 @@
str,
};
-use gcmodule::Trace;
use hashbrown::HashMap;
+use jrsonnet_gcmodule::Trace;
use rustc_hash::FxHasher;
mod inner;
crates/jrsonnet-macros/src/lib.rsdiffbeforeafterboth--- a/crates/jrsonnet-macros/src/lib.rs
+++ b/crates/jrsonnet-macros/src/lib.rs
@@ -342,7 +342,7 @@
#fun
#[doc(hidden)]
#[allow(non_camel_case_types)]
- #[derive(Clone, gcmodule::Trace #static_derive_copy)]
+ #[derive(Clone, jrsonnet_gcmodule::Trace #static_derive_copy)]
#vis struct #name {
#(#fields)*
}
crates/jrsonnet-parser/Cargo.tomldiffbeforeafterboth--- a/crates/jrsonnet-parser/Cargo.toml
+++ b/crates/jrsonnet-parser/Cargo.toml
@@ -11,12 +11,13 @@
[dependencies]
jrsonnet-interner = { path = "../jrsonnet-interner", version = "0.4.2" }
+jrsonnet-gcmodule = { version = "0.3.4" }
+
static_assertions = "1.1.0"
peg = "0.8.0"
serde = { version = "1.0", features = ["derive", "rc"], optional = true }
-gcmodule = { git = "https://github.com/CertainLach/gcmodule", branch = "jrsonnet" }
[dev-dependencies]
jrsonnet-stdlib = { path = "../jrsonnet-stdlib", version = "0.4.2" }
crates/jrsonnet-parser/src/expr.rsdiffbeforeafterboth--- a/crates/jrsonnet-parser/src/expr.rs
+++ b/crates/jrsonnet-parser/src/expr.rs
@@ -4,7 +4,7 @@
rc::Rc,
};
-use gcmodule::Trace;
+use jrsonnet_gcmodule::Trace;
use jrsonnet_interner::IStr;
#[cfg(feature = "serde")]
use serde::{Deserialize, Serialize};
@@ -359,7 +359,7 @@
/// file, begin offset, end offset
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
#[derive(Clone, PartialEq, Eq, Trace)]
-#[skip_trace]
+#[trace(skip)]
#[repr(C)]
pub struct ExprLocation(pub Source, pub u32, pub u32);
impl ExprLocation {
crates/jrsonnet-parser/src/source.rsdiffbeforeafterboth--- a/crates/jrsonnet-parser/src/source.rs
+++ b/crates/jrsonnet-parser/src/source.rs
@@ -5,7 +5,7 @@
rc::Rc,
};
-use gcmodule::{Trace, Tracer};
+use jrsonnet_gcmodule::{Trace, Tracer};
#[cfg(feature = "serde")]
use serde::{Deserialize, Serialize};
crates/jrsonnet-types/Cargo.tomldiffbeforeafterboth--- a/crates/jrsonnet-types/Cargo.toml
+++ b/crates/jrsonnet-types/Cargo.toml
@@ -7,5 +7,6 @@
edition = "2021"
[dependencies]
+jrsonnet-gcmodule = { version = "0.3.4" }
+
peg = "0.8.0"
-gcmodule = { git = "https://github.com/CertainLach/gcmodule", branch = "jrsonnet" }
crates/jrsonnet-types/src/lib.rsdiffbeforeafterboth--- a/crates/jrsonnet-types/src/lib.rs
+++ b/crates/jrsonnet-types/src/lib.rs
@@ -2,7 +2,7 @@
use std::fmt::Display;
-use gcmodule::Trace;
+use jrsonnet_gcmodule::Trace;
#[macro_export]
macro_rules! ty {
@@ -115,7 +115,7 @@
}
#[derive(Debug, Clone, PartialEq, Trace)]
-#[skip_trace]
+#[trace(skip)]
pub enum ComplexValType {
Any,
Char,