Skip to content

Commit

Permalink
Allow struct references within sol_interface macro
Browse files Browse the repository at this point in the history
fixes #74
  • Loading branch information
rory-ocl committed Aug 28, 2024
1 parent cdee8ce commit 5ac5228
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions stylus-proc/src/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,10 @@ pub fn solidity_type_info(ty: &Type) -> (Cow<'static, str>, Cow<'static, str>) {
(path.into(), abi.into())
}
}
Type::Custom(path) => {
let path: Cow<'static, str> = path.to_string().into();
(path.clone(), path)
}
_ => todo!("Solidity type {ty} is not yet implemented in sol_interface!"),
}
}

0 comments on commit 5ac5228

Please sign in to comment.