Skip to content

Generator crash on adding ExclusiveTo attribute #939

@asklar

Description

@asklar

The generator will try adding ExclusiveTo but pass a string (class name) instead of a Type

private void AddExclusiveToAttribute(EntityHandle interfaceHandle, string className)
{
List<ITypeSymbol> types = new List<ITypeSymbol>
{
Model.Compilation.GetTypeByMetadataName("System.Type")
};
List<object> arguments = new List<object>
{
className
};
AddCustomAttributes("Windows.Foundation.Metadata.ExclusiveToAttribute", types, arguments, interfaceHandle);
}

Metadata

Metadata

Assignees

Labels

authoringRelated to authoring feature workbugSomething isn't workingcswinmd

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions