Until .net 6 I couldl get the processor architecture (eg., MSIL, Amd64) of the current assembly with:
Assembly.GetExecutingAssembly().GetName().ProcessorArchitecture
But is obsolete since .net7.
It was suggested to use something from the namespace System.Reflection.Metadata
.
However it's not clear how to get ProcessorArchitecture
.
How to get this piece of information ? preferably without having to give an assembly name.