You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Q:\source\typeshape-csharp\tests\TypeShape.Tests\obj\Debug\net8.0\generated\TypeShape.SourceGenerator\TypeShape.SourceGenerator.TypeShapeIncrementalGenerator\TypeShape.Tests.MsgPackSerializerTests.Witness.MyEnum.g.cs(25,38,25,43): error CS0119: 'int' is a type, which is not valid in the given context
which points to this generated code:
privateglobal::TypeShape.Abstractions.ITypeShape<global::TypeShape.Tests.MyEnum>Create_MyEnum(){returnnewglobal::TypeShape.SourceGenModel.SourceGenEnumTypeShape<global::TypeShape.Tests.MyEnum,int>{UnderlyingType=Int32,// error on this lineProvider=this,};}
I can workaround it by adding yet another witness explicitly:
+[GenerateShape<int>]
[GenerateShape<MyEnum>]
partial class Witness { }
But having to do that seems very tedious. Shouldn't transitive types like this be implicit?
The text was updated successfully, but these errors were encountered:
When I add this to the
TypeShape.Tests
project:I get this compile error:
which points to this generated code:
I can workaround it by adding yet another witness explicitly:
+[GenerateShape<int>] [GenerateShape<MyEnum>] partial class Witness { }
But having to do that seems very tedious. Shouldn't transitive types like this be implicit?
The text was updated successfully, but these errors were encountered: