on-internet
← Community

Warning about unsafe for trimming and AOT compatibility if passed across the WinRT ABI (List)

Stack Overflow ·

I have a simple .NET 8 (C#) class library that reads some registry values. It was created and built in Visual Sudio 2022 (64 Bit) v17.11.5. Project file: <PropertyGroup> <TargetFramework>net8.0-windows10.0.26100.0</TargetFramework> <ImplicitUsings>disable</ImplicitUsings> <Nullable>enable</Nullable> </PropertyGroup> Methods: public static RegistryKey? GetRegistryKey () => Registry .CurrentUser .OpenSubKey("Software") ?.OpenSubKey("ODBC") ?.OpenSubKey("ODBC.INI") ?.OpenSubKey("ODBC Data Sources"); public static IEnumerable<string> GetDataSources1 () { using var key = DataProviderOdbc.GetRegistr

Comments

Sign in or sign up to comment and upvote.

No comments yet.