When processing .NET FW 4.7.2 version using .NET 8.0 Confuser, it incorrectly import System.UInt32 from System.Runtime/System.Private.CoreLib which unavalilable in .NET FW 4.7.2
That happens during calls to dnlib.DotNet.Importer which copy from assembly in runtime. I think Confuser.Runtime should be loaded in separate assembly context for better management of the dependencies.
Probably Confuser.CLI / ConfuserEx application should have 2 version of runtime assemblies, for each runtime target, and select based on the target application configuration. For MSBuild task, there should be just one assembly, corresponding to the version of the TFM under which task is built.
When processing .NET FW 4.7.2 version using .NET 8.0 Confuser, it incorrectly import
System.UInt32fromSystem.Runtime/System.Private.CoreLibwhich unavalilable in .NET FW 4.7.2That happens during calls to
dnlib.DotNet.Importerwhich copy from assembly in runtime. I think Confuser.Runtime should be loaded in separate assembly context for better management of the dependencies.Probably Confuser.CLI / ConfuserEx application should have 2 version of runtime assemblies, for each runtime target, and select based on the target application configuration. For MSBuild task, there should be just one assembly, corresponding to the version of the TFM under which task is built.