Skip to content

Commit e24846c

Browse files
authored
Merge pull request #1017 from dimacurrentai/rust
Only use `Box<>` for inner variants, not inner structs.
2 parents 63e5512 + 5732732 commit e24846c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

typesystem/schema/schema.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -987,7 +987,7 @@ struct LanguageSyntaxImpl<Language::Rust> final {
987987
AppendAsMultilineCommentIndentedTwoSpaces(os, Value(f.description));
988988
}
989989
const auto& t = types_.at(f.type_id);
990-
if (Exists<ReflectedType_Struct>(t) || Exists<ReflectedType_Variant>(t)) {
990+
if (Exists<ReflectedType_Variant>(t)) {
991991
os << " pub " << SanitizeRustSymbol(f.name) << ": Box<" << TypeName(f.type_id) << ">,\n";
992992
} else {
993993
os << " pub " << SanitizeRustSymbol(f.name) << ": " << TypeName(f.type_id) << ",\n";

0 commit comments

Comments
 (0)