Skip to content

Commit

Permalink
chore: use proc-macro-error2
Browse files Browse the repository at this point in the history
  • Loading branch information
mattsse committed Sep 5, 2024
1 parent ea7f594 commit 6a73c97
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ serde = { version = "1.0", default-features = false, features = ["alloc"] }
serde_json = { version = "1.0", default-features = false, features = ["alloc"] }

# macros
proc-macro-error = "1.0"
proc-macro-error2 = "2.0.0"
proc-macro2 = "1.0"
quote = "1.0"
syn = "2.0"
Expand Down
2 changes: 1 addition & 1 deletion crates/sol-macro-expander/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ syn = { workspace = true, features = ["extra-traits"] }
heck = "0.5"
hex.workspace = true
indexmap = "2"
proc-macro-error.workspace = true
proc-macro-error2.workspace = true
tiny-keccak = { workspace = true, features = ["keccak"] }

# json
Expand Down
2 changes: 1 addition & 1 deletion crates/sol-macro-expander/src/expand/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ use ast::{
};
use indexmap::IndexMap;
use proc_macro2::{Delimiter, Group, Ident, Punct, Spacing, Span, TokenStream, TokenTree};
use proc_macro_error::{abort, emit_error};
use proc_macro_error2::{abort, emit_error};
use quote::{format_ident, quote, TokenStreamExt};
use std::{
borrow::Borrow,
Expand Down
2 changes: 1 addition & 1 deletion crates/sol-macro-expander/src/expand/struct.rs
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ fn expand_encode_type_fns(
Some(Item::Enum(_)) => *ty = Type::Uint(ty.span(), NonZeroU16::new(8)),
Some(Item::Udt(udt)) => *ty = udt.ty.clone(),
Some(item) => {
proc_macro_error::abort!(item.span(), "Invalid type in struct field: {:?}", item)
proc_macro_error2::abort!(item.span(), "Invalid type in struct field: {:?}", item)
}
}
});
Expand Down
2 changes: 1 addition & 1 deletion crates/sol-macro-expander/src/expand/ty.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
use super::{ExpCtxt, ExternCrates};
use ast::{Item, Parameters, Spanned, Type, TypeArray};
use proc_macro2::{Ident, Literal, TokenStream};
use proc_macro_error::abort;
use proc_macro_error2::abort;
use quote::{quote_spanned, ToTokens};
use std::{fmt, num::NonZeroU16};

Expand Down
2 changes: 1 addition & 1 deletion crates/sol-macro/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ workspace = true
alloy-sol-macro-input.workspace = true
alloy-sol-macro-expander.workspace = true

proc-macro-error.workspace = true
proc-macro-error2.workspace = true
proc-macro2.workspace = true
quote.workspace = true
syn = { workspace = true, features = ["extra-traits"] }
Expand Down

0 comments on commit 6a73c97

Please sign in to comment.