Skip to content

Commit

Permalink
Update godot-macros/src/class/data_models/inherent_impl.rs
Browse files Browse the repository at this point in the history
Co-authored-by: Jan Haller <[email protected]>
  • Loading branch information
Houtamelo and Bromeon authored Sep 20, 2024
1 parent cf9c6f4 commit 3e563bb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions godot-macros/src/class/data_models/inherent_impl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -442,9 +442,9 @@ where
let config_expr = parser.handle_expr("config")?;

let rpc_info = match (config_expr, (&mode, &transfer_mode, &call_local, &transfer_channel)) {
// Ok: Only `args = [expr]` is present.
// Ok: Only `config = [expr]` is present.
(Some(expr), (None, None, None, None)) => RpcInfo::Expression(expr),
// Err: `args = [expr]` is present along other parameters, which is not allowed.
// Err: `config = [expr]` is present along other parameters, which is not allowed.
(Some(_), _) => return bail!(&error_scope, "`#[rpc(config = ...)]` is mutually exclusive with any other parameters(`any_peer`, `reliable`, `call_local`, `channel = 0`)"),
// Ok: `args` is not present, any combination of the other parameters is allowed..
_ => RpcInfo::SeparatedArgs {
Expand Down

0 comments on commit 3e563bb

Please sign in to comment.