@@ -345,7 +345,7 @@ private void GenerateProperties() {
345
345
bodyStatements . Add ( SyntaxFactory . ParseStatement ( internalFieldName + ".Invoke(null, new object[] {value});" ) ) ;
346
346
347
347
setter = setter . AddBodyStatements ( bodyStatements . ToArray ( ) ) ;
348
- } else if ( t . IsGenericType ( ) ) {
348
+ } else if ( generic ) {
349
349
var index = t . Methods . IndexOf ( property . Value . setter ) ;
350
350
setter = setter
351
351
. AddBodyStatements ( GenericStub ( null , [ ] , index ) )
@@ -477,7 +477,7 @@ private void GenerateFields() {
477
477
478
478
getter = getter . AddBodyStatements ( bodyStatementsGetter . ToArray ( ) ) ;
479
479
setter = setter . AddBodyStatements ( bodyStatementsSetter . ToArray ( ) ) ;
480
- } else if ( t . IsGenericType ( ) ) {
480
+ } else if ( generic ) {
481
481
getter = getter
482
482
. AddBodyStatements ( ParseStatement ( "throw new System.NotImplementedException();" ) )
483
483
. WithAttributeLists ( [ ] ) ;
@@ -747,7 +747,7 @@ private void GenerateMethods() {
747
747
methodDeclaration = methodDeclaration . AddBodyStatements (
748
748
[ .. bodyStatements ]
749
749
) ;
750
- } else if ( t . IsGenericType ( ) ) {
750
+ } else if ( generic ) {
751
751
var index = t . Methods . IndexOf ( method ) ;
752
752
methodDeclaration = methodDeclaration
753
753
. AddBodyStatements ( GenericStub ( returnType , [ .. paramNames ] , index ) )
@@ -783,7 +783,7 @@ [.. bodyStatements]
783
783
var array_generic = TDB . Get ( ) . GetType ( "!0[]" ) ;
784
784
if ( array_generic is null ) return null ;
785
785
786
- var decl = new ClassGenerator ( array_generic ) . typeDeclaration ;
786
+ var decl = new ClassGenerator ( array_generic , true ) . typeDeclaration ;
787
787
return decl
788
788
. WithIdentifier ( Identifier ( "Impl" ) )
789
789
. WithTypeParameterList ( TypeParameterList ( SingletonSeparatedList ( TypeParameter ( "T" ) ) ) ) ;
0 commit comments