Skip to content

Commit

Permalink
fix: recursive types with collections
Browse files Browse the repository at this point in the history
  • Loading branch information
paulpach committed Oct 20, 2020
1 parent fb924a3 commit 5cb0058
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions Assets/Mirror/Editor/Weaver/Readers.cs
Original file line number Diff line number Diff line change
Expand Up @@ -168,12 +168,11 @@ private static MethodDefinition GenerateReaderFunction(TypeReference variable)
}

static MethodDefinition GenerateReadCollection(TypeReference variable, TypeReference elementType, string readerFunction)
{
{
MethodDefinition readerFunc = GenerateReaderFunction(variable);
// generate readers for the element
GetReadFunc(elementType);

MethodDefinition readerFunc = GenerateReaderFunction(variable);

ModuleDefinition module = Weaver.CurrentAssembly.MainModule;
TypeReference readerExtensions = module.ImportReference(typeof(NetworkReaderExtensions));
MethodReference listReader = Resolvers.ResolveMethod(readerExtensions, Weaver.CurrentAssembly, readerFunction);
Expand Down

0 comments on commit 5cb0058

Please sign in to comment.