diff --git a/src/Authoring/WinRT.SourceGenerator/WinRTTypeWriter.cs b/src/Authoring/WinRT.SourceGenerator/WinRTTypeWriter.cs index c6f74e16c..d3c156299 100644 --- a/src/Authoring/WinRT.SourceGenerator/WinRTTypeWriter.cs +++ b/src/Authoring/WinRT.SourceGenerator/WinRTTypeWriter.cs @@ -1561,6 +1561,10 @@ private void AddOverloadAttributeForInterfaceMethods(TypeDeclaration interfaceTy continue; } + bool alreadyHasOverload = method.TryGetAttributeWithType(Model.Compilation.GetTypeByMetadataName("Windows.Foundation.Metadata.OverloadAttribute"), out AttributeData _); + if (alreadyHasOverload) + continue; + string overloadedMethodName = methodName.Key + (++lastSuffix); while (interfaceTypeDeclaration.MethodsByName.ContainsKey(overloadedMethodName)) {