556 references to HDN_UnusedUsingDirective
Microsoft.CodeAnalysis.CSharp (3)
Compilation\CSharpCompilation.cs (1)
2692: ErrorCode.HDN_UnusedUsingDirective;
Errors\ErrorFacts.cs (1)
1672or ErrorCode.HDN_UnusedUsingDirective
Generated\ErrorFacts.Generated.cs (1)
388case ErrorCode.HDN_UnusedUsingDirective:
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (11)
CodeGen\CodeGenAsyncIteratorTests.cs (1)
7869Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Runtime.CompilerServices;").WithLocation(2, 1),
CodeGen\CodeGenAsyncMainTests.cs (2)
248Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(2, 1)); 285Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(2, 1));
CodeGen\CodeGenAwaitForeachTests.cs (2)
8791Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N3;").WithLocation(5, 1)); 8896Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N2;").WithLocation(5, 1),
CodeGen\CodeGenForEachTests.cs (1)
5193Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N2;").WithLocation(4, 1),
CodeGen\CodeGenOperators.cs (2)
2293Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;").WithLocation(3, 1), 2296Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;").WithLocation(4, 1),
CodeGen\CodeGenTupleTest.cs (2)
5416Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using VT2 = (int, int);").WithLocation(2, 1)); 5423Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using VT2 = (int, int);").WithLocation(2, 1));
Perf.cs (1)
36Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using nested;"));
Microsoft.CodeAnalysis.CSharp.Emit2.UnitTests (41)
PDB\PDBUsingTests.cs (41)
1422Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Y = B::N;").WithLocation(5, 1), 1425Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = A::N;").WithLocation(4, 1), 1428Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Z = global::N;").WithLocation(6, 1)); 1569Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"), 1572Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AU1 = System;"), 1575Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AT1 = System.Char;"), 1581Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AU2 = System.IO;"), 1584Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AT2 = System.IO.Directory;"), 1587Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.IO;"), 1593Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AT3 = System.Text.StringBuilder;"), 1596Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Text;"), 1599Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AU3 = System.Text;"), 1875Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"), 1878Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AU1 = System;"), 1881Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AT1 = System.Char;"), 1887Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AU3 = System.Threading;"), 1890Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AT3 = System.Threading.Thread;"), 1893Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading;"), 1899Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AU2 = System.IO;"), 1902Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AT2 = System.IO.Directory;"), 1905Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.IO;"), 2054Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"), 2057Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AU1 = System;"), 2060Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AT1 = System.Char;"), 2066Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Text;"), 2069Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AU3 = System.Text;"), 2072Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AT3 = System.Text.StringBuilder;"), 2075Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AU2 = System.IO;"), 2081Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AT2 = System.IO.Directory;"), 2084Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.IO;"), 2087Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AU4 = System.Threading;"), 2093Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using AT4 = System.Threading.Thread;"), 2096Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading;"), 3038Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Y = A::E;").WithLocation(5, 1), 3041Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using B;").WithLocation(3, 1), 3044Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = C.D;").WithLocation(4, 1), 3047Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Z = F<int>;").WithLocation(6, 1) 3163Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static N.SBad;"), 3166Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using NIBad = N.IBad;"), 3169Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using ZBad = N.SBad;")); 3233Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = N.B;"));
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (25)
Attributes\AttributeTests.cs (1)
8439Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"));
Attributes\AttributeTests_WellKnownAttributes.cs (2)
7297Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = A;"), 7300Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Y = A.B;"));
FirstClassSpanTests.cs (1)
166Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N2;").WithLocation(5, 5)
RefReadonlyParameterTests.cs (5)
276Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Runtime.CompilerServices;").WithLocation(1, 1), 4045Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1;").WithLocation(1, 1), 4086Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1;").WithLocation(1, 1), 4359Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1;").WithLocation(1, 1), 4397Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1;").WithLocation(1, 1),
Semantics\ExtensionTests.cs (8)
11725Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N2;").WithLocation(2, 1), 11822Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1)); 18219Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1)); 30049Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1)); 30133Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1)); 30183Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1)); 38845Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using extension = int;").WithLocation(1, 1), 38893Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @extension = int;").WithLocation(1, 1));
Semantics\PatternMatchingTests2.cs (1)
1275Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using _ = System.Int32;").WithLocation(1, 1)
Semantics\PrimaryConstructorTests.cs (4)
9880comp.GetEmitDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 11781var diagnostics = verifier.Diagnostics.Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective); 20764Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1), 20811Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1),
Semantics\RecordTests.cs (3)
2958Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using record = System.Console;").WithLocation(2, 1), 2975Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @record = System.Console;").WithLocation(2, 1) 24527Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1),
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (231)
Semantics\BindingTests.cs (10)
3430Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static MyNamespace.AnyClass.AnyEnum.Val;").WithLocation(2, 1), 3462Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static MyNamespace.AnyClass.AnyEnum.Val;").WithLocation(2, 1), 3495Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static MyNamespace.AnyClass.AnyEnum.Val;").WithLocation(2, 1), 3530Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static MyNamespace.AnyClass.AnyEnum.Val;").WithLocation(2, 1), 3562Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static MyNamespace.AnyClass.AnyEnum.Val;").WithLocation(2, 1), 3594Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static MyNamespace.AnyClass.AnyEnum.Val;").WithLocation(2, 1), 3624Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static MyNamespace.AnyClass.AnyEnum.Val;").WithLocation(2, 1), 3645Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static Test<System.String>;").WithLocation(2, 1), 3665Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static A<A<int>[]>.B;").WithLocation(2, 1), 3681Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static A<int, string>;").WithLocation(2, 1),
Semantics\DelegateTypeTests.cs (11)
1677Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1) 1727Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1) 1777Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1) 1827Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1) 1877Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1) 1927Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1) 2136Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1), 2191Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1), 2201Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1), 2261Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1) 2689Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N;").WithLocation(1, 1)
Semantics\FunctionPointerTests.cs (9)
67Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using s = delegate*<void>;").WithLocation(2, 1)); 79Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using s = delegate*<void>;").WithLocation(2, 1)); 96Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe S = delegate*<void>;").WithLocation(2, 1)); 103Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe S = delegate*<void>;").WithLocation(2, 1)); 110Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe S = delegate*<void>;").WithLocation(2, 1)); 123Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using S = System.Collections.Generic.List<delegate*<void>[]>;").WithLocation(2, 1)); 129Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using S = System.Collections.Generic.List<delegate*<void>[]>;").WithLocation(2, 1), 148Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe S = System.Collections.Generic.List<delegate*<void>[]>;").WithLocation(2, 1)); 154Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe S = System.Collections.Generic.List<delegate*<void>[]>;").WithLocation(2, 1));
Semantics\GlobalUsingDirectiveTests.cs (157)
887comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 890comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 893comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 896comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 958comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 961comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 964comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 1062comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 1112comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 1531comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 1551comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 1554comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 1557comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 1591comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 1611comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 1614comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 1928comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 1964comp.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2074comp2.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify( 2084comp3.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify( 2097comp4.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify( 2127comp5.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify(expected1); 2130comp6.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify( 2140comp7.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify( 2153comp8.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify(expected1); 2156comp9.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify( 2169comp10.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify( 2216comp2.GetSemanticModel(comp2.SyntaxTrees[1]).GetDeclarationDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify(expected); 2219comp2.GetSemanticModel(comp2.SyntaxTrees[2]).GetDeclarationDiagnostics().Where(d => d.Code is not ((int)ErrorCode.HDN_UnusedUsingDirective or (int)ErrorCode.HDN_UnusedExternAlias)).Verify(expected); 2251comp2.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2265comp3.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2268comp4.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2271comp5.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2274comp6.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2277comp7.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2280comp8.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2283comp9.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2301comp2.GetSemanticModel(comp2.SyntaxTrees[1]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2308comp2.GetSemanticModel(comp2.SyntaxTrees[1]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2338comp2.GetSemanticModel(comp2.SyntaxTrees[1]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 2341comp2.GetSemanticModel(comp2.SyntaxTrees[0]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 2344comp2.GetSemanticModel(comp2.SyntaxTrees[0]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 2396comp2.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2413comp3.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2416comp4.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2419comp5.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2422comp6.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2425comp7.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2428comp8.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2431comp9.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2492comp2.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2509comp3.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2512comp4.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2515comp5.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2518comp6.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2521comp7.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2524comp8.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2527comp9.GetDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 2557CompileAndVerify(comp2).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2561CompileAndVerify(comp3).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2571CompileAndVerify(comp4).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2578CompileAndVerify(comp5).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2588CompileAndVerify(comp6).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2598CompileAndVerify(comp7).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2608CompileAndVerify(comp8).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2611CompileAndVerify(comp9).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2635comp2.GetSemanticModel(comp2.SyntaxTrees[1]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2642comp2.GetSemanticModel(comp2.SyntaxTrees[1]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2671comp2.GetSemanticModel(comp2.SyntaxTrees[1]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 2674comp2.GetSemanticModel(comp2.SyntaxTrees[0]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 2677comp2.GetSemanticModel(comp2.SyntaxTrees[0]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2711CompileAndVerify(comp2).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2715CompileAndVerify(comp3).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2725CompileAndVerify(comp4).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2732CompileAndVerify(comp5).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2742CompileAndVerify(comp6).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2752CompileAndVerify(comp7).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2762CompileAndVerify(comp8).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 2765CompileAndVerify(comp9).Diagnostics.Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2789comp2.GetSemanticModel(comp2.SyntaxTrees[1]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2796comp2.GetSemanticModel(comp2.SyntaxTrees[1]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2825comp2.GetSemanticModel(comp2.SyntaxTrees[1]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 2828comp2.GetSemanticModel(comp2.SyntaxTrees[0]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected); 2831comp2.GetSemanticModel(comp2.SyntaxTrees[0]).GetDeclarationDiagnostics().Where(d => d.Code != (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 2877Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using alias1 = C2;").WithLocation(1000, 1), 2880Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using alias3 = C4;").WithLocation(3000, 1), 2883Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using alias4 = C2;").WithLocation(4000, 1) 2892Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using alias1 = C2;").WithLocation(1000, 1) 2899Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using alias3 = C4;").WithLocation(3000, 1), 2902Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using alias4 = C2;").WithLocation(4000, 1) 2963Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static C2;").WithLocation(1000, 1), 2966Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static C4;").WithLocation(3000, 1), 2969Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static C5;").WithLocation(4000, 1) 2978Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static C2;").WithLocation(1000, 1) 2985Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static C4;").WithLocation(3000, 1), 2988Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static C5;").WithLocation(4000, 1) 3049Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using C2;").WithLocation(1000, 1), 3052Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using C4;").WithLocation(3000, 1), 3055Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using C5;").WithLocation(4000, 1) 3064Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using C2;").WithLocation(1000, 1) 3071Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using C4;").WithLocation(3000, 1), 3074Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using C5;").WithLocation(4000, 1) 3177Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using N2;").WithLocation(1000, 1), 3180Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N5;").WithLocation(4000, 1), 3183Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N8;").WithLocation(6000, 1), 3210Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using N2;").WithLocation(1000, 1), 3223Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N5;").WithLocation(4000, 1), 3236Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N8;").WithLocation(6000, 1), 3385Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using alias2 = System;").WithLocation(4, 1) 3393Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using alias2 = System;").WithLocation(4, 1) 3401Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using alias2 = System;").WithLocation(2, 1) 3409Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using alias2 = System;").WithLocation(2, 1) 3417Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using alias2 = System;").WithLocation(2, 1) 3425Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using alias2 = System;").WithLocation(2, 1) 3433Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using alias2 = System;").WithLocation(2, 1) 3441Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using alias2 = System;").WithLocation(2, 1) 4221comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.ERR_DuplicateAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify(expected1); 4224comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.ERR_DuplicateAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify(expected1); 4227comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.ERR_DuplicateAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify( 4241comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify(expected2); 4249comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify(expected2); 4257comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.ERR_DuplicateAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify(expected1); 4260comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.ERR_DuplicateAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify(expected1); 4263comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.ERR_DuplicateAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify( 4277comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify(expected3); 4285comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify(expected3); 4293comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify(expected3); 4301comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify(expected3); 4309comp.GetDiagnostics().Where(d => d.Code is not ((int)ErrorCode.ERR_BadExternAlias or (int)ErrorCode.HDN_UnusedUsingDirective)).Verify( 4375comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4378comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4381comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4384comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4387comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 4394comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 4401comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 4471comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4474comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4477comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4480comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4483comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 4490comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 4497comp.GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify( 4568Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using NS;").WithLocation(1000, 1) 4586Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static C2;").WithLocation(2000, 1) 4602Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using NS;").WithLocation(3000, 1) 4613Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static C2;").WithLocation(4000, 1) 4684Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using NS;").WithLocation(1000, 1) 4717Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static C2;").WithLocation(2000, 1) 4750Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using NS;").WithLocation(3000, 1) 4771Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static C2;").WithLocation(4000, 1) 4926GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4929GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4932GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected1); 4945GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 4948GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(expected2); 4951GetDiagnostics().Where(d => d.Code is not (int)ErrorCode.HDN_UnusedUsingDirective).Verify(
Semantics\InheritanceBindingTests.cs (1)
1373Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @str = System.String;").WithLocation(2, 1));
Semantics\LookupTests.cs (1)
1621Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using A = List<int>;").WithLocation(1, 1));
Semantics\NameCollisionTests.cs (2)
2002Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static Static<System.String>;").WithLocation(3, 1)); 2034Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static Static<string>;").WithLocation(2, 1));
Semantics\NameOfTests.cs (2)
2536Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;").WithLocation(2, 1), 2554Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;").WithLocation(2, 1),
Semantics\NativeIntegerTests.cs (5)
3842Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using A=nint;").WithLocation(1, 1), 3851Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using A=nint;").WithLocation(1, 1), 3860Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using A=nint;").WithLocation(1, 1), 3926Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using nint;").WithLocation(1, 1), 3932Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using nuint;").WithLocation(2, 1),
Semantics\NullableReferenceTypesTests.cs (2)
14439Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;").WithLocation(4, 1), 14442Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Text;").WithLocation(5, 1),
Semantics\OverloadResolutionTests.cs (1)
7579Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;").WithLocation(2, 1),
Semantics\QueryTests.cs (1)
3594Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;"));
Semantics\RefFieldTests.cs (4)
22342Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using scoped = System.Int32;").WithLocation(1, 1), 22352Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using scoped = System.Int32;").WithLocation(1, 1), 22369Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @scoped = System.Int32;").WithLocation(1, 1) 22376Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @scoped = System.Int32;").WithLocation(1, 1)
Semantics\SemanticErrorTests.cs (1)
2418Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1)
Semantics\TopLevelStatementsTests.cs (2)
3782Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static N2;").WithLocation(2, 1), 3850Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static N2;").WithLocation(2, 1),
Semantics\UnsafeTests.cs (22)
12730Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = int*;").WithLocation(2, 1), 12750Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = int;").WithLocation(2, 1), 12766Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = int*;").WithLocation(2, 1), 12785Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = int;").WithLocation(2, 1), 12804Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = int*;").WithLocation(2, 1), 12820Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = int;").WithLocation(2, 1), 12836Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = System.String;").WithLocation(2, 1), 12855Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = System.String;").WithLocation(2, 1), 12904Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Y = X;").WithLocation(5, 5), 12924Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe Y = X;").WithLocation(5, 5)); 12942Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = int*;").WithLocation(2, 1), 13015Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = int*[];").WithLocation(2, 1)); 13028Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = int*[];").WithLocation(2, 1), 13161Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = delegate*<int,int>;").WithLocation(2, 1), 13207Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = delegate*<int,int>[];").WithLocation(2, 1), 13210Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Y = delegate*<int,int>[];").WithLocation(3, 1), 13323Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = System.Collections.Generic.List<int*>;").WithLocation(2, 1), 13339Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = System.Collections.Generic.List<int*>;").WithLocation(2, 1), 13483Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = System.Collections.Generic.List<int*[]>;").WithLocation(2, 1) 13495Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = System.Collections.Generic.List<int*[]>;").WithLocation(2, 1), 13597Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = System.Collections.Generic.List<int*[]>;").WithLocation(2, 1)); 13603Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe X = System.Collections.Generic.List<int*[]>;").WithLocation(2, 1),
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (106)
Compilation\GetUnusedImportDirectivesTests.cs (18)
38Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;")); 102model.GetDiagnostics().Verify(Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using ClassLibrary2;")); 133Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;"), 136Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"), 139Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 142Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading.Tasks;") 149Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"), 152Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 155Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading.Tasks;") 205Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;") 285Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections;"), 288Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;") 295Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections;"), 298Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;") 333Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections;"), 336Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using C = System.Console;")); 383Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithWarningAsError(false)); 404Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"));
Compilation\SemanticModelAPITests.cs (2)
1240Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = System;")); 1333Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = System;"));
Compilation\SemanticModelGetDeclaredSymbolAPITests.cs (2)
4529Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Alias = Goo;")); 4566Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Alias = Goo;"));
Compilation\UsedAssembliesTests.cs (20)
219if (old.Code is (int)ErrorCode.HDN_UnusedUsingDirective) 1839Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static C1;").WithLocation(1001, 1), 2179Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1;").WithLocation(1001, 1) 2192Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static N1.C1;").WithLocation(1001, 1) 2205Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @alias = N1.C1;").WithLocation(1001, 1) 2218Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @alias = N1;").WithLocation(1001, 1) 2244Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1;").WithLocation(2, 1) 2257Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static N1.C1;").WithLocation(2, 1) 2270Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @alias = N1.C1;").WithLocation(2, 1) 2283Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @alias = N1;").WithLocation(2, 1) 4556Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1.N2;").WithLocation(1001, 1) 4561Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1.N2;").WithLocation(1001, 1), 4585Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1;").WithLocation(1001, 1) 4590Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1;").WithLocation(1001, 1), 4776Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static N1.N2.E0;").WithLocation(1001, 1) 4781Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static N1.N2.E0;").WithLocation(1001, 1), 5282Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static C1;").WithLocation(1001, 1), 5304Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static C1;").WithLocation(1001, 1), 5343Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static C1;").WithLocation(1001, 1), 5382Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static C1;").WithLocation(1001, 1),
DocumentationComments\CrefTests.cs (2)
5281Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;")); 7025Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1));
Symbols\AssemblyAndNamespaceTests.cs (4)
425Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading;"), 428Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading.Tasks;"), 561Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1)); 574Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(2, 1));
Symbols\ExtensionMethodTests.cs (3)
3404Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using NB;")); 3702Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static Program;").WithLocation(4, 5)); 3737Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = N.S;").WithLocation(4, 5));
Symbols\GenericConstraintTests.cs (4)
791Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using A = C<int>;")); 825Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using A = C<I<int?>>;"), 828Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using B1 = C<I<int>>.D1<object>;"), 831Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using B2 = C<int>.D2<string>;"));
Symbols\Metadata\PE\TypeForwarders.cs (2)
951Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Namespace;")); 987Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Namespace;"));
Symbols\Source\BaseClassTests.cs (4)
1984Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using D;").WithLocation(2, 1), 1987Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using A<int>.B;").WithLocation(1, 1) 2011Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static A<int>.B;").WithLocation(1, 1) 2208Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using CrashTest.Crash<CrashTest.Class2>;").WithLocation(2, 1)
Symbols\Source\ExternAliasTests.cs (1)
167Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Bar = System.Console;"),
Symbols\Source\FileModifierTests.cs (4)
3358Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static C;").WithLocation(1, 1), 3397Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static Container<C>;").WithLocation(1, 1), 3432Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static C<int>;").WithLocation(1, 1), 3551Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static C;").WithLocation(2, 1));
Symbols\Source\UsingAliasTests.cs (5)
987Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static A;").WithLocation(5, 5), 1006Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static A;").WithLocation(5, 5), 1025Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static A;").WithLocation(5, 5), 1044Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static A;").WithLocation(5, 5), 1064Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static A;").WithLocation(5, 5));
Symbols\SymbolErrorTests.cs (33)
2551Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Object;"), 2554Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using NS.S;")); 3422Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using NoExistNS1;"), 3425Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using NoExistNS2;")); 3920Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using NIA = N.IA;").WithLocation(1, 1)); 4508Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1), 4565Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using COfArgIterator = C<System.ArgIterator>;").WithLocation(3, 1)); 4591Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using COfArgIterator = C<System.ArgIterator>;").WithLocation(3, 1)); 15139Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using A = System;"), 15142Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using A = System;"), 15145Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using O = System.Object;"), 15148Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using O = System.Object;")); 15191Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(15, 5), 15194Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using ns = namespace2;").WithLocation(14, 5)); 15212Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = System;"), 15215Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = ABC.X<int>;")); 17058Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"), 17061Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"), 17064Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"), 17067Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Goo.Bar;")); 18009Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;")); 20274Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using A = A;").WithLocation(1, 1), 20277Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using B;").WithLocation(4, 5)); 21471Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using one = System.Console;").WithLocation(2, 1), 21477Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @two = System.Console;").WithLocation(3, 1), 21480Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using three = System;").WithLocation(4, 1), 21486Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Ten = System.Console;").WithLocation(5, 1), 21489Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using cédille = System.Console;").WithLocation(6, 1) 21499Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using one = System.Console;").WithLocation(2, 1), 21502Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using @two = System.Console;").WithLocation(3, 1), 21505Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using three = System;").WithLocation(4, 1), 21508Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Ten = System.Console;").WithLocation(5, 1), 21511Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using cédille = System.Console;").WithLocation(6, 1)
Symbols\TypeTests.cs (2)
714Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;")); 751Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"));
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (67)
Parsing\ParserErrorMessageTests.cs (6)
1924Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1)); 2183Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(2, 1)); 2819Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(2, 1)); 5312Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using N1Alias = N1;").WithLocation(2, 1), 5315Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1)); 5774Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using global = MyClass;").WithLocation(2, 1));
Parsing\UsingDirectiveParsingTests.cs (55)
353Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static x = ref int;").WithLocation(1, 1), 608Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = A*;").WithLocation(1, 1), 662Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe x = A*;").WithLocation(1, 1), 712Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = delegate*<int, void>;").WithLocation(1, 1), 774Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe x = delegate*<int, void>;").WithLocation(1, 1), 834Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe System;").WithLocation(1, 1), 864Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = int;").WithLocation(1, 1), 904Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = int;").WithLocation(1, 1), 941Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = int;").WithLocation(1, 1), 978Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = ref int;").WithLocation(1, 1), 1022Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = ref readonly int;").WithLocation(1, 1), 1067Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = int*;").WithLocation(1, 1), 1111Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe x = int*;").WithLocation(1, 1), 1159Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Y = X;").WithLocation(6, 5), 1234Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe Y = X;").WithLocation(6, 5)); 1310Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe Y = X;").WithLocation(6, 5)); 1382Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Y = X[];").WithLocation(6, 5), 1469Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe Y = X[];").WithLocation(6, 5)); 1548Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = (int, int);").WithLocation(1, 1), 1810Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = int?;").WithLocation(1, 1), 1851Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using x = string?;").WithLocation(1, 1), 1901Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = string?;").WithLocation(2, 1), 1948Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Y = X?;").WithLocation(4, 5), 2026Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using Y = X?;").WithLocation(5, 5), 2551Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using dynamic;").WithLocation(2, 1), 3150Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = int?;").WithLocation(1, 1), 3153Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = System;").WithLocation(2, 1), 3214Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = int?;").WithLocation(1, 1), 3217Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = int;").WithLocation(2, 1), 3278Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = int?;").WithLocation(1, 1), 3281Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = System.Int32;").WithLocation(2, 1), 3351Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = int?;").WithLocation(1, 1), 3354Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = int;").WithLocation(3, 1)); 3952Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = __arglist;").WithLocation(2, 1), 3997Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using X = __makeref;").WithLocation(2, 1), 4039Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe static System.Console;").WithLocation(1, 1), 4089Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe static System.Console;").WithLocation(1, 1), 4136Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe static System.Console;").WithLocation(1, 1), 4183Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe static System.Console;").WithLocation(1, 1), 4227Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe static X = System.Console;").WithLocation(1, 1), 4288Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe static X = System.Console;").WithLocation(1, 1), 4346Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe static X = System.Console;").WithLocation(1, 1), 4404Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using unsafe static X = System.Console;").WithLocation(1, 1), 4460Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static unsafe System.Console;").WithLocation(1, 1), 4503Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static unsafe System.Console;").WithLocation(1, 1), 4543Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static unsafe System.Console;").WithLocation(1, 1), 4583Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static unsafe System.Console;").WithLocation(1, 1)); 4620Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static unsafe System.Collections.Generic.List<int*[]>;").WithLocation(1, 1), 4704Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static unsafe System.Collections.Generic.List<int*[]>;").WithLocation(1, 1), 4785Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static unsafe System.Collections.Generic.List<int*[]>;").WithLocation(1, 1), 4866Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static unsafe System.Collections.Generic.List<int*[]>;").WithLocation(1, 1)); 4945Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static System.Collections.Generic.List<int*[]>;").WithLocation(1, 1)); 5023Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static System.Collections.Generic.List<int*[]>;").WithLocation(1, 1)); 5100Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static System.Collections.Generic.List<int*[]>;").WithLocation(1, 1), 5180Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using static System.Collections.Generic.List<int*[]>;").WithLocation(1, 1),
Syntax\SyntaxTreeTests.cs (6)
370Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using ns1;").WithLocation(1, 1), 442Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using ns1;").WithLocation(1, 16), 512Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static ns1;").WithLocation(1, 1), 586Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using static ns1;").WithLocation(1, 16), 664Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using alias = ns1;").WithLocation(1, 1), 755Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "global using alias = ns1;").WithLocation(1, 16),
Microsoft.CodeAnalysis.CSharp.Test.Utilities (1)
CSharpTestBase.cs (1)
1840if (!compileDiagnostics.Any(d => d.Code == (int)ErrorCode.HDN_UnusedExternAlias || d.Code == (int)ErrorCode.HDN_UnusedUsingDirective))
Microsoft.CodeAnalysis.CSharp.WinRT.UnitTests (71)
CodeGen\WinRTCollectionTests.cs (71)
443Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 446Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 449Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 1471Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 1474Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 1477Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 1841Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 1844Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 1847Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 3201Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 3204Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 3207Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 4444Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 4447Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 4450Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 4810Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 4813Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 4816Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 4997Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 5000Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 5003Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 5195Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 5198Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 5201Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;")); 5414Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 5417Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 5420Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 5423Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 5551Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 5554Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 5557Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 5560Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 5705Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;").WithLocation(2, 1), 5708Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading;").WithLocation(4, 1), 5711Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Runtime.InteropServices;").WithLocation(3, 1)); 5821Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 5824Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 5827Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 5830Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 6048Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 6051Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 6054Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 6057Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;"), 6060Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections;")); 6247Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 6250Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 6253Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 6606Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 6609Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 6612Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 6615Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 6767Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 6770Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 6773Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 6776Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;")); 7039Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 7042Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 7045Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 7048Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;"), 7051Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections;")); 7166Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 7169Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 7172Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 7175Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;"), 7178Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections;")); 7287Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections.Generic;"), 7290Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Reflection;"), 7293Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq.Expressions;"), 7296Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Linq;"), 7299Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Collections;")); 7391Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;"));