Skip to content

Commit 32f7615

Browse files
Update syn to 2.0.110 (#8563)
#8547 We are currently using an older version of `syn` in `test_random_derive`. Updating this removes one of the sources of `syn` `1.0.109` in our dependency tree. Co-Authored-By: Mac L <mjladson@pm.me> Co-Authored-By: Michael Sproul <michaelsproul@users.noreply.github.com>
1 parent 6a3a325 commit 32f7615

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ store = { path = "beacon_node/store" }
238238
strum = { version = "0.27", features = ["derive"] }
239239
superstruct = "0.10"
240240
swap_or_not_shuffle = { path = "consensus/swap_or_not_shuffle" }
241-
syn = "1"
241+
syn = "2"
242242
sysinfo = "0.26"
243243
system_health = { path = "common/system_health" }
244244
task_executor = { path = "common/task_executor" }

common/test_random_derive/src/lib.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@ use syn::{DeriveInput, parse_macro_input};
88
/// The field attribute is: `#[test_random(default)]`
99
fn should_use_default(field: &syn::Field) -> bool {
1010
field.attrs.iter().any(|attr| {
11-
attr.path.is_ident("test_random") && attr.tokens.to_string().replace(' ', "") == "(default)"
11+
attr.path().is_ident("test_random")
12+
&& matches!(&attr.meta, syn::Meta::List(list) if list.tokens.to_string().replace(' ', "") == "default")
1213
})
1314
}
1415

0 commit comments

Comments
 (0)