fix(codegen): Fixes serializing classes with no fields (#609)
Fixes code genning classes with no fields. Fixes code genning primitives. FIxes code genning uo types.
This commit is contained in:
parent
9afa4e4cab
commit
82b0d03e19
4 changed files with 36 additions and 11 deletions
|
|
@ -126,7 +126,7 @@ namespace SerializationGenerator
|
|||
};
|
||||
}
|
||||
|
||||
source.AppendLine($"{indent}{propertyName} = reader.{readMethod}()");
|
||||
source.AppendLine($"{indent}{propertyName} = reader.{readMethod}();");
|
||||
}
|
||||
|
||||
public void GenerateSerializationMethod(StringBuilder source, string indent, SerializableProperty property)
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ namespace SerializationGenerator
|
|||
}
|
||||
|
||||
var propertyName = property.Name;
|
||||
source.AppendLine($"{indent}{propertyName} = reader.Read{property.RuleArguments[0]}()");
|
||||
source.AppendLine($"{indent}{propertyName} = reader.Read{property.RuleArguments[0]}();");
|
||||
}
|
||||
|
||||
public void GenerateSerializationMethod(StringBuilder source, string indent, SerializableProperty property)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue