Skip to content

Commit

Permalink
fix(sozo-bindgen): unity less strict on composites (#2791)
Browse files Browse the repository at this point in the history
  • Loading branch information
Larkooo authored Dec 10, 2024
1 parent cc4c800 commit 51545fa
Showing 1 changed file with 1 addition and 14 deletions.
15 changes: 1 addition & 14 deletions crates/dojo/bindgen/src/plugins/unity/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -344,19 +344,7 @@ public class {}_{} : ModelInstance {{
true,
enum_variant,
)],
CompositeType::Unknown if t.type_name() == "U256" => vec![
(
format!("new FieldElement({}.high).Inner", arg_name),
false,
enum_variant.clone(),
),
(
format!("new FieldElement({}.low).Inner", arg_name),
false,
enum_variant,
),
],
CompositeType::Struct => {
CompositeType::Unknown | CompositeType::Struct => {
let mut tokens = vec![];
t.inners.iter().for_each(|f| {
tokens.extend(handle_arg_recursive(
Expand Down Expand Up @@ -408,7 +396,6 @@ public class {}_{} : ModelInstance {{

tokens
}
CompositeType::Unknown => panic!("Unknown composite type: {:?}", t),
}
}
Token::Array(array) => {
Expand Down

0 comments on commit 51545fa

Please sign in to comment.