28 references to Create
Microsoft.CodeAnalysis (6)
CodeGen\SwitchStringJumpTableEmitter.cs (1)
146ConstantValue hashConstant = ConstantValue.Create(hashValue);
Compilation\Expression.cs (1)
18return ConstantValue.Create((uint)value);
ConstantValue.cs (1)
378case ConstantValueTypeDiscriminator.UInt32: return Create((uint)value);
EnumConstantHelper.cs (1)
86offsetValue = ConstantValue.Create((uint)(previous + offset));
MetadataReader\MetadataDecoder.cs (1)
1091return ConstantValue.Create(sigReader.ReadUInt32());
MetadataReader\PEModule.cs (1)
3737return ConstantValue.Create(reader.ReadUInt32());
Microsoft.CodeAnalysis.CSharp (9)
Binder\PatternExplainer.cs (1)
684if (remainingValues.Any(BinaryOperatorKind.GreaterThan, ConstantValue.Create(uint.MaxValue)))
Lowering\LocalRewriter\LocalRewriter_Literal.cs (4)
106arguments.Add(new BoundLiteral(syntax, ConstantValue.Create((uint)value), _compilation.GetSpecialType(SpecialType.System_UInt32))); 124arguments.Add(new BoundLiteral(syntax, ConstantValue.Create(low), _compilation.GetSpecialType(SpecialType.System_Int32))); 125arguments.Add(new BoundLiteral(syntax, ConstantValue.Create(mid), _compilation.GetSpecialType(SpecialType.System_Int32))); 126arguments.Add(new BoundLiteral(syntax, ConstantValue.Create(high), _compilation.GetSpecialType(SpecialType.System_Int32)));
Lowering\LocalRewriter\LocalRewriter_UnaryOperator.cs (2)
1243constantOne = ConstantValue.Create(1U); 1255constantOne = ConstantValue.Create(1U);
Lowering\SyntheticBoundNodeFactory.cs (1)
736return new BoundLiteral(Syntax, ConstantValue.Create(value), SpecialType(Microsoft.CodeAnalysis.SpecialType.System_UInt32)) { WasCompilerGenerated = true };
Utilities\ValueSetFactory.UIntTC.cs (1)
51public ConstantValue ToConstantValue(uint value) => ConstantValue.Create(value);
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (1)
Semantics\ConstantTests.cs (1)
4013uint32Const = ConstantValue.Create(uint.MaxValue),
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (8)
Compilation\GetSemanticInfoTests.cs (8)
929EnumOffset(ConstantValue.Create((uint)0), 1, EnumOverflowKind.NoOverflow, ConstantValue.Create((uint)1)); 930EnumOffset(ConstantValue.Create((uint)0), 2, EnumOverflowKind.NoOverflow, ConstantValue.Create((uint)2)); 931EnumOffset(ConstantValue.Create((uint)(uint.MaxValue - 3)), 3, EnumOverflowKind.NoOverflow, ConstantValue.Create((uint)uint.MaxValue)); 932EnumOffset(ConstantValue.Create((uint)(uint.MaxValue - 3)), 4, EnumOverflowKind.OverflowReport, ConstantValue.Bad); 933EnumOffset(ConstantValue.Create((uint)(uint.MaxValue - 3)), 5, EnumOverflowKind.OverflowIgnore, ConstantValue.Bad);
Microsoft.CodeAnalysis.ExpressionEvaluator.ExpressionCompiler (1)
PDB\PdbHelpers.cs (1)
96(SpecialType.System_UInt32, uint uintVal) => ConstantValue.Create(uintVal),
Microsoft.CodeAnalysis.UnitTests (3)
CorLibTypesTests.cs (3)
148Assert.True(ConstantValue.Create((uint)1).IsOne); 201var cv61 = ConstantValue.Create(uint.MinValue); 202var cv62 = ConstantValue.Create(uint.MinValue);