We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 442f7ae commit 26443a8Copy full SHA for 26443a8
1 file changed
template/framework/__PROJECT_NAME__/Program.cs
@@ -4,6 +4,12 @@
4
using Microsoft.UI.Xaml;
5
using WinRT;
6
7
+// Windows-only WinUI desktop app. The custom entry point (DISABLE_XAML_GENERATED_MAIN)
8
+// has no platform attribute, so CA1416 treats every Windows API call site as "reachable
9
+// on all platforms." Declaring the assembly's supported platform once tells the analyzer
10
+// the whole assembly only runs on Windows >= 17763, silencing those false positives.
11
+[assembly: System.Runtime.Versioning.SupportedOSPlatform("windows10.0.17763.0")]
12
+
13
namespace __PROJECT_NAME__
14
{
15
public static class Program
0 commit comments