Skip to content

Commit

Permalink
feat(sol-macro-expander): make #[sol(rpc)] default
Browse files Browse the repository at this point in the history
  • Loading branch information
yash-atreya committed Jan 9, 2025
1 parent f2280a5 commit 544e059
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion crates/sol-macro-expander/src/expand/contract.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ pub(super) fn expand(cx: &mut ExpCtxt<'_>, contract: &ItemContract) -> Result<To
let (sol_attrs, attrs) = contract.split_attrs()?;

let extra_methods = sol_attrs.extra_methods.or(cx.attrs.extra_methods).unwrap_or(false);
let rpc = sol_attrs.rpc.or(cx.attrs.rpc).unwrap_or(false);
let rpc = sol_attrs.rpc.or(cx.attrs.rpc).unwrap_or(true);
let abi = sol_attrs.abi.or(cx.attrs.abi).unwrap_or(false);
let docs = sol_attrs.docs.or(cx.attrs.docs).unwrap_or(true);

Expand Down
2 changes: 1 addition & 1 deletion crates/sol-macro/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ use syn::parse_macro_input;
/// This is a limitation of the proc-macro API.
///
/// List of all `#[sol(...)]` supported values:
/// - `rpc [ = <bool = false>]` (contracts and alike only): generates a structs with methods to
/// - `rpc [ = <bool = true>]` (contracts and alike only): generates a structs with methods to
/// construct `eth_call`s to an on-chain contract through Ethereum JSON RPC, similar to the
/// default behavior of [`abigen`]. This makes use of the [`alloy-contract`](https://github.com/alloy-rs/alloy)
/// crate.
Expand Down

0 comments on commit 544e059

Please sign in to comment.