770 references to IsNaN
Aspire.Dashboard (1)
Components\Controls\Chart\ChartBase.cs (1)
470if (double.IsNaN(pointValue))
dotnet-svcutil-lib (6)
FrameworkFork\Microsoft.CodeDom\Microsoft\CSharpCodeProvider.cs (1)
2304if (double.IsNaN(d))
FrameworkFork\Microsoft.Xml\Xml\schema\DatatypeImplementation.cs (1)
3775if (double.IsInfinity(value) || double.IsNaN(value))
FrameworkFork\Microsoft.Xml\Xml\XPath\Internal\BooleanFunctions.cs (1)
54return number != 0 && !double.IsNaN(number);
FrameworkFork\Microsoft.Xml\Xml\XPath\Internal\StringFunctions.cs (2)
170if (Double.IsNaN(num) || str1.Length <= num) 177if (Double.IsNaN(num1))
FrameworkFork\System.Runtime.Serialization\System\Xml\ValueHandle.cs (1)
331if ((value >= Single.MinValue && value <= Single.MaxValue) || double.IsInfinity(value) || double.IsNaN(value))
GenerateDocumentationAndConfigFiles (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Metrics (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Metrics.Legacy (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.AspNetCore.Components (2)
BindConverter.cs (2)
1066if (double.IsInfinity(converted) || double.IsNaN(converted)) 1091if (double.IsInfinity(converted) || double.IsNaN(converted))
Microsoft.Build.Framework (1)
ArraySortHelper.cs (1)
1243if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.Cci.Extensions (1)
Writers\CSharp\CSDeclarationWriter.Attributes.cs (1)
277else if (double.IsNaN(val))
Microsoft.CodeAnalysis (3)
ConstantValueSpecialized.cs (2)
923if (double.IsNaN(value)) 961if (double.IsNaN(value))
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.Analyzers (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.AnalyzerUtilities (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.BannedApiAnalyzers (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.CodeStyle (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.Collections.Package (1)
Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.CSharp (6)
Lowering\LocalRewriter\LocalRewriter.DecisionDagRewriter.cs (1)
738double.IsNaN(value.DoubleValue);
Lowering\LocalRewriter\LocalRewriter.PatternLocalRewriter.cs (1)
407if (input.Type.SpecialType == SpecialType.System_Double && double.IsNaN(value.DoubleValue) ||
Utilities\ValueSetFactory.DoubleTC.cs (4)
33Debug.Assert(!double.IsNaN(value)); 69return left == right || double.IsNaN(left) && double.IsNaN(right); // for our purposes, NaNs are equal 91double.IsNaN(value) ? "NaN" :
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (1)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\ExpressionGenerator.cs (1)
176if (double.IsNaN(value))
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\ExpressionGenerator.cs (1)
176if (double.IsNaN(value))
Microsoft.CodeAnalysis.EditorFeatures (2)
IWpfDifferenceViewerExtensions.cs (1)
121=> !double.IsNaN(value) && !double.IsInfinity(value) && value > 0.0;
IWpfTextViewExtensions.cs (1)
44=> !double.IsNaN(value) && !double.IsInfinity(value);
Microsoft.CodeAnalysis.Extensions.Package (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.InteractiveHost (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.PerformanceSensitiveAnalyzers (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.PublicApiAnalyzers (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.ResxSourceGenerator (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.Threading.Package (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.UnitTests (1)
RealParserTests.cs (1)
383if (double.IsInfinity(d) || double.IsNaN(d)) return;
Microsoft.CodeAnalysis.VisualBasic (4)
Preprocessor\ExpressionEvaluator.vb (1)
1340Double.IsNaN(RightValue)
Semantics\CompileTimeCalculations.vb (2)
524If Double.IsNaN(value) Then 554If Double.IsNaN(value) Then
Semantics\Operators.vb (1)
1371Double.IsNaN(rightValue)
Microsoft.CodeAnalysis.VisualBasic.CodeStyle.Fixes (2)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\VisualBasic\CodeGeneration\ExpressionGenerator.vb (2)
279If Double.IsNaN(value) Then 304If Double.IsNaN(value) Then
Microsoft.CodeAnalysis.VisualBasic.Workspaces (2)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\VisualBasic\CodeGeneration\ExpressionGenerator.vb (2)
279If Double.IsNaN(value) Then 304If Double.IsNaN(value) Then
Microsoft.CodeAnalysis.Workspaces (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CodeAnalysis.Workspaces.MSBuild.BuildHost (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Microsoft.CSharp (1)
Microsoft\CSharp\RuntimeBinder\BinderHelper.cs (1)
72if (o.Value is double && double.IsNaN((double)o.Value))
Microsoft.Extensions.Diagnostics.ResourceMonitoring.Tests (4)
Linux\AcceptanceTest.cs (2)
248Assert.True(double.IsNaN(cpuFromGauge)); 332Assert.True(double.IsNaN(cpuFromGauge));
Windows\WindowsContainerSnapshotProviderTests.cs (1)
240Assert.True(double.IsNaN(metricCollector.LastMeasurement.Value));
Windows\WindowsSnapshotProviderTests.cs (1)
100Assert.True(double.IsNaN(metricCollector.LastMeasurement.Value));
Microsoft.Maui (18)
Layouts\Flex.cs (2)
433 if (Double.IsNaN(Width) || Double.IsNaN(Height))
Layouts\FlexLayoutManager.cs (4)
30 if (double.IsNaN(frame.X) 31 || double.IsNaN(frame.Y) 32 || double.IsNaN(frame.Width) 33 || double.IsNaN(frame.Height))
Layouts\GridLayoutManager.cs (4)
396 if (double.IsNaN(cell.MeasureHeight) || double.IsNaN(cell.MeasureWidth)) 673 if (double.IsNaN(cell.MeasureWidth)) 695 if (double.IsNaN(cell.MeasureHeight))
Primitives\Dimension.cs (2)
11 return !double.IsNaN(value); 21 return !double.IsNaN(value);
Primitives\Font.cs (1)
18 public bool IsDefault => Family == null && (Size <= 0 || double.IsNaN(Size)) && Slant == FontSlant.Default && Weight == FontWeight.Regular;
Primitives\GridLength.cs (1)
52 if (value < 0 || double.IsNaN(value))
Primitives\Thickness.cs (4)
34 public bool IsNaN => double.IsNaN(Left) && double.IsNaN(Top) && double.IsNaN(Right) && double.IsNaN(Bottom);
Microsoft.Maui.Controls (11)
FontExtensions.cs (1)
32 if (defaultSize.HasValue && (size <= 0 || double.IsNaN(size)))
LegacyLayouts\FlexLayout.cs (4)
424 if (double.IsNaN(frame.X) 425 || double.IsNaN(frame.Y) 426 || double.IsNaN(frame.Width) 427 || double.IsNaN(frame.Height))
Shapes\Shape.cs (2)
396 scaleX = double.IsNaN(scaleX) || double.IsInfinity(scaleX) ? 0 : scaleX; 397 scaleY = double.IsNaN(scaleY) || double.IsInfinity(scaleY) ? 0 : scaleY;
VisualElement\VisualElement.cs (4)
69 coerceValue: (bindable, value) => double.IsNaN((double)value) ? 0d : value); 75 coerceValue: (bindable, value) => double.IsNaN((double)value) ? 0d : value); 1178 if (heightRequest != -1 && !double.IsNaN(heightRequest)) 1185 if (widthRequest != -1 && !double.IsNaN(widthRequest))
Microsoft.Maui.Controls.DesignTools (2)
GridLengthDesignTypeConverter.cs (2)
30 return !(len < 0 || double.IsNaN(len)); 32 return !(len < 0 || double.IsNaN(len));
Microsoft.ML.AutoML (11)
AutoMLExperiment\AutoMLExperiment.cs (1)
108Contracts.Assert(!double.IsNaN(value) && value > 0, "value can't be nan or non-positive");
Experiment\MetricsAgents\BinaryMetricsAgent.cs (1)
53if (double.IsNaN(score))
Experiment\MetricsAgents\MultiMetricsAgent.cs (1)
47if (double.IsNaN(score))
Experiment\MetricsAgents\RankingMetricsAgent.cs (1)
53if (double.IsNaN(score))
Experiment\MetricsAgents\RegressionMetricsAgent.cs (1)
44if (double.IsNaN(score))
Experiment\Runners\CrossValRunner.cs (1)
71var newScores = scores.Where(r => !double.IsNaN(r));
Experiment\Runners\CrossValSummaryRunner.cs (3)
185var newResults = results.Where(r => !double.IsNaN(r)); 200if (double.IsNaN(average)) 216if (double.IsNaN(value))
Tuner\PipelineProposer.cs (1)
138var isSuccess = duration != 0 && !double.IsNaN(loss) && !double.IsInfinity(loss);
Tuner\SmacTuner.cs (1)
366if (!double.IsNaN(result.Loss) && !double.IsInfinity(result.Loss))
Microsoft.ML.Core (10)
Data\ProgressReporter.cs (2)
89if (Double.IsNaN(lim.GetValueOrDefault())) 539ProgressLim[index] = Double.IsNaN(lim) ? (Double?)null : lim;
Utilities\DoubleParser.cs (1)
104Contracts.Assert(res != Result.Empty || ((flags & OptionFlags.EmptyAsNaN) == 0 && value == 0) || Double.IsNaN(value));
Utilities\Stats.cs (3)
192if (double.IsNaN(logLam)) 362if (double.IsNaN(alpha)) 414if (double.IsNaN(h))
Utilities\SummaryStatistics.cs (1)
263if (double.IsNaN(b2))
Utilities\Utils.cs (2)
359Contracts.Assert(!Double.IsNaN(value)); 367Contracts.Assert(!Double.IsNaN(input[mid]));
Utilities\VBufferUtils.cs (1)
39if (Double.IsNaN(values[i]))
Microsoft.ML.Data (24)
Data\Conversion.cs (3)
767private bool IsNA(in R8 src) => R8.IsNaN(src); 772private bool HasNA(in VBuffer<R8> src) { var srcValues = src.GetValues(); for (int i = 0; i < srcValues.Length; i++) { if (R8.IsNaN(srcValues[i])) return true; } return false; } 925public void Convert(in R8 src, ref SB dst) { ClearDst(ref dst); if (R8.IsNaN(src)) dst.AppendFormat(CultureInfo.InvariantCulture, "{0}", "?"); else dst.AppendFormat(CultureInfo.InvariantCulture, "{0:G17}", src); }
Evaluators\BinaryClassifierEvaluator.cs (1)
465return Double.IsNaN(_logLoss) ? Double.NaN : (_numLogLossPositives + _numLogLossNegatives > 0)
Transforms\Hashing.cs (3)
570if (double.IsNaN(value)) 579if (double.IsNaN(value)) 591if (double.IsNaN(value))
Transforms\NormalizeColumnDbl.cs (15)
134Contracts.CheckDecode(!TFloat.IsNaN(scale)); 143Contracts.CheckDecode(!TFloat.IsNaN(offset)); 170Contracts.CheckDecode(!TFloat.IsNaN(scale)); 179Contracts.CheckDecode(!TFloat.IsNaN(offset)); 1396Contracts.Assert(!TFloat.IsNaN(min)); 1397Contracts.Assert(!TFloat.IsNaN(max)); 1421Contracts.Assert(!TFloat.IsNaN(min)); 1422Contracts.Assert(!TFloat.IsNaN(max)); 1445Contracts.Assert(!Double.IsNaN(mean)); 1462Contracts.Assert(!Double.IsNaN(mean)); 1497if (TFloat.IsNaN(input)) 1508if (TFloat.IsNaN(input)) 1891_values.RemoveAll(TFloat.IsNaN); 1967_values[i].RemoveAll(TFloat.IsNaN); 1990return !TFloat.IsNaN(colValue);
Transforms\NormalizeColumnSng.cs (2)
1608Contracts.Assert(!Double.IsNaN(mean)); 1625Contracts.Assert(!Double.IsNaN(mean));
Microsoft.ML.FastTree (7)
BinFile\BinFinder.cs (1)
75if (double.IsNaN(valueBuffer[0]))
Training\RegressionTreeNodeDocuments.cs (2)
129if (!double.IsNaN(_weightedOutput)) 163if (!double.IsNaN(_weightedOutput) && _nodeCount != int.MaxValue)
Training\TreeLearners\LeastSquaresRegressionTreeLearner.cs (3)
240if (Double.IsNaN(rootSplitInfo.Gain) || Double.IsNegativeInfinity(rootSplitInfo.Gain)) 1190if (double.IsNaN(myGain)) 1193if (double.IsNaN(otherGain))
TreeEnsemble\InternalRegressionTree.cs (1)
828if (double.IsNaN(x))
Microsoft.ML.IntegrationTests (2)
Common.cs (2)
216if (!double.IsNaN(metrics.NormalizedMutualInformation)) 352Assert.False(double.IsNaN(array[i]));
Microsoft.ML.Mkl.Components (7)
OlsLinearRegression.cs (7)
490ch.Assert(!Double.IsNaN(rSquaredAdjusted)); 779Contracts.Assert(!Double.IsNaN(rSquaredAdjusted) || standardErrors == null); 783Contracts.Assert(Double.IsNaN(rSquaredAdjusted) || (0 <= rSquaredAdjusted && rSquaredAdjusted <= 1)); 824if (!Double.IsNaN(RSquaredAdjusted)) 827Host.CheckDecode(!Double.IsNaN(RSquaredAdjusted) || !hasStats); 864Contracts.Assert(Double.IsNaN(RSquaredAdjusted) || (0 <= RSquaredAdjusted && RSquaredAdjusted <= 1)); 866Contracts.Assert(!Double.IsNaN(RSquaredAdjusted) || !HasStatistics);
Microsoft.ML.Predictor.Tests (2)
CompareBaselines.cs (2)
275if (double.IsNaN(d1) && double.IsNaN(d2))
Microsoft.ML.TestFramework (3)
BaseTestBaseline.cs (3)
632if (double.IsNaN(expected) && double.IsNaN(actual)) 675if ((value == 0) || double.IsInfinity(value) || double.IsNaN(value))
Microsoft.ML.TimeSeries (8)
PolynomialUtils.cs (2)
293if (Double.IsNaN(roots[i].Real) || Double.IsNaN(roots[i].Imaginary))
RootCauseAnalyzer.cs (5)
264if (Double.IsNaN(gain)) 311if (Double.IsNaN(entropy)) 498bool isRatioNan = Double.IsNaN(valueRatioMap[best]); 618if (Double.IsNaN(a)) 720private double Log2(double val) => Double.IsNaN(val) ? 0 : Math.Log(val) / Math.Log(2);
SequentialAnomalyDetectionTransformBase.cs (1)
536if (Double.IsNaN(result.Values[1]))
Microsoft.ML.Transforms (19)
Dracula\CountTableTransformer.cs (1)
271if (double.IsNaN(src))
Expression\BuiltinFunctions.cs (2)
41return R8.IsNaN((R8)v); 841return R8.IsNaN(a);
Expression\LambdaBinder.cs (13)
663if (!R8.IsNaN(v)) 669if (R8.IsNaN(v)) 675if (R8.IsNaN(v)) 683if (R8.IsNaN(v)) 695if (R8.IsNaN(v)) 699if (R8.IsNaN(v)) 705if (R8.IsNaN(v)) 713if (R8.IsNaN(v)) 797return !R8.IsNaN(v1) ? v1 : v2; 1784(a,b) => { var x = Cast<R8>(a); var y = Cast<R8>(b); if (x == y) return true; if (!R8.IsNaN(x) && !R8.IsNaN(y)) return false; return null; }, 1798(a,b) => { var x = Cast<R8>(a); var y = Cast<R8>(b); if (x == y) return false; if (!R8.IsNaN(x) && !R8.IsNaN(y)) return true; return null; },
Expression\Printer.cs (1)
264if (R8.IsNaN(x))
MutualInformationFeatureSelection.cs (2)
848if (!Double.IsNaN(val)) 857dst = Double.IsNaN(src) ? offset : offset + 1 + bounds.FindIndexSorted(src);
Microsoft.VisualBasic.Core (1)
Microsoft\VisualBasic\Strings.vb (1)
1180If System.Double.IsNaN(dbl) OrElse System.Double.IsInfinity(dbl) Then
Microsoft.VisualStudio.LanguageServices (2)
PreviewPane\PreviewPane.xaml.cs (2)
297double.IsNaN(previewElement.Width) ? DefaultWidth : previewElement.Width, 331=> size > 0 && !double.IsNaN(size) && !double.IsInfinity(size);
PresentationCore (60)
MS\Internal\AnimatedTypeHelpers.cs (1)
847|| double.IsNaN(value);
MS\Internal\FontFace\CompositeFontParser.cs (3)
23if (double.IsNaN(value)) 39if (double.IsNaN(value)) 55if (double.IsNaN(value))
MS\Internal\Ink\EllipticalNodeOperations.cs (4)
643System.Diagnostics.Debug.Assert(!double.IsNaN(findex)); 654System.Diagnostics.Debug.Assert(!double.IsNaN(findex)); 670System.Diagnostics.Debug.Assert(!double.IsNaN(findex)); 682System.Diagnostics.Debug.Assert(!double.IsNaN(findex));
MS\Internal\Ink\InkSerializedFormat\CustomAttributeSerializer.cs (2)
859if ( Double.IsNaN(dVal) || dVal < DrawingAttributes.MinHeight || dVal > DrawingAttributes.MaxHeight) 866if (Double.IsNaN(dVal) || dVal < DrawingAttributes.MinWidth || dVal > DrawingAttributes.MaxWidth)
MS\Internal\Ink\StrokeFIndices.cs (4)
167private bool IsValid { get { return !double.IsNaN(_beginFIndex) && !double.IsNaN(_endFIndex) && _beginFIndex < _endFIndex; } } 179System.Diagnostics.Debug.Assert(!double.IsNaN(_beginFIndex) && !double.IsNaN(_endFIndex) && DoubleUtil.LessThan(_beginFIndex, _endFIndex));
MS\Internal\Ink\StrokeNode.cs (2)
897System.Diagnostics.Debug.Assert(!double.IsNaN(cutAt.BeginFIndex) && !double.IsNaN(cutAt.EndFIndex));
MS\Internal\Ink\StylusShape.cs (3)
41if (Double.IsNaN(width) || Double.IsInfinity(width) || width < DrawingAttributes.MinWidth || width > DrawingAttributes.MaxWidth) 46if (Double.IsNaN(height) || Double.IsInfinity(height) || height < DrawingAttributes.MinHeight || height > DrawingAttributes.MaxHeight) 51if (Double.IsNaN(rotation) || Double.IsInfinity(rotation))
System\Windows\Ink\DrawingAttributes.cs (2)
159if (double.IsNaN(value) || value < MinHeight || value > MaxHeight) 186if (double.IsNaN(value) || value < MinWidth || value > MaxWidth)
System\Windows\Ink\Stroke.cs (8)
1023return (!double.IsNaN(findex.BeginFIndex) && !double.IsNaN(findex.EndFIndex) && findex.BeginFIndex < findex.EndFIndex); 1107if (Double.IsNaN(matrix.M11) || 1108Double.IsNaN(matrix.M12) || 1109Double.IsNaN(matrix.M21) || 1110Double.IsNaN(matrix.M22) || 1111Double.IsNaN(matrix.OffsetX) || 1112Double.IsNaN(matrix.OffsetY))
System\Windows\Ink\Stroke2.cs (1)
193if (Double.IsNaN(diameter) || diameter < DrawingAttributes.MinWidth || diameter > DrawingAttributes.MaxWidth)
System\Windows\Ink\StrokeCollection2.cs (1)
64if (Double.IsNaN(diameter) || diameter < DrawingAttributes.MinWidth || diameter > DrawingAttributes.MaxWidth)
System\Windows\Input\InertiaExpansionBehavior.cs (1)
52if (Double.IsInfinity(value) || Double.IsNaN(value))
System\Windows\Input\InertiaRotationBehavior.cs (2)
52if (Double.IsInfinity(value) || Double.IsNaN(value)) 72if (Double.IsInfinity(value) || Double.IsNaN(value))
System\Windows\Input\InertiaTranslationBehavior.cs (2)
52if (Double.IsInfinity(value) || Double.IsNaN(value)) 72if (Double.IsInfinity(value) || Double.IsNaN(value))
System\Windows\Input\Stylus\Common\StylusPoint.cs (4)
70if (Double.IsNaN(x)) 74if (Double.IsNaN(y)) 164if (Double.IsNaN(value)) 184if (Double.IsNaN(value))
System\Windows\Media\Animation\ClockController.cs (1)
277if (value < 0 || value > double.MaxValue || double.IsNaN(value))
System\Windows\Media\Animation\RepeatBehavior.cs (1)
38if (double.IsInfinity(count) || double.IsNaN(count) || count < 0.0)
System\Windows\Media\Animation\Timeline.cs (2)
210if (newValue < 0 || newValue > 1 || double.IsNaN(newValue)) 599if (newValue <= 0 || newValue > double.MaxValue || double.IsNaN(newValue))
System\Windows\Media\FormattedText.cs (3)
1312if (double.IsNaN(value)) 1413if (_metrics == null || double.IsNaN(_metrics.Extent)) 1678if (_metrics != null && !double.IsNaN(_metrics.Extent))
System\Windows\Media\GlyphRun.cs (2)
1743if (double.IsNaN(_baseVectorX)) 1747if (double.IsNaN(_baseVectorY))
System\Windows\Media3D\MeshGeometry3D.cs (2)
407Debug.Assert(!double.IsInfinity(pz / pw) && !double.IsNaN(pz / pw), 493Debug.Assert(!double.IsInfinity(pz / pw) && !double.IsNaN(pz / pw),
System\Windows\UIElement.cs (9)
578if (double.IsNaN(availableSize.Width) || double.IsNaN(availableSize.Height)) 675if (double.IsNaN(desiredSize.Width) || double.IsNaN(desiredSize.Height)) 794|| double.IsNaN(finalRect.Width) 795|| double.IsNaN(finalRect.Height) 1088if (double.IsNaN(newValue) || 1392return ( (!double.IsNaN(v.X) && !Double.IsPositiveInfinity(v.X) && !Double.IsNegativeInfinity(v.X)) 1393&& (!double.IsNaN(v.Y) && !Double.IsPositiveInfinity(v.Y) && !Double.IsNegativeInfinity(v.Y)));
PresentationFramework (291)
MS\Internal\AnimatedTypeHelpers.cs (1)
165|| double.IsNaN(value);
MS\Internal\Annotations\Anchoring\FixedTextSelectionProcessor.cs (6)
208if (!double.IsNaN(fp.Segments[i].Start.X)) 217if (!double.IsNaN(fp.Segments[i].End.X)) 315if (double.IsNaN(start.X) || double.IsNaN(start.Y)) 334if (double.IsNaN(end.X) || double.IsNaN(end.Y))
MS\Internal\Controls\InkCanvasInnerCanvas.cs (6)
91if (!double.IsNaN(left)) 101if (!double.IsNaN(top)) 142if (!double.IsNaN(left)) 150if (!double.IsNaN(right)) 157if (!double.IsNaN(top)) 165if (!double.IsNaN(bottom))
MS\Internal\Controls\StickyNote\StickyNoteAnnotations.cs (4)
1011if ((double.IsNaN(anchor.X)) || (double.IsNaN(anchor.Y))) 1564if (!(double.IsNaN(anchor.X)) && !(double.IsNaN(anchor.Y)) && PositionTransform != null)
MS\Internal\Documents\DocumentGrid.cs (4)
592if (Double.IsNaN(offset)) 635if (Double.IsNaN(offset)) 2139if (Double.IsNaN(offset)) 2159if (Double.IsNaN(offset))
MS\Internal\Documents\FlowDocumentFormatter.cs (5)
193if (double.IsNaN(pageSize.Width)) 224if (double.IsNaN(pageMargin.Left)) 228if (double.IsNaN(pageMargin.Top)) 232if (double.IsNaN(pageMargin.Right)) 236if (double.IsNaN(pageMargin.Bottom))
MS\Internal\Documents\FlowDocumentPaginator.cs (4)
520if (double.IsNaN(newPageSize.Width)) 524if (double.IsNaN(newPageSize.Height)) 839if (double.IsNaN(pageSize.Width)) 853if (double.IsNaN(pageSize.Height))
MS\Internal\Documents\TextBoxView.cs (1)
732else if (double.IsNaN(suggestedX))
MS\Internal\Documents\TextDocumentView.cs (6)
2483if (!double.IsNaN(suggestedX)) 2503if (!double.IsNaN(suggestedX)) 2515if (!double.IsNaN(suggestedX)) 2962if (!double.IsNaN(suggestedX)) 2977if (!double.IsNaN(suggestedX)) 2989if (!double.IsNaN(suggestedX))
MS\Internal\Documents\TextParagraphView.cs (1)
171else if (!double.IsNaN(suggestedX))
MS\Internal\Helper.cs (1)
551return !(Double.IsInfinity(value) || Double.IsNaN(value));
MS\Internal\Ink\InkCanvasSelection.cs (8)
429if ( !double.IsNaN(left) ) 433else if ( !double.IsNaN(right) ) 438if ( !double.IsNaN(top) ) 442else if ( !double.IsNaN(bottom) ) 449if ( !double.IsNaN(left) ) 453else if ( !double.IsNaN(right) ) 465if ( !double.IsNaN(top) ) 469else if ( !double.IsNaN(bottom) )
MS\Internal\PtsHost\ColumnPropertiesGroup.cs (4)
38internal double ColumnWidth { get { Debug.Assert(!double.IsNaN(_columnWidth)); return _columnWidth; } } 59Invariant.Assert(!double.IsNaN(_columnGap)); 80internal bool ColumnWidthAuto { get { return double.IsNaN(_columnWidth); } } 89return double.IsNaN(_columnGap);
MS\Internal\PtsHost\FigureHelper.cs (2)
116Invariant.Assert(!double.IsNaN(value)); 167if(!double.IsNaN(value))
MS\Internal\PtsHost\FloaterParagraph.cs (3)
265if(fsbbox.fsrc.du < subpageWidth && Double.IsNaN(specifiedWidth) && HorizontalAlignment != HorizontalAlignment.Stretch) 443if(fsbbox.fsrc.du < subpageWidth && Double.IsNaN(specifiedWidth) && HorizontalAlignment != HorizontalAlignment.Stretch) 648if (!Double.IsNaN(specifiedWidth))
MS\Internal\PtsHost\Line.cs (1)
344Debug.Assert(!double.IsNaN(_trackWidth), "Track width must be set for measure pass.");
MS\Internal\PtsHost\MbpInfo.cs (16)
137Double.IsNaN(mbp.Margin.Left) ? defaultMargin.Left : mbp.Margin.Left, 138Double.IsNaN(mbp.Margin.Top) ? defaultMargin.Top : mbp.Margin.Top, 139Double.IsNaN(mbp.Margin.Right) ? defaultMargin.Right : mbp.Margin.Right, 140Double.IsNaN(mbp.Margin.Bottom) ? defaultMargin.Bottom : mbp.Margin.Bottom); 162Double.IsNaN(mbp.Padding.Left) ? defaultPadding.Left : mbp.Padding.Left, 163Double.IsNaN(mbp.Padding.Top) ? defaultPadding.Top : mbp.Padding.Top, 164Double.IsNaN(mbp.Padding.Right) ? defaultPadding.Right : mbp.Padding.Right, 165Double.IsNaN(mbp.Padding.Bottom) ? defaultPadding.Bottom : mbp.Padding.Bottom); 336Double.IsNaN(_padding.Left) || 337Double.IsNaN(_padding.Right) || 338Double.IsNaN(_padding.Top) || 339Double.IsNaN(_padding.Bottom)); 351Double.IsNaN(_margin.Left) || 352Double.IsNaN(_margin.Right) || 353Double.IsNaN(_margin.Top) || 354Double.IsNaN(_margin.Bottom));
MS\Internal\PtsHost\RunClient.cs (2)
58if(!double.IsNaN(baselineOffsetValue)) 81if (!sideways && !double.IsNaN(baselineOffsetValue))
MS\Internal\Text\DynamicPropertyReader.cs (1)
204if (double.IsNaN(lineHeight))
MS\Internal\Text\InlineObject.cs (2)
53if(!double.IsNaN(baselineOffsetValue)) 75if (!sideways && !double.IsNaN(baselineOffsetValue))
MS\Internal\Text\LineProperties.cs (3)
54if (LineStackingStrategy == LineStackingStrategy.BlockLineHeight && !Double.IsNaN(_lineHeight)) 162if (!double.IsNaN(_lineHeight)) 204if (!double.IsNaN(_lineHeight))
MS\Internal\Text\MarkerProperties.cs (1)
32if (Double.IsNaN(_offset))
System\Windows\Automation\Peers\GridSplitterAutomationPeer.cs (2)
42if (double.IsInfinity(x) || double.IsNaN(x)) 45if (double.IsInfinity(y) || double.IsNaN(y))
System\Windows\Controls\Canvas.cs (4)
295if(!double.IsNaN(left)) 303if(!double.IsNaN(right)) 310if(!double.IsNaN(top)) 318if(!double.IsNaN(bottom))
System\Windows\Controls\DataGrid.cs (5)
205return !(value < 0d || double.IsNaN(value) || Double.IsPositiveInfinity(value)); 214return !(value < 0d || double.IsNaN(value)); 1255if (!double.IsNaN(newValue)) 1274if (double.IsNaN(RowHeaderWidth)) 8471else if (!Double.IsNaN(RowHeaderWidth))
System\Windows\Controls\DataGridCellsPanel.cs (5)
143!double.IsNaN(width.DisplayValue) && 572if (!double.IsNaN(width.DisplayValue)) 1464if (double.IsNaN(childWidth)) 1890if (double.IsNaN(childMeasureWidth)) 2011if (!double.IsNaN(rowPresenterAvailableSize.Width) && !Double.IsInfinity(rowPresenterAvailableSize.Width))
System\Windows\Controls\DataGridColumn.cs (9)
367if (double.IsNaN(memberValue)) 398newDisplayValue = (double.IsNaN(newDisplayValue) ? newDisplayValue : DataGridHelper.CoerceToMinMax(newDisplayValue, column.MinWidth, column.MaxWidth)); 399if (double.IsNaN(newDisplayValue) || DoubleUtil.AreClose(newDisplayValue, width.DisplayValue)) 454return !(value < 0d || double.IsNaN(value) || Double.IsPositiveInfinity(value)); 463return !(value < 0d || double.IsNaN(value)); 514if (!double.IsNaN(width.DisplayValue)) 552if (double.IsNaN(width.DesiredValue) || 555if (double.IsNaN(width.DisplayValue)) 572if (double.IsNaN(width.DisplayValue))
System\Windows\Controls\DataGridColumnCollection.cs (4)
883if (double.IsNaN(nonStarSpace)) 897!double.IsNaN(availableStarSpace) && !Double.IsNegativeInfinity(availableStarSpace), 1083if (column.IsVisible && !double.IsNaN(width.DisplayValue)) 1186double displayValue = DataGridHelper.CoerceToMinMax(double.IsNaN(width.DesiredValue) ? minWidth : width.DesiredValue, minWidth, column.MaxWidth);
System\Windows\Controls\DataGridColumnDropSeparator.cs (2)
38if (double.IsNaN(width)) 50if (separator._referenceHeader != null && double.IsNaN(height))
System\Windows\Controls\DataGridColumnFloatingHeader.cs (6)
41if (header._visualBrushCanvas != null && !double.IsNaN(width)) 56if (header._referenceHeader != null && double.IsNaN(width)) 68if (header._visualBrushCanvas != null && !double.IsNaN(height)) 83if (header._referenceHeader != null && double.IsNaN(height)) 125if (double.IsNaN(width)) 135if (double.IsNaN(height))
System\Windows\Controls\DataGridHelper.cs (1)
268if (double.IsNaN(width.DesiredValue) ||
System\Windows\Controls\DataGridLength.cs (9)
75if (double.IsNaN(value) || Double.IsInfinity(value)) 129&& ((gl1.DesiredValue == gl2.DesiredValue) || (double.IsNaN(gl1.DesiredValue) && double.IsNaN(gl2.DesiredValue))) 130&& ((gl1.DisplayValue == gl2.DisplayValue) || (double.IsNaN(gl1.DisplayValue) && double.IsNaN(gl2.DisplayValue))); 144|| ((gl1.DesiredValue != gl2.DesiredValue) && !(double.IsNaN(gl1.DesiredValue) && double.IsNaN(gl2.DesiredValue))) 145|| ((gl1.DisplayValue != gl2.DisplayValue) && !(double.IsNaN(gl1.DisplayValue) && double.IsNaN(gl2.DisplayValue)));
System\Windows\Controls\DataGridLengthConverter.cs (1)
83if (double.IsNaN(doubleValue))
System\Windows\Controls\DefinitionBase.cs (2)
206return (!double.IsNaN(v) && v >= 0.0d && !Double.IsPositiveInfinity(v)); 235return (!double.IsNaN(v) && v >= 0.0d);
System\Windows\Controls\DocumentViewer.cs (1)
2278if ((double.IsNaN(checkValue)) ||
System\Windows\Controls\FlowDocumentReader.cs (1)
1793return (!Double.IsNaN(value) && !Double.IsInfinity(value) && DoubleUtil.GreaterThanZero(value));
System\Windows\Controls\FlowDocumentScrollViewer.cs (1)
1671return (!Double.IsNaN(value) && !Double.IsInfinity(value) && DoubleUtil.GreaterThanZero(value));
System\Windows\Controls\Grid.cs (2)
1625&& !double.IsNaN(totalRemainingSize) 1628&& !double.IsNaN(sizeToDistribute)
System\Windows\Controls\GridViewColumn.cs (4)
42_state = Double.IsNaN(Width) ? ColumnMeasureState.Init : ColumnMeasureState.SpecificWidth; 404c.State = Double.IsNaN(newWidth) ? ColumnMeasureState.Init : ColumnMeasureState.SpecificWidth; 422if (Double.IsNaN(value) || Double.IsInfinity(value) || value < 0.0) 529_state = Double.IsNaN(Width) ? ColumnMeasureState.Init : ColumnMeasureState.SpecificWidth;
System\Windows\Controls\GridViewColumnHeader.cs (1)
705if (Double.IsNaN(Column.Width))
System\Windows\Controls\InkCanvas.cs (2)
1837if (double.IsNaN(point.X) || 1838double.IsNaN(point.Y) ||
System\Windows\Controls\Primitives\DataGridColumnHeadersPresenter.cs (1)
900if (double.IsNaN(columnEstimatedWidth))
System\Windows\Controls\Primitives\DataGridRowHeader.cs (1)
190if (double.IsNaN(dataGridOwner.RowHeaderWidth) &&
System\Windows\Controls\Primitives\Popup.cs (4)
2155if (!IsTransparent || double.IsNaN(horizontalAxis.Y) || Math.Abs(horizontalAxis.Y) < Tolerance) 2190if (!IsTransparent || double.IsNaN(verticalAxis.X) || Math.Abs(verticalAxis.X) < Tolerance) 2256if (!IsTransparent || double.IsNaN(verticalAxis.X) || Math.Abs(verticalAxis.X) < Tolerance) 2278if (!IsTransparent || double.IsNaN(horizontalAxis.X) || Math.Abs(horizontalAxis.Y) < Tolerance)
System\Windows\Controls\Primitives\RangeBase.cs (1)
252return !(double.IsNaN(d) || double.IsInfinity(d));
System\Windows\Controls\Primitives\ScrollContentPresenter.cs (1)
677if (double.IsNaN(offset))
System\Windows\Controls\Primitives\TabPanel.cs (1)
131if (double.IsInfinity(contentSize.Width) || double.IsNaN(contentSize.Width) || maxRowWidth < constraint.Width)
System\Windows\Controls\Primitives\TextBoxBase.cs (2)
277if (Double.IsNaN(offset)) 294if (Double.IsNaN(offset))
System\Windows\Controls\Primitives\ToolBarOverflowPanel.cs (2)
39return (double.IsNaN(v)) || (DoubleUtil.GreaterThanOrClose(v, 0d) && !Double.IsPositiveInfinity(v)); 53_wrapWidth = double.IsNaN(WrapWidth) ? constraint.Width : WrapWidth;
System\Windows\Controls\Primitives\Track.cs (4)
318return d >= 0.0 || double.IsNaN(d); 419if (!double.IsNaN(ViewportSize)) 438else if (componentLength > trackLength || double.IsNaN(componentLength)) 466if (double.IsNaN(ViewportSize))
System\Windows\Controls\SinglePageViewer.cs (1)
1448return (!Double.IsNaN(value) && !Double.IsInfinity(value) && DoubleUtil.GreaterThanZero(value));
System\Windows\Controls\Slider.cs (1)
1414return !(double.IsNaN(d) || double.IsInfinity(d));
System\Windows\Controls\TextBlock.cs (2)
4042if(double.IsNaN((double) value)) 4058return (localBaseline != DependencyProperty.UnsetValue) && !double.IsNaN((double) localBaseline);
System\Windows\Controls\TextRangeAdaptor.cs (1)
1368return (double.IsNaN(length) ? 0d : (length * 72.0 / 96.0));
System\Windows\Controls\VirtualizationCacheLength.cs (2)
66if (double.IsNaN(cacheBeforeViewport)) 71if (double.IsNaN(cacheAfterViewport))
System\Windows\Controls\WrapPanel.cs (5)
68return (double.IsNaN(v)) || (v >= 0.0d && !Double.IsPositiveInfinity(v)); 217bool itemWidthSet = !double.IsNaN(itemWidth); 218bool itemHeightSet = !double.IsNaN(itemHeight); 280bool itemWidthSet = !double.IsNaN(itemWidth); 281bool itemHeightSet = !double.IsNaN(itemHeight);
System\Windows\CornerRadius.cs (12)
125return ( (cr1._topLeft == cr2._topLeft || (double.IsNaN(cr1._topLeft) && double.IsNaN(cr2._topLeft))) 126&& (cr1._topRight == cr2._topRight || (double.IsNaN(cr1._topRight) && double.IsNaN(cr2._topRight))) 127&& (cr1._bottomRight == cr2._bottomRight || (double.IsNaN(cr1._bottomRight) && double.IsNaN(cr2._bottomRight))) 128&& (cr1._bottomLeft == cr2._bottomLeft || (double.IsNaN(cr1._bottomLeft) && double.IsNaN(cr2._bottomLeft))) 205if (double.IsNaN(_topLeft) || double.IsNaN(_topRight) || double.IsNaN(_bottomLeft) || double.IsNaN(_bottomRight))
System\Windows\Documents\Block.cs (9)
488if (Double.IsNaN(lineHeight)) 533if (Double.IsNaN(t.Left) || Double.IsNaN(t.Right) || Double.IsNaN(t.Top) || Double.IsNaN(t.Bottom)) 538if (!Double.IsNaN(t.Left) && (t.Left < 0 || t.Left > maxThickness)) 542if (!Double.IsNaN(t.Right) && (t.Right < 0 || t.Right > maxThickness)) 546if (!Double.IsNaN(t.Top) && (t.Top < 0 || t.Top > maxThickness)) 550if (!Double.IsNaN(t.Bottom) && (t.Bottom < 0 || t.Bottom > maxThickness))
System\windows\Documents\CaretElement.cs (4)
319if (positionChanged || !double.IsNaN(scrollToOriginPosition)) 338if (!double.IsNaN(scrollToOriginPosition) && scrollToOriginPosition > 0) 367if (!double.IsNaN(scrollToOriginPosition)) 1106if (double.IsNaN(value))
System\Windows\Documents\Figure.cs (1)
299if (Double.IsNaN(offset))
System\Windows\Documents\FixedDocument.cs (2)
704if (double.IsNaN(width)) 711if (double.IsNaN(height))
System\Windows\Documents\FixedPage.cs (4)
776if(!double.IsNaN(left)) 784if(!double.IsNaN(right)) 791if(!double.IsNaN(top)) 799if(!double.IsNaN(bottom))
System\Windows\Documents\FixedTextView.cs (1)
377if (double.IsNaN(suggestedX))
System\Windows\Documents\Floater.cs (1)
132if (Double.IsNaN(width))
System\Windows\Documents\FlowDocument.cs (11)
1001if (double.IsNaN(pageMargin.Left)) 1005if (double.IsNaN(pageMargin.Top)) 1009if (double.IsNaN(pageMargin.Right)) 1013if (double.IsNaN(pageMargin.Bottom)) 1325if (!double.IsNaN(width)) 1351if (!double.IsNaN(height)) 1517if (Double.IsNaN(value)) 1532if (Double.IsNaN(value)) 1547if (Double.IsNaN(value)) 1568if (Double.IsNaN(ruleWidth) || ruleWidth < 0 || ruleWidth > maxRuleWidth) 1579if (Double.IsNaN(gap))
System\Windows\Documents\Glyphs.cs (2)
170bool haveOriginX = !double.IsNaN(OriginX); 171bool haveOriginY = !double.IsNaN(OriginY);
System\Windows\Documents\ImmComposition.cs (1)
1811if (Double.IsNaN(value))
System\Windows\Documents\List.cs (1)
329if (Double.IsNaN(value))
System\Windows\Documents\Paragraph.cs (6)
235return (Double.IsNaN(margin.Left) && Double.IsNaN(margin.Right) && Double.IsNaN(margin.Top) && Double.IsNaN(margin.Bottom)); 240return (Double.IsNaN(lineHeight)); 304if (Double.IsNaN(indent))
System\Windows\Documents\Table.cs (1)
367if (Double.IsNaN(spacing))
System\windows\Documents\TextEditorSelection.cs (1)
2231if (Double.IsNaN(This._suggestedX))
System\Windows\Documents\TextElement.cs (1)
1589if (Double.IsNaN(fontSize))
System\Windows\Documents\TextRange.cs (2)
1036if (double.IsNaN(image.Height)) 1050if (double.IsNaN(image.Width))
System\Windows\Documents\TextRangeEdit.cs (2)
1133if (double.IsNaN(newValue)) 1138if (double.IsNaN(currentValue))
System\Windows\Documents\ZoomPercentageConverter.cs (1)
80if ((double.IsNaN(percent)) || (double.IsInfinity(percent)))
System\Windows\FigureLength.cs (1)
101if (double.IsNaN(value))
System\Windows\FrameworkElement.cs (8)
3440return (double.IsNaN(v)) || (v >= 0.0d && !Double.IsPositiveInfinity(v)); 3446return (!double.IsNaN(v) && v >= 0.0d && !Double.IsPositiveInfinity(v)); 3452return (!double.IsNaN(v) && v >= 0.0d); 4044double height = (double.IsNaN(l) ? Double.PositiveInfinity : l); 4047height = (double.IsNaN(l) ? 0 : l); 4054double width = (double.IsNaN(l) ? Double.PositiveInfinity : l); 4057width = (double.IsNaN(l) ? 0 : l); 4269if( !Double.IsNaN(expandFactor)
System\Windows\GridLength.cs (1)
90if (double.IsNaN(value))
System\Windows\GridLengthConverter.cs (1)
123if (double.IsNaN(value))
System\Windows\Input\KeyboardNavigation.cs (1)
2850if (double.IsNaN(score))
System\Windows\LengthConverter.cs (2)
145if(double.IsNaN(l)) 175if (double.IsNaN(value))
System\Windows\Shapes\Shape.cs (5)
442return (double.IsNaN(size.Width) || 443double.IsNaN(size.Height) || 452return (Stroke == null) || double.IsNaN(strokeThickness) || DoubleUtil.IsZero(strokeThickness); 523return !(Double.IsInfinity(d) || double.IsNaN(d) || d < 0.0); 528return !(Double.IsInfinity(d) || double.IsNaN(d));
System\Windows\Shell\TaskbarItemInfo.cs (1)
99if (double.IsNaN(progressValue))
System\Windows\Standard\DoubleUtil.cs (1)
112return !double.IsNaN(value) && !double.IsInfinity(value);
System\Windows\Standard\Utilities.cs (1)
298if (double.IsNaN(d) || double.IsInfinity(d) || d < 0)
System\Windows\Thickness.cs (12)
157if(double.IsNaN(Left) || double.IsNaN(Right) || double.IsNaN(Top) || double.IsNaN(Bottom)) 228return ( (t1._Left == t2._Left || (double.IsNaN(t1._Left) && double.IsNaN(t2._Left))) 229&& (t1._Top == t2._Top || (double.IsNaN(t1._Top) && double.IsNaN(t2._Top))) 230&& (t1._Right == t2._Right || (double.IsNaN(t1._Right) && double.IsNaN(t2._Right))) 231&& (t1._Bottom == t2._Bottom || (double.IsNaN(t1._Bottom) && double.IsNaN(t2._Bottom)))
System\Windows\Window.cs (21)
2710if ((!double.IsNaN(requestedWidth)) && (!DoubleUtil.AreClose(sizeDeviceUnits.Width, requestedSizeDeviceUnits.X))) 2727if (!double.IsNaN(requestedHeight) && (!DoubleUtil.AreClose(sizeDeviceUnits.Height, requestedSizeDeviceUnits.Y))) 2744if (!double.IsNaN(requestedLeft) && (!DoubleUtil.AreClose(xDeviceUnits, requestedLocationDeviceUnits.X))) 2757if (!double.IsNaN(requestedTop) && (!DoubleUtil.AreClose(yDeviceUnits, requestedLocationDeviceUnits.Y))) 3935if ((double.IsNaN(Owner.Width)) || 3936(double.IsNaN(Owner.Height))) 3943if ((double.IsNaN(Owner.Left)) || 3944(double.IsNaN(Owner.Top))) 5683if (!Double.IsPositiveInfinity(l) && !double.IsNaN(l) && 5724if (!IsSourceWindowNull && !IsCompositionTargetInvalid && !double.IsNaN(height)) 5822if (!IsSourceWindowNull && !IsCompositionTargetInvalid && !double.IsNaN(width)) 6081if (double.IsNaN(top)) 6117if (!double.IsNaN(newTop)) 6121Invariant.Assert(!Double.IsNaN(_actualLeft), "_actualLeft cannot be NaN after show"); 6122UpdateHwndPositionOnTopLeftChange(Double.IsNaN(Left) ? _actualLeft : Left, newTop); 6156if (double.IsNaN(left)) 6212if (!double.IsNaN(newLeft)) 6216Invariant.Assert(!Double.IsNaN(_actualTop), "_actualTop cannot be NaN after show"); 6217UpdateHwndPositionOnTopLeftChange(newLeft, Double.IsNaN(Top) ? _actualTop : Top); 7109if (!double.IsNaN(_prePanningLocation.X) && !double.IsNaN(_prePanningLocation.Y) && (_swh != null))
PresentationFramework.Aero (10)
Microsoft\Windows\Themes\ProgressBarHighlightConverter.cs (2)
50if (width <= 0.0 || Double.IsInfinity(width) || Double.IsNaN(width) || 51height <= 0.0 || Double.IsInfinity(height) || Double.IsNaN(height) )
Microsoft\Windows\Themes\ScrollChrome.cs (4)
745if (double.IsNaN(widthScale) || double.IsInfinity(widthScale) || double.IsNaN(heightScale) || double.IsInfinity(heightScale) || 746double.IsNaN(x) || double.IsInfinity(x) || double.IsNaN(y) || double.IsInfinity(y))
src\Microsoft.DotNet.Wpf\src\Themes\Shared\Microsoft\Windows\Themes\SystemDropShadowChrome.cs (4)
68double.IsNaN(cr.TopLeft) || double.IsNaN(cr.TopRight) || double.IsNaN(cr.BottomLeft) || double.IsNaN(cr.BottomRight) ||
PresentationFramework.Aero2 (10)
Microsoft\Windows\Themes\ProgressBarHighlightConverter.cs (2)
50if (width <= 0.0 || Double.IsInfinity(width) || Double.IsNaN(width) || 51height <= 0.0 || Double.IsInfinity(height) || Double.IsNaN(height) )
Microsoft\Windows\Themes\ScrollChrome.cs (4)
745if (double.IsNaN(widthScale) || double.IsInfinity(widthScale) || double.IsNaN(heightScale) || double.IsInfinity(heightScale) || 746double.IsNaN(x) || double.IsInfinity(x) || double.IsNaN(y) || double.IsInfinity(y))
src\Microsoft.DotNet.Wpf\src\Themes\Shared\Microsoft\Windows\Themes\SystemDropShadowChrome.cs (4)
68double.IsNaN(cr.TopLeft) || double.IsNaN(cr.TopRight) || double.IsNaN(cr.BottomLeft) || double.IsNaN(cr.BottomRight) ||
PresentationFramework.AeroLite (6)
src\Microsoft.DotNet.Wpf\src\Themes\Shared\Microsoft\Windows\Themes\ProgressBarBrushConverter.cs (2)
54if (width <= 0.0 || Double.IsInfinity(width) || Double.IsNaN(width) || 55height <= 0.0 || Double.IsInfinity(height) || Double.IsNaN(height) )
src\Microsoft.DotNet.Wpf\src\Themes\Shared\Microsoft\Windows\Themes\SystemDropShadowChrome.cs (4)
68double.IsNaN(cr.TopLeft) || double.IsNaN(cr.TopRight) || double.IsNaN(cr.BottomLeft) || double.IsNaN(cr.BottomRight) ||
PresentationFramework.Classic (6)
src\Microsoft.DotNet.Wpf\src\Themes\Shared\Microsoft\Windows\Themes\ProgressBarBrushConverter.cs (2)
54if (width <= 0.0 || Double.IsInfinity(width) || Double.IsNaN(width) || 55height <= 0.0 || Double.IsInfinity(height) || Double.IsNaN(height) )
src\Microsoft.DotNet.Wpf\src\Themes\Shared\Microsoft\Windows\Themes\SystemDropShadowChrome.cs (4)
68double.IsNaN(cr.TopLeft) || double.IsNaN(cr.TopRight) || double.IsNaN(cr.BottomLeft) || double.IsNaN(cr.BottomRight) ||
PresentationFramework.Luna (10)
Microsoft\Windows\Themes\ScrollChrome.cs (4)
597if (double.IsNaN(widthScale) || double.IsInfinity(widthScale) || double.IsNaN(heightScale) || double.IsInfinity(heightScale) || 598double.IsNaN(x) || double.IsInfinity(x) || double.IsNaN(y) || double.IsInfinity(y))
src\Microsoft.DotNet.Wpf\src\Themes\Shared\Microsoft\Windows\Themes\ProgressBarBrushConverter.cs (2)
54if (width <= 0.0 || Double.IsInfinity(width) || Double.IsNaN(width) || 55height <= 0.0 || Double.IsInfinity(height) || Double.IsNaN(height) )
src\Microsoft.DotNet.Wpf\src\Themes\Shared\Microsoft\Windows\Themes\SystemDropShadowChrome.cs (4)
68double.IsNaN(cr.TopLeft) || double.IsNaN(cr.TopRight) || double.IsNaN(cr.BottomLeft) || double.IsNaN(cr.BottomRight) ||
PresentationFramework.Royale (10)
Microsoft\Windows\Themes\ScrollChrome.cs (4)
557if (double.IsNaN(widthScale) || double.IsInfinity(widthScale) || double.IsNaN(heightScale) || double.IsInfinity(heightScale) || 558double.IsNaN(x) || double.IsInfinity(x) || double.IsNaN(y) || double.IsInfinity(y))
src\Microsoft.DotNet.Wpf\src\Themes\Shared\Microsoft\Windows\Themes\ProgressBarBrushConverter.cs (2)
54if (width <= 0.0 || Double.IsInfinity(width) || Double.IsNaN(width) || 55height <= 0.0 || Double.IsInfinity(height) || Double.IsNaN(height) )
src\Microsoft.DotNet.Wpf\src\Themes\Shared\Microsoft\Windows\Themes\SystemDropShadowChrome.cs (4)
68double.IsNaN(cr.TopLeft) || double.IsNaN(cr.TopRight) || double.IsNaN(cr.BottomLeft) || double.IsNaN(cr.BottomRight) ||
PresentationUI (2)
MS\Internal\Documents\Application\ZoomComboBox.cs (1)
460if (!(double.IsNaN(zoomValue)) && !(double.IsInfinity(zoomValue)))
TenFeetInstallationProgress.xaml.cs (1)
123if (double.IsNaN(percentDone))
ReachFramework (20)
AlphaFlattener\Utility.cs (17)
1063else if (Double.IsNaN(opacity) || (opacity < 0)) 2147return !double.IsNaN(value); 2152return !double.IsNaN(point.X) && !double.IsNaN(point.Y); 2163return !double.IsNaN(size.Width) && !double.IsNaN(size.Height); 2174return !double.IsNaN(rect.X) && 2175!double.IsNaN(rect.Y) && 2176!double.IsNaN(rect.Width) && 2177!double.IsNaN(rect.Height); 2188!double.IsNaN(matrix.M11) && 2189!double.IsNaN(matrix.M12) && 2190!double.IsNaN(matrix.M21) && 2191!double.IsNaN(matrix.M22) && 2192!double.IsNaN(matrix.OffsetX) && 2193!double.IsNaN(matrix.OffsetY); 2227if (double.IsNaN(value) || value <= 0)
Serialization\Manager\ReachSerializationUtils.cs (2)
1174double.IsNaN(documentSize.Width) || 1175double.IsNaN(documentSize.Height) ||
Serialization\VisualSerializer.cs (1)
373if (double.IsNaN(offset))
Roslyn.Diagnostics.Analyzers (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Roslyn.Diagnostics.CSharp.Analyzers (1)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\ExpressionGenerator.cs (1)
176if (double.IsNaN(value))
Roslyn.Diagnostics.VisualBasic.Analyzers (2)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\VisualBasic\CodeGeneration\ExpressionGenerator.vb (2)
279If Double.IsNaN(value) Then 304If Double.IsNaN(value) Then
Roslyn.VisualStudio.Next.UnitTests (1)
Services\PerformanceTrackerServiceTests.cs (1)
178if (double.IsNaN(timeSpan))
System.CodeDom (2)
Microsoft\CSharp\CSharpCodeGenerator.cs (1)
1540if (double.IsNaN(d))
Microsoft\VisualBasic\VBCodeGenerator.cs (1)
985if (double.IsNaN(d))
System.Formats.Cbor (3)
System\Formats\Cbor\Reader\CborReader.Tag.cs (1)
122if (double.IsNaN(seconds) || double.IsInfinity(seconds))
System\Formats\Cbor\Writer\CborWriter.Simple.cs (1)
137return double.IsNaN(value) || BitConverter.DoubleToInt64Bits(result) == BitConverter.DoubleToInt64Bits(value);
System\Formats\Cbor\Writer\CborWriter.Tag.cs (1)
76if (double.IsInfinity(seconds) || double.IsNaN(seconds))
System.Linq.AsyncEnumerable (5)
System\Linq\MaxAsync.cs (2)
185while (double.IsNaN(value)) 244if (value is null || x > value || double.IsNaN((double)value))
System\Linq\MinAsync.cs (3)
183if (double.IsNaN(value)) 203else if (double.IsNaN(x)) 253if (value == null || x < value || double.IsNaN(x.GetValueOrDefault()))
System.Linq.Parallel (8)
System\Linq\Parallel\QueryOperators\Inlined\DoubleMinMaxAggregationOperator.cs (4)
70if (current < best || double.IsNaN(current)) 81if (current > best || double.IsNaN(best)) 149if (elem < currentElement || double.IsNaN(elem)) 163if (elem > currentElement || double.IsNaN(currentElement))
System\Linq\Parallel\QueryOperators\Inlined\NullableDoubleMinMaxAggregationOperator.cs (4)
70if (best == null || current < best || double.IsNaN(current.GetValueOrDefault())) 82if (best == null || current > best || double.IsNaN(best.GetValueOrDefault())) 150if (currentElement == null || elem < currentElement || double.IsNaN(elem.GetValueOrDefault())) 165if (currentElement == null || elem > currentElement || double.IsNaN(currentElement.GetValueOrDefault()))
System.Private.CoreLib (31)
src\libraries\System.Private.CoreLib\src\System\Collections\Generic\ArraySortHelper.cs (1)
1119if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i])) ||
src\libraries\System.Private.CoreLib\src\System\Double.cs (12)
290if (IsNaN(m_value)) 292return IsNaN(value) ? 0 : -1; 295Debug.Assert(IsNaN(value)); 336return IsNaN(obj) && IsNaN(m_value); 983if (!IsNaN(y)) 1014if (!IsNaN(y)) 1154if ((ax > ay) || IsNaN(ay)) 1184if ((ax < ay) || IsNaN(ay)) 1410IsNaN(value) ? 0.0m : (decimal)value; 1712else if (IsNaN(x)) 1757else if (IsNaN(x))
src\libraries\System.Private.CoreLib\src\System\Int128.cs (2)
494else if (double.IsNaN(value)) 514if ((value < -TwoPow127) || double.IsNaN(value) || (value >= +TwoPow127))
src\libraries\System.Private.CoreLib\src\System\Math.cs (9)
828if (double.IsNaN(x)) 833if (double.IsNaN(y)) 840if (double.IsNaN(regularMod)) 906if (double.IsNaN(a)) 911if (double.IsNaN(newBase)) 954if (!double.IsNaN(val1)) 1076if ((ax > ay) || double.IsNaN(ax)) 1114if (!double.IsNaN(val1)) 1236if ((ax < ay) || double.IsNaN(ax))
src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\NFloat.cs (1)
584public static bool IsNaN(NFloat value) => NativeType.IsNaN(value._value);
src\libraries\System.Private.CoreLib\src\System\TimeSpan.cs (4)
644if (double.IsNaN(value)) 653if ((ticks > MaxTicks) || (ticks < MinTicks) || double.IsNaN(ticks)) 916if (double.IsNaN(factor)) 933if (double.IsNaN(divisor))
src\libraries\System.Private.CoreLib\src\System\UInt128.cs (2)
512if (double.IsNegative(value) || double.IsNaN(value)) 535if ((value < 0.0) || double.IsNaN(value) || (value >= TwoPow128))
System.Private.Xml (29)
System\Xml\Serialization\XmlSerializationWriter.cs (1)
4287if (double.IsNaN((double)value))
System\Xml\XmlConvert.cs (1)
1731if (double.IsNaN(value))
System\Xml\XPath\Internal\BooleanFunctions.cs (1)
47return number != 0 && !double.IsNaN(number);
System\Xml\XPath\Internal\StringFunctions.cs (2)
171if (double.IsNaN(num) || str1.Length <= num) 178if (double.IsNaN(num1))
System\Xml\XPath\Internal\XPathScanner.cs (1)
95Debug.Assert(!double.IsNaN(_numberValue));
System\Xml\Xsl\IlGen\XmlILOptimizerVisitor.cs (2)
5441if (double.IsNaN((double)litLeft) || double.IsNaN((double)litRight))
System\Xml\Xsl\Runtime\XmlAggregates.cs (2)
236if (_cnt == 0 || value < _result || double.IsNaN(value)) 244if (_cnt == 0 || value > _result || double.IsNaN(value))
System\Xml\Xsl\Runtime\XmlSortKey.cs (1)
303if (double.IsNaN(value))
System\Xml\Xsl\Runtime\XsltFunctions.cs (2)
69Debug.Assert(value.Length < startIndex || double.IsNaN(startIndex)); 96Debug.Assert(endIndex <= startIndex || double.IsNaN(endIndex));
System\Xml\Xsl\XPathConvert.cs (5)
44if (double.IsNaN(x)) 48if (double.IsNaN(y)) 2581Debug.Assert(dbl == dblLo || double.IsNaN(dblLo)); 2600Debug.Assert(double.IsNaN(dblLowPrec) || dblLowPrec == dbl); 2869if (double.IsNaN(dbl))
System\Xml\Xsl\Xslt\MatcherBuilder.cs (3)
128_priority = double.IsNaN(template.Priority) ? XPathPatternBuilder.GetPriority(filter) : template.Priority; 234Debug.Assert(!double.IsNaN(x!._priority)); 235Debug.Assert(!double.IsNaN(y!._priority));
System\Xml\Xsl\Xslt\XslAst.cs (1)
204if (!double.IsNaN(Priority))
System\Xml\Xsl\Xslt\XsltInput.cs (1)
652if (double.IsNaN(version))
System\Xml\Xsl\Xslt\XsltLoader.cs (1)
1151if (double.IsNaN(priority) && !_input.ForwardCompatibility)
System\Xml\Xsl\XsltOld\TemplateAction.cs (3)
106Debug.Assert(double.IsNaN(_priority)); 108if (double.IsNaN(_priority) && !compiler.ForwardCompatibility) 128if (!double.IsNaN(_priority) || _matchKey == Compiler.InvalidQueryKey)
System\Xml\Xsl\XsltOld\TemplateManager.cs (2)
28Debug.Assert(!double.IsNaN(tx.Priority)); 29Debug.Assert(!double.IsNaN(ty.Priority));
System.Runtime.Numerics (11)
System\Numerics\BigInteger.cs (2)
4359result = double.IsNaN(actualValue) ? Zero : (BigInteger)actualValue; 4476result = double.IsNaN(actualValue) ? Zero : (BigInteger)actualValue;
System\Numerics\Complex.cs (9)
300Debug.Assert((x >= 0.0) || double.IsNaN(x)); 529Debug.Assert((x >= 0.0) || double.IsNaN(x)); 530Debug.Assert((y >= 0.0) || double.IsNaN(y)); 638if (double.IsNaN(value.m_real)) 646if (double.IsNaN(value.m_imaginary)) 1092if ((ax > ay) || double.IsNaN(ax)) 1182if ((ax > ay) || double.IsNaN(ay)) 1272if ((ax < ay) || double.IsNaN(ax)) 1364if ((ax < ay) || double.IsNaN(ay))
System.Text.Json (1)
System\Text\Json\Writer\Utf8JsonWriter.WriteValues.Double.cs (1)
155if (double.IsNaN(value))
System.Windows.Controls.Ribbon (21)
Microsoft\Windows\Controls\ActivatingKeyTipEventArgs.cs (2)
84if (double.IsInfinity(value) || double.IsNaN(value)) 103if (double.IsInfinity(value) || double.IsNaN(value))
Microsoft\Windows\Controls\Ribbon\Primitives\RibbonGroupsPanel.cs (1)
178if (double.IsNaN(_nextGroupIncreaseWidth) ||
Microsoft\Windows\Controls\Ribbon\Primitives\RibbonTabHeadersPanel.cs (1)
1043if (double.IsNaN(offset))
Microsoft\Windows\Controls\Ribbon\Primitives\RibbonTabsPanel.cs (1)
295if (double.IsNaN(offset))
Microsoft\Windows\Controls\Ribbon\Primitives\StarLayoutInfo.cs (3)
105return (!double.IsNaN(starWeight) && 119return (!double.IsNaN(starMinWidth) && 139return (!double.IsNaN(starMaxWidth) &&
Microsoft\Windows\Controls\Ribbon\RibbonApplicationMenu.cs (2)
345if (double.IsNaN(currentXPosition)) 351if (double.IsNaN(currentYPosition))
Microsoft\Windows\Controls\Ribbon\RibbonControlLength.cs (1)
48if (double.IsNaN(value))
Microsoft\Windows\Controls\Ribbon\RibbonControlLengthConverter.cs (1)
94if (double.IsNaN(doubleValue))
Microsoft\Windows\Controls\Ribbon\RibbonHelper.cs (2)
2868!(double.IsNaN(oldHeight) && double.IsNaN(newHeight)))
Microsoft\Windows\Controls\Ribbon\RibbonMenuButton.cs (3)
1012if (double.IsNaN(_itemsPresenter.Width) || double.IsNaN(_itemsPresenter.Height)) 1165return (double.IsNaN(v)) || (v >= 0.0d && !Double.IsPositiveInfinity(v));
Microsoft\Windows\Controls\Ribbon\RibbonMenuItem.cs (3)
1076if (double.IsNaN(_itemsPresenter.Width) || double.IsNaN(_itemsPresenter.Height)) 1331if (double.IsNaN(_popupOffsetY))
Microsoft\Windows\Controls\Ribbon\RibbonTabHeader.cs (1)
140if (double.IsNaN(_initialPadding.Left))
System.Windows.Forms (1)
System\Windows\Forms\Controls\ToolStrips\ToolStrip.cs (1)
2186if (minTan == tan && !double.IsNaN(minTan))
System.Windows.Input.Manipulations (40)
System\Windows\Input\Manipulations\DoubleUtil.cs (2)
169if (!double.IsNaN(max) && d > max) 173if (!double.IsNaN(min) && d < min)
System\Windows\Input\Manipulations\InertiaExpansionBehavior2D.cs (1)
312if (value < 1 || double.IsInfinity(value) || double.IsNaN(value))
System\Windows\Input\Manipulations\InertiaProcessor2D.cs (36)
609if (!double.IsNaN(this.desiredDisplacement)) 611Debug.Assert(double.IsNaN(this.desiredDeceleration), "desiredDisplacement and desiredDeceleration are mutually exclusive."); 620else if (!double.IsNaN(this.desiredDeceleration)) 622Debug.Assert(double.IsNaN(this.desiredDisplacement), "desiredDisplacement and desiredDeceleration are mutually exclusive."); 669!double.IsNaN(state.Offset) || !double.IsNaN(state.AbsoluteDeceleration), 686if (!double.IsNaN(state.Offset)) 716else if (double.IsNaN(state.Offset)) 724Debug.Assert(!double.IsNaN(state.Deceleration)); 725Debug.Assert(!double.IsNaN(state.Offset)); 793!double.IsNaN(this.expansion.InitialValue), "Invalid initial expansion value."); 838!double.IsNaN(this.expansion.InitialValue), "Invalid initial expansion value."); 903Debug.Assert(!double.IsNaN(initialVelocity) && !double.IsInfinity(initialValue)); 904Debug.Assert(!double.IsNaN(initialVelocity) && !double.IsInfinity(initialVelocity)); 905Debug.Assert(!double.IsNaN(deceleration) && !double.IsInfinity(deceleration)); 906Debug.Assert(!double.IsNaN(timeDelta) && !double.IsInfinity(timeDelta) && timeDelta >= 0); 920Debug.Assert(!double.IsNaN(timeDelta) && !double.IsInfinity(timeDelta) && timeDelta >= 0); 941if (double.IsNaN(resultValue)) 954Debug.Assert(!double.IsNaN(resultValue) && !double.IsInfinity(resultValue), "Calculation error, value should be a finite number."); 1042if (double.IsNaN(value)) 1059Debug.Assert(!double.IsNaN(length) && length >= 0 && !double.IsInfinity(length)); 1064if (!double.IsNaN(baseVector.X) && !double.IsNaN(baseVector.Y) && 1229Debug.Assert(initialState.AbsoluteDeceleration >= 0 || double.IsNaN(initialState.AbsoluteDeceleration)); 1230Debug.Assert(initialState.AbsoluteOffset >= 0 || double.IsNaN(initialState.AbsoluteOffset)); 1240this.ExtrapolationResult = double.IsNaN(this.InitialVelocity) ? ExtrapolationResult.Skip : ExtrapolationResult.Continue; 1285if (double.IsNaN(this.InitialVelocity)) 1292Debug.Assert(!double.IsNaN(this.InitialValue) && !double.IsInfinity(this.InitialValue)); 1293Debug.Assert(!double.IsNaN(this.InitialVelocity) && !double.IsInfinity(this.InitialVelocity)); 1294Debug.Assert(!double.IsNaN(this.Offset)); // can be infinity 1295Debug.Assert(!double.IsNaN(this.AbsoluteDeceleration) && this.AbsoluteDeceleration >= 0 && !double.IsInfinity(this.InitialVelocity)); 1296Debug.Assert(!double.IsNaN(this.Duration) && this.Duration >= 0); // can be infinity 1297Debug.Assert(!double.IsNaN(this.FinalValue)); // can be infinity 1336Debug.Assert(!double.IsNaN(value) && !double.IsInfinity(value)); 1337Debug.Assert(!double.IsNaN(delta) && !double.IsInfinity(delta)); 1338Debug.Assert(!double.IsNaN(total) && !double.IsInfinity(total));
System\Windows\Input\Manipulations\ManipulationSequence.cs (1)
751Debug.Assert(!double.IsNaN(value));
Test.Utilities (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
Text.Analyzers (1)
src\Dependencies\Collections\Internal\ArraySortHelper.cs (1)
1241if ((typeof(TKey) == typeof(double) && double.IsNaN((double)(object)keys[i]))
UIAutomationClient (2)
System\Windows\Automation\AutomationElement.cs (2)
882if (double.IsNaN (((Point) ptClickable).X) || double.IsNaN (((Point) ptClickable).Y))
UIAutomationClientSideProviders (1)
MS\Internal\AutomationProxies\WindowsUpDown.cs (1)
208if (double.IsNaN(val))
xunit.assert (2)
EqualityAsserts.cs (2)
395 if (double.IsNaN(tolerance) || double.IsNegativeInfinity(tolerance) || tolerance < 0.0) 876 if (double.IsNaN(tolerance) || double.IsNegativeInfinity(tolerance) || tolerance < 0.0)