86 references to LiteralExpression
Microsoft.AspNetCore.Mvc.Api.Analyzers (1)
AddResponseTypeAttributeCodeFixAction.cs (1)
243return SyntaxFactory.LiteralExpression(SyntaxKind.NumericLiteralExpression, SyntaxFactory.Literal(statusCode));
Microsoft.CodeAnalysis.CSharp (2)
_generated\2\Syntax.xml.Syntax.Generated.cs (1)
2024var newNode = SyntaxFactory.LiteralExpression(this.Kind(), token);
Syntax\LiteralExpressionSyntax.cs (1)
14=> SyntaxFactory.LiteralExpression(kind, SyntaxFactory.Token(GetLiteralExpressionTokenKind(kind)));
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (9)
src\roslyn\src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpCollectionExpressionRewriter.cs (1)
105[LiteralExpression(SyntaxKind.NullLiteralExpression, NullKeyword.WithAdditionalAnnotations(nullTokenAnnotation))],
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\EnumMemberGenerator.cs (4)
133LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(numericLiteral.Token.Text, 1)), 134LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(shiftValue.ToString(), shiftValue))); 146return LiteralExpression(SyntaxKind.NumericLiteralExpression, 151return LiteralExpression(SyntaxKind.NumericLiteralExpression,
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\ExpressionGenerator.cs (3)
115return LiteralExpression( 122return LiteralExpression( 278var literal = LiteralExpression(
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpSyntaxGeneratorInternal.cs (1)
288return SyntaxFactory.LiteralExpression(
Microsoft.CodeAnalysis.CSharp.Features (9)
CodeFixes\Suppression\CSharpSuppressionCodeFixProvider.cs (5)
180var category = LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(diagnostic.Descriptor.Category)); 185var ruleId = LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(ruleIdText)); 188var justificationExpr = LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(FeaturesResources.Pending)); 198var scopeExpr = LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(scopeString)); 202var targetExpr = LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(targetString));
ConvertLinq\CSharpConvertLinqQueryToForEachProvider.cs (1)
319LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(0)), // count = 0
SplitStringLiteral\SimpleStringSplitter.cs (2)
64var leftExpression = SyntaxFactory.LiteralExpression(SyntaxKind.StringLiteralExpression, firstToken); 65var rightExpression = SyntaxFactory.LiteralExpression(SyntaxKind.StringLiteralExpression, secondToken);
src\roslyn\src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpCollectionExpressionRewriter.cs (1)
105[LiteralExpression(SyntaxKind.NullLiteralExpression, NullKeyword.WithAdditionalAnnotations(nullTokenAnnotation))],
Microsoft.CodeAnalysis.CSharp.NetAnalyzers (2)
Microsoft.NetCore.Analyzers\Performance\CSharpPreferLengthCountIsEmptyOverAny.Fixer.cs (1)
81LiteralExpression(
Microsoft.NetCore.Analyzers\Performance\CSharpUseSearchValues.Fixer.cs (1)
139return SyntaxFactory.LiteralExpression(
Microsoft.CodeAnalysis.CSharp.Workspaces (8)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\EnumMemberGenerator.cs (4)
133LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(numericLiteral.Token.Text, 1)), 134LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(shiftValue.ToString(), shiftValue))); 146return LiteralExpression(SyntaxKind.NumericLiteralExpression, 151return LiteralExpression(SyntaxKind.NumericLiteralExpression,
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\ExpressionGenerator.cs (3)
115return LiteralExpression( 122return LiteralExpression( 278var literal = LiteralExpression(
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpSyntaxGeneratorInternal.cs (1)
288return SyntaxFactory.LiteralExpression(
Microsoft.Interop.ComInterfaceGenerator (3)
ComInterfaceGeneratorHelpers.cs (1)
45literals[i] = ExpressionElement(LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(bytes[i])));
Marshallers\ManagedHResultExceptionGeneratorResolver.cs (1)
89LiteralExpression(
VirtualMethodPointerStubGenerator.cs (1)
75Argument(LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(methodStub.VtableIndexData.Index)))),
Microsoft.Interop.JavaScript.JSImportGenerator (12)
JSExportGenerator.cs (9)
249LiteralExpression(SyntaxKind.StringLiteralExpression, Literal($"{generatedNamespace}.{initializerClass}")) 253LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(assemblyName)) 348AttributeArgument(LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(wrapperName))), 349AttributeArgument(LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(incrementalContext.SignatureContext.StubTypeFullName))), 350AttributeArgument(LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(incrementalContext.SignatureContext.AssemblyName))), 377LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(nativeArg.NativeIndex + 2)))))))); 389LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(1))))); 413Argument(LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(context.QualifiedMethodName))), 414Argument(LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(context.TypesHash))),
JSImportGenerator.cs (3)
265Argument(LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(jsImportData.FunctionName))), 269: LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(jsImportData.ModuleName))), 310LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(1)))))))
Microsoft.Interop.LibraryImportGenerator (7)
Analyzers\ConvertToLibraryImportFixer.cs (2)
528SyntaxFactory.LiteralExpression(SyntaxKind.StringLiteralExpression, 540SyntaxFactory.LiteralExpression(SyntaxKind.StringLiteralExpression,
LibraryImportGenerator.cs (5)
131LiteralExpression(SyntaxKind.NumericLiteralExpression, 380AttributeArgument(LiteralExpression( 386LiteralExpression( 433AttributeArgument(LiteralExpression( 476return LiteralExpression(
Microsoft.Interop.LibraryImportGenerator.Downlevel (5)
DownlevelLibraryImportGenerator.cs (5)
121LiteralExpression(SyntaxKind.NumericLiteralExpression, 325AttributeArgument(LiteralExpression( 331LiteralExpression( 378AttributeArgument(LiteralExpression( 421return LiteralExpression(
Microsoft.Interop.SourceGeneration (18)
MarshalAsParser.cs (5)
50LiteralExpression(SyntaxKind.NumericLiteralExpression, 79LiteralExpression(SyntaxKind.NumericLiteralExpression, 89LiteralExpression(SyntaxKind.NumericLiteralExpression, 100LiteralExpression(SyntaxKind.NumericLiteralExpression, 108LiteralExpression(SyntaxKind.NumericLiteralExpression,
Marshalling\BoolMarshaller.cs (3)
70LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(_trueValue)), 71LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(_falseValue))))))); 90LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(comparand)))));
Marshalling\ElementsMarshalling.cs (2)
92return LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(size)); 621EqualsValueClause(LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(0)))))))
Marshalling\MarshallerHelpers.cs (3)
49Argument(LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(errorCode)))); 251LiteralExpression(SyntaxKind.DefaultLiteralExpression, Token(SyntaxKind.DefaultKeyword))); 260LiteralExpression(SyntaxKind.DefaultLiteralExpression, Token(SyntaxKind.DefaultKeyword)));
Marshalling\StatelessMarshallingStrategy.cs (1)
592LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(0))));
SignatureContext.cs (2)
78AttributeArgument(LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(generatorName))), 79AttributeArgument(LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(generatorVersion)))
Utils\SyntaxFactoryExtensions.cs (2)
97public static LiteralExpressionSyntax IntLiteral(int number) => LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(number)); 129LiteralExpression(
QuarantineTools.Tests (2)
ActiveIssueTests.cs (1)
431SyntaxFactory.LiteralExpression(SyntaxKind.StringLiteralExpression, SyntaxFactory.Literal(issueUrl)))));
QuarantineScriptTests.cs (1)
375SyntaxFactory.LiteralExpression(SyntaxKind.StringLiteralExpression, SyntaxFactory.Literal(issueUrl)))));
Roslyn.Diagnostics.CSharp.Analyzers (8)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\EnumMemberGenerator.cs (4)
133LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(numericLiteral.Token.Text, 1)), 134LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(shiftValue.ToString(), shiftValue))); 146return LiteralExpression(SyntaxKind.NumericLiteralExpression, 151return LiteralExpression(SyntaxKind.NumericLiteralExpression,
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\ExpressionGenerator.cs (3)
115return LiteralExpression( 122return LiteralExpression( 278var literal = LiteralExpression(
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpSyntaxGeneratorInternal.cs (1)
288return SyntaxFactory.LiteralExpression(