When adding a type alias using a keyword, the analyzer throws `AD0001`, when inside a namespace ```csharp namespace ClassLibrary { using Example = string; } ``` and also when using value tuple values ```csharp namespace ClassLibrary { using Example = (System.Collections.IList, int); } ```
Activity
rsking commentedon Aug 5, 2024
This does not occur when outside a namespace, but this violates
SA1200
bjornhellander commentedon Aug 5, 2024
What version are you using?
bjornhellander commentedon Aug 5, 2024
Sorry! I asked because I couldn't reproduce it, but I see it now using the latest beta.
bjornhellander commentedon Aug 5, 2024
I will have a look.
Update SA1135UsingDirectivesMustBeQualified to not crash on a UsingDi…
Update SA1135UsingDirectivesMustBeQualified to not crash on a UsingDi…
Update SA1135UsingDirectivesMustBeQualified to not crash on a UsingDi…
runehalfdan commentedon Aug 29, 2024
We've also encountered this bug, using StyleCop.Analyzers.Unstable 1.2.0.556 (can't use Beta for reasons)
Workaround (but names are lost):
using Foo = System.ValueTuple<int, string>;
YoshiRulz commentedon May 16, 2025
You can also
(
#pragma
around the line is not sufficient as the Analyzer still executes.)