warning CS0436: The type ‘SelfRegisteredExtensions’ causes a conflict #3036
Closed as not planned
Description
warning CS0436: The type ‘SelfRegisteredExtensions’ in ‘...\bugtest\obj\Debug\net8.0\AutoRegisteredExtensions.cs’ causes a conflict with the imported type ‘SelfRegisteredExtensions’ in ‘ClassLibrary1, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null’. The type defined in ‘...\bugtest\obj\Debug\net8.0\AutoRegisteredExtensions.cs’ is used.
super fresh warning with the following version:
and this is how you can recreate it:
one solution with two libs. the first lib has a ProjectReference to the second lib.
in the second lib exists the following class:
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, AllowMultiple = true)] public class BaseTestAttribute : Attribute { public BaseTestAttribute() { } }