87 references to MinValue
dotnet-svcutil-lib (3)
FrameworkFork\Microsoft.Xml\Xml\schema\DatatypeImplementation.cs (1)
3444private static readonly FacetsChecker s_numeric10FacetsChecker = new Numeric10FacetsChecker(sbyte.MinValue, sbyte.MaxValue);
FrameworkFork\Microsoft.Xml\Xml\schema\XmlValueConverter.cs (1)
927if (value < (int)SByte.MinValue || value > (int)SByte.MaxValue)
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlReaderDelegator.cs (1)
460if (value < SByte.MinValue || value > SByte.MaxValue)
GenerateDocumentationAndConfigFiles (2)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeGeneration\LiteralSpecialValues.cs (2)
41{ sbyte.MinValue, nameof(sbyte.MinValue) },
ILCompiler.Compiler (1)
Compiler\TypePreinit.cs (1)
936ValueTypeValue.FromInt32((sbyte)(int)Math.Clamp(double.IsNaN(val) ? 0 : val, sbyte.MinValue, sbyte.MaxValue)));
Microsoft.AspNetCore.Components.Server (4)
src\aspnetcore\src\submodules\MessagePack-CSharp\src\MessagePack.UnityClient\Assets\Scripts\MessagePack\MessagePackWriter.cs (4)
314else if (value >= sbyte.MinValue) 416else if (value >= sbyte.MinValue) 535else if (value >= sbyte.MinValue) 1313>= sbyte.MinValue => 2,
Microsoft.AspNetCore.Server.Kestrel.Core (1)
src\aspnetcore\src\Shared\runtime\Http2\Hpack\IntegerEncoder.cs (1)
75private static byte MaskHigh(int n) => (byte)(sbyte.MinValue >> (n - 1));
Microsoft.CodeAnalysis (1)
ExtendedSpecialType.cs (1)
21Debug.Assert(value >= sbyte.MinValue && value <= sbyte.MaxValue);
Microsoft.CodeAnalysis.Analyzers (2)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeGeneration\LiteralSpecialValues.cs (2)
41{ sbyte.MinValue, nameof(sbyte.MinValue) },
Microsoft.CodeAnalysis.CodeStyle.Fixes (2)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeGeneration\LiteralSpecialValues.cs (2)
41{ sbyte.MinValue, nameof(sbyte.MinValue) },
Microsoft.CodeAnalysis.CSharp (5)
Binder\Binder_Conversions.cs (2)
4307case SpecialType.System_SByte: return (sbyte.MinValue - 1D) < value && value < (sbyte.MaxValue + 1D); 4337case SpecialType.System_SByte: return (sbyte.MinValue - 1M) < value && value < (sbyte.MaxValue + 1M);
Binder\Semantics\Conversions\ConversionsBase.cs (1)
1389return sbyte.MinValue <= value && value <= sbyte.MaxValue;
Utilities\ValueSetFactory.SByteTC.cs (2)
17sbyte INumericTC<sbyte>.MinValue => sbyte.MinValue; 50Debug.Assert(value != sbyte.MinValue);
Microsoft.CodeAnalysis.NetAnalyzers (2)
Microsoft.NetCore.Analyzers\Performance\ConstantExpectedAnalyzer.cs (2)
311return UnmanagedHelper<long>.TryCreate(parameterSymbol, attributeData, sbyte.MinValue, sbyte.MaxValue, out parameter); 363return UnmanagedHelper<long>.Validate(parameterSymbol, attributeData, sbyte.MinValue, sbyte.MaxValue, helper, out diagnostics);
Microsoft.CodeAnalysis.Workspaces (2)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeGeneration\LiteralSpecialValues.cs (2)
41{ sbyte.MinValue, nameof(sbyte.MinValue) },
Microsoft.Data.Analysis (3)
PrimitiveDataFrameColumnComputations.cs (3)
3705var ret = sbyte.MinValue; 3938var value = sbyte.MinValue; 3961var value = sbyte.MinValue;
Microsoft.ML.Core (1)
Data\DataKind.cs (1)
226return sbyte.MinValue;
Microsoft.ML.Core.Tests (2)
UnitTests\DataTypes.cs (2)
79sbyte minValue = sbyte.MinValue; 93src = (sbyte.MinValue - 1).ToString().AsMemory();
Microsoft.ML.Tests (8)
CollectionsDataViewTest.cs (1)
146fsByte = sbyte.MinValue + 1,
TextLoaderTests.cs (2)
35string.Format("{0},{1},{2},{3}", sbyte.MinValue, short.MinValue, int.MinValue, long.MinValue), 54sbyte[] sByteTargets = new sbyte[] { sbyte.MinValue, sbyte.MaxValue, default };
Transformers\ConvertTests.cs (5)
158AF = new sbyte[]{ sbyte.MinValue, sbyte.MaxValue}, 226AF = new sbyte[]{ sbyte.MinValue, sbyte.MaxValue}, 238ConvF = new float[] { sbyte.MinValue, sbyte.MaxValue }, 252var allInputTypesData = new[] { new { A = (sbyte)sbyte.MinValue, B = (byte)byte.MinValue, C = double.MaxValue, D = float.MinValue, E = "already a string", F = false } }; 264var expectedValuesData = new[] { new { A = (sbyte)sbyte.MinValue, B = (byte)byte.MinValue, C = double.MaxValue, D = float.MinValue, E = "already a string", F = false,
Microsoft.ML.Transforms (1)
Expression\IlGeneratorExtensions.cs (1)
278if (sbyte.MinValue <= arg && arg <= sbyte.MaxValue)
Microsoft.VisualBasic.Core (7)
Microsoft\VisualBasic\CompilerServices\Operators.vb (7)
1066If operand = SByte.MinValue Then 1067Return -CShort(SByte.MinValue) 2829If result > SByte.MaxValue OrElse result < SByte.MinValue Then 3297If result < SByte.MinValue OrElse result > SByte.MaxValue Then 3737If result > SByte.MaxValue OrElse result < SByte.MinValue Then 4980If left = SByte.MinValue AndAlso right = -1 Then 4981Return -CShort(SByte.MinValue)
Roslyn.Diagnostics.Analyzers (2)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeGeneration\LiteralSpecialValues.cs (2)
41{ sbyte.MinValue, nameof(sbyte.MinValue) },
System.Data.Common (1)
System\Data\Common\SByteStorage.cs (1)
118sbyte max = sbyte.MinValue;
System.Formats.Asn1 (1)
System\Formats\Asn1\AsnWriter.Integer.cs (1)
124if (value >= sbyte.MinValue)
System.Net.Http (1)
src\runtime\src\libraries\Common\src\System\Net\Http\aspnetcore\Http2\Hpack\IntegerEncoder.cs (1)
75private static byte MaskHigh(int n) => (byte)(sbyte.MinValue >> (n - 1));
System.Private.CoreLib (28)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Convert.cs (4)
572if (value < sbyte.MinValue || value > sbyte.MaxValue) ThrowSByteOverflowException(); 586if (value < sbyte.MinValue || value > sbyte.MaxValue) ThrowSByteOverflowException(); 600if (value < sbyte.MinValue || value > sbyte.MaxValue) ThrowSByteOverflowException(); 2089if (r < sbyte.MinValue || r > sbyte.MaxValue)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Decimal.cs (2)
1759(value <= sbyte.MinValue) ? sbyte.MinValue : (sbyte)value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Enum.cs (1)
109if ((long)uint64Value < sbyte.MinValue || (long)uint64Value > sbyte.MaxValue) return null;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\BFloat16.cs (2)
1841(value <= sbyte.MinValue) ? sbyte.MinValue : (sbyte)value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\NFloat.cs (2)
1656(value <= sbyte.MinValue) ? sbyte.MinValue : (sbyte)value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Scalar.cs (2)
428result = (result < 0) ? sbyte.MaxValue : sbyte.MinValue; 1918result = (result < 0) ? sbyte.MaxValue : sbyte.MinValue;
src\runtime\src\libraries\System.Private.CoreLib\src\System\SByte.cs (15)
552static sbyte IMinMaxValue<sbyte>.MinValue => MinValue; 936(actualValue <= MinValue) ? MinValue : (sbyte)actualValue; 943(actualValue <= MinValue) ? MinValue : (sbyte)actualValue; 950(actualValue <= MinValue) ? MinValue : (sbyte)actualValue; 957(actualValue <= MinValue) ? MinValue : (sbyte)actualValue; 964(actualValue <= MinValue) ? MinValue : (sbyte)actualValue; 971(actualValue <= MinValue) ? MinValue : (sbyte)actualValue; 1024(actualValue <= MinValue) ? MinValue : (sbyte)actualValue;
System.Private.DataContractSerialization (1)
System\Runtime\Serialization\XmlReaderDelegator.cs (1)
674if (value < sbyte.MinValue || value > sbyte.MaxValue)
System.Private.Xml (2)
System\Xml\Schema\DataTypeImplementation.cs (1)
3376private static readonly Numeric10FacetsChecker s_numeric10FacetsChecker = new Numeric10FacetsChecker(sbyte.MinValue, sbyte.MaxValue);
System\Xml\Schema\XmlValueConverter.cs (1)
842if (value < (int)sbyte.MinValue || value > (int)sbyte.MaxValue)
System.Runtime.Numerics (3)
System\Numerics\BigInteger.cs (3)
4891actualResult = IsNegative(value) ? sbyte.MinValue : sbyte.MaxValue; 4896(value._sign <= sbyte.MinValue) ? sbyte.MinValue : (sbyte)value._sign;
System.Text.Json (1)
System\Text\Json\Reader\Utf8JsonReader.TryGet.cs (1)
341/// is written in scientific notation) or, it represents a number less than <see cref="sbyte.MinValue"/> or greater