CsWinRT
CsWinRT copied to clipboard
Adding an attribute class makes the build fail with an unrelated error
Describe the bug
Adding a class that derives from Attribute
will cause the build to fail with an unrelated error
To Reproduce
namespace CSWinRT_AuthoringPlayground
{
public sealed class X {}
// Commenting the following line makes the build succeed
public sealed class MyAttr : Attribute { }
}
Produces the error:
error CS0246: The type or namespace name 'IXClass' could not be found (are you missing a using directive or an assembly reference?)
Expected behavior Build succeeds with proper output
Version Info CsWinRT 1.6.4
the issue seems to be bad codegen from the generator, see how IntelliSense thinks the class name is global
and errors out once it encounters the :: etc.:
@asklar Is this more-or-less the same issue we saw yesterday with Windows.Foundation.Point not being found?
@j0shuams this is a different one- this one is about the generator outputting invalid C# code