311 references to NewKeyword
Microsoft.CodeAnalysis.CSharp (23)
Parser\LanguageParser.cs (16)
348
case SyntaxKind.
NewKeyword
:
1315
case SyntaxKind.
NewKeyword
:
2204
case SyntaxKind.
NewKeyword
:
2221
SyntaxKind.
NewKeyword
=>
2320
case SyntaxKind.
NewKeyword
:
2527
case SyntaxKind.
NewKeyword
:
8479
Debug.Assert(this.CurrentToken.Kind == SyntaxKind.
NewKeyword
);
10582
case SyntaxKind.
NewKeyword
:
10856
case SyntaxKind.
NewKeyword
:
11501
case SyntaxKind.
NewKeyword
:
12654
Debug.Assert(this.CurrentToken.Kind == SyntaxKind.
NewKeyword
);
12714
return this.CurrentToken.Kind == SyntaxKind.
NewKeyword
&& this.PeekToken(1).Kind == SyntaxKind.OpenBraceToken;
12720
var @new = this.EatToken(SyntaxKind.
NewKeyword
);
12774
SyntaxToken @new = this.EatToken(SyntaxKind.
NewKeyword
);
13002
Debug.Assert(this.CurrentToken.Kind is SyntaxKind.
NewKeyword
or SyntaxKind.StackAllocKeyword);
13008
var @new = this.EatToken(SyntaxKind.
NewKeyword
);
SymbolDisplay\SymbolDisplayVisitor.Types.cs (1)
929
AddKeyword(SyntaxKind.
NewKeyword
);
SymbolDisplay\SymbolDisplayVisitor_Minimal.cs (1)
55
return SyntaxFacts.IsInNamespaceOrTypeContext(startNode as ExpressionSyntax) || token.IsKind(SyntaxKind.
NewKeyword
) || this.InNamespaceOrType;
Symbols\Source\ModifierUtils.cs (2)
286
return SyntaxFacts.GetText(SyntaxKind.
NewKeyword
);
344
case SyntaxKind.
NewKeyword
:
Syntax\SyntaxKindFacts.cs (2)
953
return SyntaxKind.
NewKeyword
;
1601
case SyntaxKind.
NewKeyword
:
Syntax\SyntaxNormalizer.cs (1)
973
case SyntaxKind.
NewKeyword
:
Microsoft.CodeAnalysis.CSharp.CodeStyle (6)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeGeneration\CSharpSyntaxTokens.cs (1)
54
public static readonly SyntaxToken NewKeyword = Token(SyntaxKind.
NewKeyword
);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeStyle\CSharpCodeStyleOptions.cs (1)
157
SyntaxKind.
NewKeyword
,
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxTokenExtensions.cs (1)
92
case SyntaxKind.
NewKeyword
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\TokenBasedFormattingRule.cs (1)
313
if (previousToken.Kind() == SyntaxKind.
NewKeyword
)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpAccessibilityFacts.cs (1)
131
SyntaxKind.
NewKeyword
=> DeclarationModifiers.New,
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpSyntaxKinds.cs (1)
70
public int NewKeyword => (int)SyntaxKind.
NewKeyword
;
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (5)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTreeExtensions.cs (1)
1930
if (token.IsKind(SyntaxKind.
NewKeyword
))
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpTypeInferenceService.TypeInferrer.cs (1)
423
if (previousToken.Kind() == SyntaxKind.
NewKeyword
&&
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Utilities\SyntaxKindSet.cs (3)
16
SyntaxKind.
NewKeyword
,
33
SyntaxKind.
NewKeyword
,
51
SyntaxKind.
NewKeyword
,
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (7)
Formatting\Indentation\SmartTokenFormatterFormatRangeTests.cs (7)
926
await AutoFormatOnCloseBraceAsync(code, expected, SyntaxKind.
NewKeyword
);
948
await AutoFormatOnCloseBraceAsync(code, expected, SyntaxKind.
NewKeyword
);
973
await AutoFormatOnCloseBraceAsync(code, expected, SyntaxKind.
NewKeyword
);
993
await AutoFormatOnCloseBraceAsync(code, expected, SyntaxKind.
NewKeyword
);
1017
await AutoFormatOnCloseBraceAsync(code, expected, SyntaxKind.
NewKeyword
);
1041
await AutoFormatOnCloseBraceAsync(code, expected, SyntaxKind.
NewKeyword
);
2300
SyntaxKind.
NewKeyword
);
Microsoft.CodeAnalysis.CSharp.Features (37)
Completion\CompletionProviders\CSharpSuggestionModeCompletionProvider.cs (1)
113
if (token.IsKind(SyntaxKind.
NewKeyword
) && token.Parent.IsKind(SyntaxKind.ObjectCreationExpression))
Completion\CompletionProviders\DeclarationName\DeclarationNameInfo.cs (1)
557
case SyntaxKind.
NewKeyword
:
Completion\CompletionProviders\ObjectCreationCompletionProvider.cs (1)
51
if (newToken.Kind() == SyntaxKind.
NewKeyword
)
Completion\KeywordRecommenders\AbstractKeywordRecommender.cs (3)
18
SyntaxKind.
NewKeyword
,
29
SyntaxKind.
NewKeyword
,
40
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\ClassKeywordRecommender.cs (1)
16
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\ConstKeywordRecommender.cs (2)
16
SyntaxKind.
NewKeyword
,
25
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\EventKeywordRecommender.cs (1)
17
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\ExternKeywordRecommender.cs (2)
18
SyntaxKind.
NewKeyword
,
32
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\FixedKeywordRecommender.cs (1)
16
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\NewKeywordRecommender.cs (1)
46
: base(SyntaxKind.
NewKeyword
)
Completion\KeywordRecommenders\ReadOnlyKeywordRecommender.cs (1)
18
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\RecordKeywordRecommender.cs (1)
16
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\RefKeywordRecommender.cs (3)
31
SyntaxKind.
NewKeyword
,
52
SyntaxKind.
NewKeyword
,
70
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\SealedKeywordRecommender.cs (3)
18
SyntaxKind.
NewKeyword
,
29
SyntaxKind.
NewKeyword
,
40
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\StaticKeywordRecommender.cs (4)
18
SyntaxKind.
NewKeyword
,
31
SyntaxKind.
NewKeyword
,
46
SyntaxKind.
NewKeyword
,
61
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\UnsafeKeywordRecommender.cs (3)
18
SyntaxKind.
NewKeyword
,
32
SyntaxKind.
NewKeyword
,
48
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\VirtualKeywordRecommender.cs (2)
18
SyntaxKind.
NewKeyword
,
29
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\VoidKeywordRecommender.cs (1)
17
SyntaxKind.
NewKeyword
,
Completion\KeywordRecommenders\VolatileKeywordRecommender.cs (1)
17
SyntaxKind.
NewKeyword
,
EncapsulateField\CSharpEncapsulateFieldService.cs (1)
191
=> field.DeclaringSyntaxReferences.Any(static d => d.GetSyntax().GetAncestor<FieldDeclarationSyntax>().Modifiers.Any(SyntaxKind.
NewKeyword
));
LanguageServices\CSharpStructuralTypeDisplayService.cs (1)
37
members.Add(Keyword(SyntaxFacts.GetText(SyntaxKind.
NewKeyword
)));
SignatureHelp\GenericNameSignatureHelpProvider.cs (1)
284
parts.Add(Keyword(SyntaxKind.
NewKeyword
));
Snippets\CSharpClassSnippetProvider.cs (1)
27
SyntaxKind.
NewKeyword
,
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (27)
Symbols\AnonymousTypesSemanticsTests.cs (27)
69
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
73
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 3).Span,
77
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 5).Span,
87
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 7).Span);
89
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 8).Span);
309
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
313
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 3).Span,
422
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
484
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
541
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
717
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
737
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span);
774
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, NumberOfNewKeywords(LINQ) + 2).Span,
841
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, NumberOfNewKeywords(LINQ) + 2).Span,
916
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
920
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 2).Span);
981
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
985
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 2).Span);
1046
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
1052
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 2).Span);
1140
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
1144
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 3).Span,
1148
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 5).Span,
1337
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span);
1401
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
1489
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 1).Span,
1509
data.Tree.FindNodeOrTokenByKind(SyntaxKind.
NewKeyword
, 2).Span);
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (188)
Generated\Syntax.Test.xml.Generated.cs (24)
191
=> InternalSyntaxFactory.ImplicitObjectCreationExpression(InternalSyntaxFactory.Token(SyntaxKind.
NewKeyword
), GenerateArgumentList(), null);
194
=> InternalSyntaxFactory.ObjectCreationExpression(InternalSyntaxFactory.Token(SyntaxKind.
NewKeyword
), GenerateIdentifierName(), null, null);
203
=> InternalSyntaxFactory.AnonymousObjectCreationExpression(InternalSyntaxFactory.Token(SyntaxKind.
NewKeyword
), InternalSyntaxFactory.Token(SyntaxKind.OpenBraceToken), new Microsoft.CodeAnalysis.Syntax.InternalSyntax.SeparatedSyntaxList<Syntax.InternalSyntax.AnonymousObjectMemberDeclaratorSyntax>(), InternalSyntaxFactory.Token(SyntaxKind.CloseBraceToken));
206
=> InternalSyntaxFactory.ArrayCreationExpression(InternalSyntaxFactory.Token(SyntaxKind.
NewKeyword
), GenerateArrayType(), null);
209
=> InternalSyntaxFactory.ImplicitArrayCreationExpression(InternalSyntaxFactory.Token(SyntaxKind.
NewKeyword
), InternalSyntaxFactory.Token(SyntaxKind.OpenBracketToken), new Microsoft.CodeAnalysis.Syntax.InternalSyntax.SyntaxList<Syntax.InternalSyntax.SyntaxToken>(), InternalSyntaxFactory.Token(SyntaxKind.CloseBracketToken), GenerateInitializerExpression());
536
=> InternalSyntaxFactory.ConstructorConstraint(InternalSyntaxFactory.Token(SyntaxKind.
NewKeyword
), InternalSyntaxFactory.Token(SyntaxKind.OpenParenToken), InternalSyntaxFactory.Token(SyntaxKind.CloseParenToken));
1445
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind);
1457
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind);
1493
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind);
1506
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind);
1518
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind);
2944
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind);
10407
=> SyntaxFactory.ImplicitObjectCreationExpression(SyntaxFactory.Token(SyntaxKind.
NewKeyword
), GenerateArgumentList(), default(InitializerExpressionSyntax));
10410
=> SyntaxFactory.ObjectCreationExpression(SyntaxFactory.Token(SyntaxKind.
NewKeyword
), GenerateIdentifierName(), default(ArgumentListSyntax), default(InitializerExpressionSyntax));
10419
=> SyntaxFactory.AnonymousObjectCreationExpression(SyntaxFactory.Token(SyntaxKind.
NewKeyword
), SyntaxFactory.Token(SyntaxKind.OpenBraceToken), new SeparatedSyntaxList<AnonymousObjectMemberDeclaratorSyntax>(), SyntaxFactory.Token(SyntaxKind.CloseBraceToken));
10422
=> SyntaxFactory.ArrayCreationExpression(SyntaxFactory.Token(SyntaxKind.
NewKeyword
), GenerateArrayType(), default(InitializerExpressionSyntax));
10425
=> SyntaxFactory.ImplicitArrayCreationExpression(SyntaxFactory.Token(SyntaxKind.
NewKeyword
), SyntaxFactory.Token(SyntaxKind.OpenBracketToken), new SyntaxTokenList(), SyntaxFactory.Token(SyntaxKind.CloseBracketToken), GenerateInitializerExpression());
10752
=> SyntaxFactory.ConstructorConstraint(SyntaxFactory.Token(SyntaxKind.
NewKeyword
), SyntaxFactory.Token(SyntaxKind.OpenParenToken), SyntaxFactory.Token(SyntaxKind.CloseParenToken));
11661
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind());
11673
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind());
11709
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind());
11722
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind());
11734
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind());
13160
Assert.Equal(SyntaxKind.
NewKeyword
, node.NewKeyword.Kind());
Parsing\AllowsConstraintParsing.cs (3)
1466
N(SyntaxKind.
NewKeyword
);
1535
N(SyntaxKind.
NewKeyword
);
1880
N(SyntaxKind.
NewKeyword
);
Parsing\AnonymousFunctionParsingTests.cs (10)
1193
N(SyntaxKind.
NewKeyword
);
1250
N(SyntaxKind.
NewKeyword
);
1296
N(SyntaxKind.
NewKeyword
);
1363
N(SyntaxKind.
NewKeyword
);
1441
N(SyntaxKind.
NewKeyword
);
1497
N(SyntaxKind.
NewKeyword
);
1551
N(SyntaxKind.
NewKeyword
);
1645
N(SyntaxKind.
NewKeyword
);
1749
N(SyntaxKind.
NewKeyword
);
1826
N(SyntaxKind.
NewKeyword
);
Parsing\AwaitParsingTests.cs (2)
709
N(SyntaxKind.
NewKeyword
);
1921
N(SyntaxKind.
NewKeyword
);
Parsing\CollectionExpressionParsingTests.cs (8)
6668
N(SyntaxKind.
NewKeyword
);
6700
N(SyntaxKind.
NewKeyword
);
6737
N(SyntaxKind.
NewKeyword
);
6781
N(SyntaxKind.
NewKeyword
);
6832
N(SyntaxKind.
NewKeyword
);
7708
N(SyntaxKind.
NewKeyword
);
7739
N(SyntaxKind.
NewKeyword
);
7771
N(SyntaxKind.
NewKeyword
);
Parsing\DeclarationParsingTests.cs (3)
4655
TestClassPropertyWithModifier(SyntaxKind.
NewKeyword
);
4669
TestClassPropertyWithModifier(SyntaxKind.
NewKeyword
);
4862
TestClassEventPropertyWithModifier(SyntaxKind.
NewKeyword
);
Parsing\DeclarationScopeParsingTests.cs (6)
8060
N(SyntaxKind.
NewKeyword
);
8109
N(SyntaxKind.
NewKeyword
);
8163
N(SyntaxKind.
NewKeyword
);
8208
N(SyntaxKind.
NewKeyword
);
8271
N(SyntaxKind.
NewKeyword
);
8327
N(SyntaxKind.
NewKeyword
);
Parsing\DeconstructionTests.cs (1)
1703
N(SyntaxKind.
NewKeyword
);
Parsing\ExpressionParsingTests.cs (23)
375
N(SyntaxKind.
NewKeyword
);
1389
N(SyntaxKind.
NewKeyword
);
1433
N(SyntaxKind.
NewKeyword
);
1471
N(SyntaxKind.
NewKeyword
);
1515
N(SyntaxKind.
NewKeyword
);
1567
N(SyntaxKind.
NewKeyword
);
1613
N(SyntaxKind.
NewKeyword
);
1653
N(SyntaxKind.
NewKeyword
);
1693
N(SyntaxKind.
NewKeyword
);
1733
N(SyntaxKind.
NewKeyword
);
1781
N(SyntaxKind.
NewKeyword
);
1813
N(SyntaxKind.
NewKeyword
);
4898
N(SyntaxKind.
NewKeyword
);
6027
N(SyntaxKind.
NewKeyword
);
6058
N(SyntaxKind.
NewKeyword
);
6088
N(SyntaxKind.
NewKeyword
);
6123
N(SyntaxKind.
NewKeyword
);
6152
N(SyntaxKind.
NewKeyword
);
6193
N(SyntaxKind.
NewKeyword
);
6229
N(SyntaxKind.
NewKeyword
);
6406
N(SyntaxKind.
NewKeyword
);
6433
N(SyntaxKind.
NewKeyword
);
6461
N(SyntaxKind.
NewKeyword
);
Parsing\FieldKeywordParsingTests.cs (1)
1662
N(SyntaxKind.
NewKeyword
);
Parsing\FunctionPointerTests.cs (1)
2026
N(SyntaxKind.
NewKeyword
);
Parsing\ImplicitObjectCreationParsingTests.cs (17)
30
N(SyntaxKind.
NewKeyword
);
51
N(SyntaxKind.
NewKeyword
);
99
N(SyntaxKind.
NewKeyword
);
119
N(SyntaxKind.
NewKeyword
);
137
N(SyntaxKind.
NewKeyword
);
184
N(SyntaxKind.
NewKeyword
);
227
N(SyntaxKind.
NewKeyword
);
265
N(SyntaxKind.
NewKeyword
);
319
N(SyntaxKind.
NewKeyword
);
355
N(SyntaxKind.
NewKeyword
);
392
N(SyntaxKind.
NewKeyword
);
420
N(SyntaxKind.
NewKeyword
);
436
N(SyntaxKind.
NewKeyword
);
469
N(SyntaxKind.
NewKeyword
);
490
N(SyntaxKind.
NewKeyword
);
556
N(SyntaxKind.
NewKeyword
);
604
N(SyntaxKind.
NewKeyword
);
Parsing\LambdaAttributeParsingTests.cs (7)
1055
N(SyntaxKind.
NewKeyword
);
1108
N(SyntaxKind.
NewKeyword
);
2708
N(SyntaxKind.
NewKeyword
);
2802
N(SyntaxKind.
NewKeyword
);
2893
N(SyntaxKind.
NewKeyword
);
2968
N(SyntaxKind.
NewKeyword
);
3021
N(SyntaxKind.
NewKeyword
);
Parsing\LocalFunctionParsingTests.cs (5)
1444
N(SyntaxKind.
NewKeyword
);
1492
N(SyntaxKind.
NewKeyword
);
1546
N(SyntaxKind.
NewKeyword
);
1594
N(SyntaxKind.
NewKeyword
);
1651
N(SyntaxKind.
NewKeyword
);
Parsing\MemberDeclarationParsingTests.cs (1)
12509
N(SyntaxKind.
NewKeyword
);
Parsing\NullableParsingTests.cs (7)
1392
N(SyntaxKind.
NewKeyword
);
1444
N(SyntaxKind.
NewKeyword
);
1503
N(SyntaxKind.
NewKeyword
);
1567
N(SyntaxKind.
NewKeyword
);
1631
N(SyntaxKind.
NewKeyword
);
1695
N(SyntaxKind.
NewKeyword
);
1722
N(SyntaxKind.
NewKeyword
);
Parsing\ParsingErrorRecoveryTests.cs (5)
5232
N(SyntaxKind.
NewKeyword
);
5344
N(SyntaxKind.
NewKeyword
);
5491
N(SyntaxKind.
NewKeyword
);
5604
N(SyntaxKind.
NewKeyword
);
5741
N(SyntaxKind.
NewKeyword
);
Parsing\PatternParsingTests.cs (1)
12707
N(SyntaxKind.
NewKeyword
);
Parsing\RecordParsing.cs (2)
1036
N(SyntaxKind.
NewKeyword
);
3763
N(SyntaxKind.
NewKeyword
);
Parsing\RefFieldParsingTests.cs (11)
703
N(SyntaxKind.
NewKeyword
);
747
N(SyntaxKind.
NewKeyword
);
794
N(SyntaxKind.
NewKeyword
);
852
N(SyntaxKind.
NewKeyword
);
884
N(SyntaxKind.
NewKeyword
);
942
N(SyntaxKind.
NewKeyword
);
992
N(SyntaxKind.
NewKeyword
);
1023
N(SyntaxKind.
NewKeyword
);
1062
N(SyntaxKind.
NewKeyword
);
1101
N(SyntaxKind.
NewKeyword
);
1148
N(SyntaxKind.
NewKeyword
);
Parsing\RefReadonlyTests.cs (1)
465
N(SyntaxKind.
NewKeyword
);
Parsing\ScriptParsingTests.cs (26)
109
N(SyntaxKind.
NewKeyword
);
321
N(SyntaxKind.
NewKeyword
);
354
N(SyntaxKind.
NewKeyword
);
393
N(SyntaxKind.
NewKeyword
);
435
N(SyntaxKind.
NewKeyword
);
486
N(SyntaxKind.
NewKeyword
);
518
N(SyntaxKind.
NewKeyword
);
544
N(SyntaxKind.
NewKeyword
);
583
N(SyntaxKind.
NewKeyword
);
611
N(SyntaxKind.
NewKeyword
);
651
N(SyntaxKind.
NewKeyword
);
692
N(SyntaxKind.
NewKeyword
);
721
N(SyntaxKind.
NewKeyword
);
750
N(SyntaxKind.
NewKeyword
);
785
N(SyntaxKind.
NewKeyword
);
813
N(SyntaxKind.
NewKeyword
);
857
N(SyntaxKind.
NewKeyword
);
917
N(SyntaxKind.
NewKeyword
);
964
NewModifier_WithOtherModifier("new", SyntaxKind.
NewKeyword
);
979
N(SyntaxKind.
NewKeyword
);
1008
N(SyntaxKind.
NewKeyword
);
1029
N(SyntaxKind.
NewKeyword
);
1057
N(SyntaxKind.
NewKeyword
);
1086
N(SyntaxKind.
NewKeyword
);
1612
N(SyntaxKind.
NewKeyword
);
1659
N(SyntaxKind.
NewKeyword
);
Parsing\SeparatedSyntaxListParsingTests.cs (10)
367
N(SyntaxKind.
NewKeyword
);
407
N(SyntaxKind.
NewKeyword
);
822
N(SyntaxKind.
NewKeyword
);
861
N(SyntaxKind.
NewKeyword
);
900
N(SyntaxKind.
NewKeyword
);
944
N(SyntaxKind.
NewKeyword
);
988
N(SyntaxKind.
NewKeyword
);
1037
N(SyntaxKind.
NewKeyword
);
1081
N(SyntaxKind.
NewKeyword
);
1125
N(SyntaxKind.
NewKeyword
);
Parsing\StatementAttributeParsingTests.cs (5)
3804
N(SyntaxKind.
NewKeyword
);
3878
N(SyntaxKind.
NewKeyword
);
3971
N(SyntaxKind.
NewKeyword
);
5241
N(SyntaxKind.
NewKeyword
);
5319
N(SyntaxKind.
NewKeyword
);
Parsing\StatementParsingTests.cs (4)
4076
N(SyntaxKind.
NewKeyword
);
4135
N(SyntaxKind.
NewKeyword
);
4262
N(SyntaxKind.
NewKeyword
);
4631
N(SyntaxKind.
NewKeyword
);
Parsing\SwitchExpressionParsingTests.cs (1)
431
N(SyntaxKind.
NewKeyword
);
Parsing\TopLevelStatementsParsingTests.cs (2)
1593
N(SyntaxKind.
NewKeyword
);
1849
N(SyntaxKind.
NewKeyword
);
Parsing\TypeArgumentListParsingTests.cs (1)
749
N(SyntaxKind.
NewKeyword
);
Microsoft.CodeAnalysis.CSharp.Workspaces (11)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeGeneration\CSharpSyntaxTokens.cs (1)
54
public static readonly SyntaxToken NewKeyword = Token(SyntaxKind.
NewKeyword
);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeStyle\CSharpCodeStyleOptions.cs (1)
157
SyntaxKind.
NewKeyword
,
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxTokenExtensions.cs (1)
92
case SyntaxKind.
NewKeyword
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\TokenBasedFormattingRule.cs (1)
313
if (previousToken.Kind() == SyntaxKind.
NewKeyword
)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpAccessibilityFacts.cs (1)
131
SyntaxKind.
NewKeyword
=> DeclarationModifiers.New,
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpSyntaxKinds.cs (1)
70
public int NewKeyword => (int)SyntaxKind.
NewKeyword
;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTreeExtensions.cs (1)
1930
if (token.IsKind(SyntaxKind.
NewKeyword
))
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpTypeInferenceService.TypeInferrer.cs (1)
423
if (previousToken.Kind() == SyntaxKind.
NewKeyword
&&
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Utilities\SyntaxKindSet.cs (3)
16
SyntaxKind.
NewKeyword
,
33
SyntaxKind.
NewKeyword
,
51
SyntaxKind.
NewKeyword
,
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (1)
CodeGeneration\CodeGenerationTests.cs (1)
746
yield return CS.SyntaxFactory.Token(CS.SyntaxKind.
NewKeyword
);
Microsoft.Gen.Logging (1)
Parsing\Parser.LogProperties.cs (1)
242
if (ParserUtilities.PropertyHasModifier(property, SyntaxKind.
NewKeyword
, _cancellationToken))
Microsoft.Interop.ComInterfaceGenerator (3)
ComInterfaceGenerator.cs (1)
369
var methodSyntaxTemplate = new ContainingSyntax(new SyntaxTokenList(syntax.Modifiers.Where(static m => !m.IsKind(SyntaxKind.
NewKeyword
))).StripAccessibilityModifiers(), SyntaxKind.MethodDeclaration, syntax.Identifier, syntax.TypeParameterList);
ComMethodContext.cs (1)
132
.WithModifiers(TokenList(Token(SyntaxKind.
NewKeyword
)))
ComMethodInfo.cs (1)
151
bool shadowsBaseMethod = comMethodDeclaringSyntax.Modifiers.Any(SyntaxKind.
NewKeyword
);
Microsoft.VisualStudio.LanguageServices.CSharp (2)
CodeModel\ModifierFlagsExtensions.cs (2)
25
{ ModifierFlags.New, SyntaxKind.
NewKeyword
},
64
case SyntaxKind.
NewKeyword
: