192 references to MethodDeclaration
Microsoft.Analyzers.Extra (1)
CallAnalysis\Fixers\LegacyLoggingFixer.cs (1)
586
var logMethod = gen.
MethodDeclaration
(
Microsoft.CodeAnalysis.CSharp.Workspaces.UnitTests (85)
CodeGeneration\SymbolEditorTests.cs (16)
82
var newSymbol = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbol, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("m")));
114
var newSymbol = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbol, (e, d) => e.AddMember(d, Generator.
MethodDeclaration
("m")));
118
newSymbol = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbol, (e, d) => e.AddMember(d, Generator.
MethodDeclaration
("m2")));
151
var newSymbol = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbol, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("m")));
155
newSymbol = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(newSymbol, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("m2")));
198
var newSymbolA = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbolA, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("ma")));
201
var newSymbolB = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbolB, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("mb")));
244
var newSymbolA = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbolA, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("ma")));
247
var newSymbolB = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbolB, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("mb")));
359
var newSymbol = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbol, location, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("m")));
396
var newSymbol = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbol, location, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("m")));
437
var newSymbol = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbol, location, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("m")));
441
var newSymbol2 = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(newSymbol, location, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("m2")));
483
var newSymbol = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbol, location, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("m")));
488
var newSymbol2 = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(newSymbol, newLocation, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("m2")));
533
var newSymbol = (INamedTypeSymbol)await editor.EditOneDeclarationAsync(symbol, member, (e, d) => e.AddMember(d, e.Generator.
MethodDeclaration
("m2")));
CodeGeneration\SyntaxGeneratorTests.cs (69)
805
Generator.
MethodDeclaration
("m"),
813
Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("x")),
829
Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("x"), accessibility: Accessibility.Public),
833
Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("x"), accessibility: Accessibility.Public, modifiers: DeclarationModifiers.Abstract),
837
Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Partial),
845
Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Partial | DeclarationModifiers.Async, statements: null),
1171
Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("t"), modifiers: DeclarationModifiers.Abstract),
1189
Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("t"), accessibility: Accessibility.Private, modifiers: DeclarationModifiers.Abstract),
1474
Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("t"), accessibility: Accessibility.Private, modifiers: DeclarationModifiers.Abstract),
1498
Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("t"), accessibility: Accessibility.Private, modifiers: DeclarationModifiers.Abstract),
1562
Generator.ClassDeclaration("c", members: [Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("t"))]),
1598
Generator.StructDeclaration("s", members: [Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("t"))]),
1630
Generator.InterfaceDeclaration("i", members: [Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("t"), accessibility: Accessibility.Public, modifiers: DeclarationModifiers.Sealed)]),
1858
Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("t"), modifiers: DeclarationModifiers.Abstract),
1864
Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("t"), modifiers: DeclarationModifiers.Abstract),
2001
Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract),
2007
Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract)),
2012
Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract),
2018
Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract),
2052
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a"),
2058
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a"),
2064
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a"),
2070
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a"),
2077
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a", "x"),
2084
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a"),
2090
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a"),
2096
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a"),
2102
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a"),
2108
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a"),
2114
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Abstract), "a"),
2627
AssertNamesEqual("", Generator.GetNamespaceImports(Generator.AddNamespaceImports(Generator.CompilationUnit(), Generator.
MethodDeclaration
("m"))));
2749
AssertMemberNamesEqual("m", Generator.AddMembers(Generator.ClassDeclaration("d"), [Generator.
MethodDeclaration
("m")]));
2750
AssertMemberNamesEqual("m", Generator.AddMembers(Generator.StructDeclaration("s"), [Generator.
MethodDeclaration
("m")]));
2751
AssertMemberNamesEqual("m", Generator.AddMembers(Generator.InterfaceDeclaration("i"), [Generator.
MethodDeclaration
("m")]));
2757
AssertMemberNamesEqual(new[] { "m", "m2" }, Generator.AddMembers(Generator.ClassDeclaration("d", members: [Generator.
MethodDeclaration
("m")]), [Generator.
MethodDeclaration
("m2")]));
2758
AssertMemberNamesEqual(new[] { "m", "m2" }, Generator.AddMembers(Generator.StructDeclaration("s", members: [Generator.
MethodDeclaration
("m")]), [Generator.
MethodDeclaration
("m2")]));
2759
AssertMemberNamesEqual(new[] { "m", "m2" }, Generator.AddMembers(Generator.InterfaceDeclaration("i", members: [Generator.
MethodDeclaration
("m")]), [Generator.
MethodDeclaration
("m2")]));
2799
var method = (MethodDeclarationSyntax)Generator.
MethodDeclaration
("m");
2839
TestRemoveAllMembers(Generator.ClassDeclaration("c", members: [Generator.
MethodDeclaration
("m")]));
2840
TestRemoveAllMembers(Generator.StructDeclaration("s", members: [Generator.
MethodDeclaration
("m")]));
2841
TestRemoveAllMembers(Generator.InterfaceDeclaration("i", members: [Generator.
MethodDeclaration
("m")]));
2846
TestRemoveMember(Generator.ClassDeclaration("c", members: [Generator.
MethodDeclaration
("m1"), Generator.
MethodDeclaration
("m2")]), "m1", ["m2"]);
2847
TestRemoveMember(Generator.StructDeclaration("s", members: [Generator.
MethodDeclaration
("m1"), Generator.
MethodDeclaration
("m2")]), "m1", ["m2"]);
2862
AssertMemberNamesEqual("m", Generator.ClassDeclaration("c", members: [Generator.
MethodDeclaration
("m")]));
2863
AssertMemberNamesEqual("m", Generator.StructDeclaration("s", members: [Generator.
MethodDeclaration
("m")]));
2864
AssertMemberNamesEqual("m", Generator.InterfaceDeclaration("i", members: [Generator.
MethodDeclaration
("m")]));
2879
Assert.Equal(DeclarationKind.Method, Generator.GetDeclarationKind(Generator.
MethodDeclaration
("m")));
2902
Assert.Equal("m", Generator.GetName(Generator.
MethodDeclaration
("m")));
2925
Assert.Equal("m", Generator.GetName(Generator.WithName(Generator.
MethodDeclaration
("x"), "m")));
2948
Assert.Equal(Accessibility.Internal, Generator.GetAccessibility(Generator.
MethodDeclaration
("m", accessibility: Accessibility.Internal)));
2972
Assert.Equal(Accessibility.Private, Generator.GetAccessibility(Generator.WithAccessibility(Generator.
MethodDeclaration
("m", accessibility: Accessibility.Internal), Accessibility.Private)));
2996
Assert.Equal(DeclarationModifiers.Static, Generator.GetModifiers(Generator.
MethodDeclaration
("m", modifiers: DeclarationModifiers.Static)));
3019
Assert.Equal(DeclarationModifiers.Static, Generator.GetModifiers(Generator.WithModifiers(Generator.
MethodDeclaration
("m"), DeclarationModifiers.Static)));
3074
Generator.GetModifiers(Generator.WithModifiers(Generator.
MethodDeclaration
("m"), allModifiers)));
3194
Assert.Equal("t", Generator.GetType(Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("t"))).ToString());
3195
Assert.Null(Generator.GetType(Generator.
MethodDeclaration
("m")));
3217
Assert.Equal("t", Generator.GetType(Generator.WithType(Generator.
MethodDeclaration
("m", returnType: Generator.IdentifierName("x")), Generator.IdentifierName("t"))).ToString());
3236
Assert.Equal(0, Generator.GetParameters(Generator.
MethodDeclaration
("m")).Count);
3263
Assert.Equal(1, Generator.GetParameters(Generator.AddParameters(Generator.
MethodDeclaration
("m"), [Generator.ParameterDeclaration("p", Generator.IdentifierName("t"))])).Count);
3298
var method = (MethodDeclarationSyntax)Generator.
MethodDeclaration
("p");
3334
var method = (MethodDeclarationSyntax)Generator.
MethodDeclaration
("p");
3541
Assert.Equal(0, Generator.GetStatements(Generator.
MethodDeclaration
("m")).Count);
3542
Assert.Equal(2, Generator.GetStatements(Generator.
MethodDeclaration
("m", statements: stmts)).Count);
3568
Assert.Equal(2, Generator.GetStatements(Generator.WithStatements(Generator.
MethodDeclaration
("m"), stmts)).Count);
Microsoft.CodeAnalysis.VisualBasic.Workspaces.UnitTests (88)
CodeGeneration\SyntaxGeneratorTests.vb (88)
847
Generator.
MethodDeclaration
("m"),
852
Generator.
MethodDeclaration
("m", typeParameters:={"x", "y"}),
857
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("x")),
862
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("x"), statements:={Generator.ReturnStatement(Generator.IdentifierName("y"))}),
868
Generator.
MethodDeclaration
("m", parameters:={Generator.ParameterDeclaration("z", Generator.IdentifierName("y"))}, returnType:=Generator.IdentifierName("x")),
873
Generator.
MethodDeclaration
("m", parameters:={Generator.ParameterDeclaration("z", Generator.IdentifierName("y"), Generator.IdentifierName("a"))}, returnType:=Generator.IdentifierName("x")),
878
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("x"), accessibility:=Accessibility.Public, modifiers:=DeclarationModifiers.None),
883
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("x"), accessibility:=Accessibility.Public, modifiers:=DeclarationModifiers.Abstract),
887
Generator.
MethodDeclaration
("m", accessibility:=Accessibility.Private, modifiers:=DeclarationModifiers.Partial),
895
Dim md = Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Sealed)
902
Dim md2 = Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Sealed + DeclarationModifiers.Override)
920
Dim md = Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract)
1492
Generator.StructDeclaration("s", members:={Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"))}),
1541
Generator.InterfaceDeclaration("i", members:={Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"), accessibility:=Accessibility.Public, modifiers:=DeclarationModifiers.Sealed)}),
1755
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"), modifiers:=DeclarationModifiers.Abstract),
1762
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"), modifiers:=DeclarationModifiers.None),
1805
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t")),
1823
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"), accessibility:=Accessibility.Private, modifiers:=DeclarationModifiers.Abstract),
1830
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"), accessibility:=Accessibility.Private, modifiers:=DeclarationModifiers.Abstract),
1861
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t")),
1879
Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract),
1885
Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.None),
1893
Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract)),
1898
Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.None)),
1905
Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract),
1911
Generator.
MethodDeclaration
("m"),
1919
Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract),
1925
Generator.
MethodDeclaration
("m"),
1958
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a"),
1964
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m"), "a"),
1972
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a"),
1978
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m"), "a"),
1986
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a"),
1992
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m"), "a"),
2000
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a"),
2006
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m"), "a"),
2015
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a", "x"),
2023
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a"),
2030
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a"),
2037
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a"),
2044
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a"),
2051
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a"),
2058
Generator.WithTypeParameters(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), "a"),
2150
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"), modifiers:=DeclarationModifiers.Abstract),
2157
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"), modifiers:=DeclarationModifiers.Abstract),
2163
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"), modifiers:=DeclarationModifiers.None),
2171
Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"), modifiers:=DeclarationModifiers.None),
2571
Assert.Equal(DeclarationKind.Method, Generator.GetDeclarationKind(Generator.
MethodDeclaration
("m")))
2572
Assert.Equal(DeclarationKind.Method, Generator.GetDeclarationKind(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract)))
2596
Assert.Equal("m", Generator.GetName(Generator.
MethodDeclaration
("m")))
2597
Assert.Equal("m", Generator.GetName(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract)))
2621
Assert.Equal("m", Generator.GetName(Generator.WithName(Generator.
MethodDeclaration
("x"), "m")))
2622
Assert.Equal("m", Generator.GetName(Generator.WithName(Generator.
MethodDeclaration
("x", modifiers:=DeclarationModifiers.Abstract), "m")))
2646
Assert.Equal(Accessibility.Internal, Generator.GetAccessibility(Generator.
MethodDeclaration
("m", accessibility:=Accessibility.Internal)))
2674
Assert.Equal(Accessibility.Private, Generator.GetAccessibility(Generator.WithAccessibility(Generator.
MethodDeclaration
("m", accessibility:=Accessibility.Internal), Accessibility.Private)))
2701
Assert.Equal(DeclarationModifiers.Static, Generator.GetModifiers(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Static)))
2723
Assert.Equal(DeclarationModifiers.Static, Generator.GetModifiers(Generator.WithModifiers(Generator.
MethodDeclaration
("m"), DeclarationModifiers.Static)))
2754
classBlock = DirectCast(Generator.AddMembers(classBlock, Generator.WithModifiers(Generator.
MethodDeclaration
("Goo"), DeclarationModifiers.Sealed)), ClassBlockSyntax)
2764
Assert.Equal("t", Generator.GetType(Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("t"))).ToString())
2765
Assert.Null(Generator.GetType(Generator.
MethodDeclaration
("m")))
2786
Assert.Equal("t", Generator.GetType(Generator.WithType(Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("x")), Generator.IdentifierName("t"))).ToString())
2787
Assert.Equal("t", Generator.GetType(Generator.WithType(Generator.
MethodDeclaration
("m"), Generator.IdentifierName("t"))).ToString())
2807
Generator.WithType(Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("x")), Nothing),
2812
Generator.WithType(Generator.
MethodDeclaration
("m"), Generator.IdentifierName("x")),
2817
Generator.WithType(Generator.
MethodDeclaration
("m", returnType:=Generator.IdentifierName("x"), modifiers:=DeclarationModifiers.Abstract), Nothing),
2821
Generator.WithType(Generator.
MethodDeclaration
("m", modifiers:=DeclarationModifiers.Abstract), Generator.IdentifierName("x")),
2836
Assert.Equal(0, Generator.GetParameters(Generator.
MethodDeclaration
("m")).Count)
2837
Assert.Equal(1, Generator.GetParameters(Generator.
MethodDeclaration
("m", parameters:={Generator.ParameterDeclaration("p", Generator.IdentifierName("t"))})).Count)
2838
Assert.Equal(2, Generator.GetParameters(Generator.
MethodDeclaration
("m", parameters:={Generator.ParameterDeclaration("p", Generator.IdentifierName("t")), Generator.ParameterDeclaration("p2", Generator.IdentifierName("t2"))})).Count)
2864
Assert.Equal(1, Generator.GetParameters(Generator.AddParameters(Generator.
MethodDeclaration
("m"), {Generator.ParameterDeclaration("p", Generator.IdentifierName("t"))})).Count)
2965
Assert.Equal(0, Generator.GetStatements(Generator.
MethodDeclaration
("m")).Count)
2966
Assert.Equal(2, Generator.GetStatements(Generator.
MethodDeclaration
("m", statements:=stmts)).Count)
2986
Assert.Equal(2, Generator.GetStatements(Generator.WithStatements(Generator.
MethodDeclaration
("m"), stmts)).Count)
3158
AssertMemberNamesEqual("m", Generator.ClassDeclaration("c", members:={Generator.
MethodDeclaration
("m")}))
3159
AssertMemberNamesEqual("m", Generator.StructDeclaration("s", members:={Generator.
MethodDeclaration
("m")}))
3160
AssertMemberNamesEqual("m", Generator.InterfaceDeclaration("i", members:={Generator.
MethodDeclaration
("m")}))
3168
AssertMemberNamesEqual("m", Generator.AddMembers(Generator.ClassDeclaration("d"), {Generator.
MethodDeclaration
("m")}))
3169
AssertMemberNamesEqual("m", Generator.AddMembers(Generator.StructDeclaration("s"), {Generator.
MethodDeclaration
("m")}))
3170
AssertMemberNamesEqual("m", Generator.AddMembers(Generator.InterfaceDeclaration("i"), {Generator.
MethodDeclaration
("m")}))
3175
AssertMemberNamesEqual({"m", "m2"}, Generator.AddMembers(Generator.ClassDeclaration("d", members:={Generator.
MethodDeclaration
("m")}), {Generator.
MethodDeclaration
("m2")}))
3176
AssertMemberNamesEqual({"m", "m2"}, Generator.AddMembers(Generator.StructDeclaration("s", members:={Generator.
MethodDeclaration
("m")}), {Generator.
MethodDeclaration
("m2")}))
3177
AssertMemberNamesEqual({"m", "m2"}, Generator.AddMembers(Generator.InterfaceDeclaration("i", members:={Generator.
MethodDeclaration
("m")}), {Generator.
MethodDeclaration
("m2")}))
3185
TestRemoveAllMembers(Generator.ClassDeclaration("d", members:={Generator.
MethodDeclaration
("m")}))
3186
TestRemoveAllMembers(Generator.StructDeclaration("s", members:={Generator.
MethodDeclaration
("m")}))
3187
TestRemoveAllMembers(Generator.InterfaceDeclaration("i", members:={Generator.
MethodDeclaration
("m")}))
Microsoft.Interop.LibraryImportGenerator (17)
Analyzers\CustomMarshallerAttributeFixer.cs (17)
222
gen.
MethodDeclaration
(
234
gen.
MethodDeclaration
(
257
gen.
MethodDeclaration
(
273
gen.
MethodDeclaration
(
289
gen.
MethodDeclaration
(
304
gen.
MethodDeclaration
(
320
gen.
MethodDeclaration
(
336
gen.
MethodDeclaration
(
418
gen.
MethodDeclaration
(
428
gen.
MethodDeclaration
(
438
gen.
MethodDeclaration
(
448
gen.
MethodDeclaration
(
469
gen.
MethodDeclaration
(
479
gen.
MethodDeclaration
(
489
gen.
MethodDeclaration
(
503
gen.
MethodDeclaration
(
517
gen.
MethodDeclaration
(
System.Text.RegularExpressions.Generator (1)
UpgradeToGeneratedRegexCodeFixer.cs (1)
183
MethodDeclarationSyntax newMethod = (MethodDeclarationSyntax)generator.
MethodDeclaration
(