Skip to content

Commit a5dcd6c

Browse files
committed
fix: The IExtraData interface causes the packet to be a managed type.
1 parent 7f382ee commit a5dcd6c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/TrProtocol.SerializerGenerator/Internal/SyntaxTemplates/TypeDefinitionWriter.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ public static BlockNode WriteTypeDefinition(this BlockNode namespaceBlock, Proto
2828
if (!typeData.IsSideSpecific) {
2929
interfaces.Add(nameof(INonSideSpecific));
3030
}
31-
if (!typeData.DefSymbol.IsUnmanagedType) {
31+
if (!typeData.DefSymbol.IsUnmanagedType || typeData.HasExtraData) {
3232
interfaces.Add(nameof(IManagedPacket));
3333
}
3434
}

0 commit comments

Comments
 (0)