604 references to GetValueOrDefault
Aspire.Dashboard (5)
Components\Controls\Chart\ChartBase.cs (1)
185trace.Tooltips.Add(FormatTooltip(trace.Name, trace.Values[i].GetValueOrDefault(), data.XValues[i]));
Components\Layout\MainLayout.razor.cs (1)
232return !Options.CurrentValue.Api.Disabled.GetValueOrDefault() &&
DashboardEndpointsBuilder.cs (1)
98if (dashboardOptions.Api.Disabled.GetValueOrDefault())
DashboardWebApplication.cs (2)
453_logger.LogDebug("Dashboard API disabled: {ApiDisabled}", _dashboardOptionsMonitor.CurrentValue.Api.Disabled.GetValueOrDefault()); 457if (!_dashboardOptionsMonitor.CurrentValue.Api.Disabled.GetValueOrDefault() &&
Aspire.Hosting (2)
Backchannel\AuxiliaryBackchannelRpcTarget.cs (2)
1621var serverTailLineCount = !follow && tail.GetValueOrDefault() > 0 && resourcesToLog.Count == 1 1622? tail.GetValueOrDefault()
Aspire.Hosting.Tests (7)
Dcp\DcpExecutorTests.cs (5)
4845Assert.True(exe.Spec.Persistent.GetValueOrDefault()); 5226Assert.True(container.Spec.Persistent.GetValueOrDefault()); 5236Assert.True(exe.Spec.Persistent.GetValueOrDefault()); 5379Assert.True(container.Spec.Persistent.GetValueOrDefault()); 5390Assert.True(exe.Spec.Persistent.GetValueOrDefault());
DistributedApplicationTests.cs (2)
2062Assert.True(dcpContainer.Spec.Persistent.GetValueOrDefault()); 2071Assert.True(dcpExecutable.Spec.Persistent.GetValueOrDefault());
GenerateDocumentationAndConfigFiles (14)
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (4)
141=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 144=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedHashSet`1.cs (4)
102=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 105=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedList`1.cs (4)
121=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 124=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\RoslynAnalyzers\Microsoft.CodeAnalysis.Analyzers\Core\MetaAnalyzers\ReleaseTrackingHelper.cs (1)
427return (x?.CompareTo(y)).GetValueOrDefault() * -1;
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.TypeParameterSymbolKey.cs (1)
47return resolution.GetValueOrDefault();
ILAssembler (2)
GrammarVisitor.cs (2)
5736suffix.WriteCompressedInteger(bounds[bIdx].Upper.GetValueOrDefault()); 5741suffix.WriteCompressedSignedInteger(bounds[bIdx].Lower.GetValueOrDefault());
Microsoft.AspNetCore.Authentication.Abstractions (2)
AuthenticationProperties.cs (2)
187Items[key] = value.GetValueOrDefault().ToString(); 219Items[key] = value.GetValueOrDefault().ToString(UtcDateTimeFormat, CultureInfo.InvariantCulture);
Microsoft.AspNetCore.Components (1)
BindConverter.cs (1)
1582value = converted.GetValueOrDefault();
Microsoft.AspNetCore.DataProtection (4)
AuthenticatedEncryption\ConfigurationModel\XmlExtensions.cs (1)
17return ((bool?)element.Attribute(XmlConstants.RequiresEncryptionAttributeName)).GetValueOrDefault();
Repositories\EphemeralXmlRepository.cs (1)
78.OrderBy(e => e.DeletionOrder.GetValueOrDefault());
Repositories\FileSystemXmlRepository.cs (1)
197.OrderBy(e => e.DeletionOrder.GetValueOrDefault());
Repositories\RegistryXmlRepository.cs (1)
179.OrderBy(e => e.DeletionOrder.GetValueOrDefault());
Microsoft.AspNetCore.Grpc.JsonTranscoding (1)
Internal\JsonRequestHelpers.cs (1)
340var contentLength = serverCallContext.HttpContext.Request.ContentLength.GetValueOrDefault();
Microsoft.AspNetCore.Http (5)
Features\FormFeature.cs (1)
268file = new FormFile(_request.Body, section.BaseStreamOffset.GetValueOrDefault(), section.Body.Length, name, fileName);
HeaderDictionary.cs (1)
139this[HeaderNames.ContentLength] = HeaderUtilities.FormatNonNegativeInt64(value.GetValueOrDefault());
parent\parent\Shared\StreamCopyOperationInternal.cs (3)
41Debug.Assert(!bytesRemaining.HasValue || bytesRemaining.GetValueOrDefault() >= 0); 47if (bytesRemaining.HasValue && bytesRemaining.GetValueOrDefault() <= 0) 57readLength = (int)Math.Min(bytesRemaining.GetValueOrDefault(), (long)readLength);
Microsoft.AspNetCore.Http.Abstractions (3)
CookieBuilder.cs (1)
118Expires = Expiration.HasValue ? expiresFrom.Add(Expiration.GetValueOrDefault()) : default(DateTimeOffset?)
Internal\ParsingHelpers.cs (2)
92if (!values.HasValue || StringValues.IsNullOrEmpty(values.GetValueOrDefault())) 98headers[key] = values.GetValueOrDefault();
Microsoft.AspNetCore.Http.Connections.Common (2)
NegotiateProtocol.cs (2)
196version = reader.ReadAsInt32(NegotiateVersionPropertyName).GetValueOrDefault(); 230tokenLifetime = TimeSpan.FromSeconds(reader.ReadAsInt32(TokenLifetimePropertyName).GetValueOrDefault());
Microsoft.AspNetCore.Http.Extensions (5)
HeaderDictionaryTypeExtensions.cs (1)
127headers[name] = HeaderUtilities.FormatDate(value.GetValueOrDefault());
parent\parent\Shared\StreamCopyOperationInternal.cs (3)
41Debug.Assert(!bytesRemaining.HasValue || bytesRemaining.GetValueOrDefault() >= 0); 47if (bytesRemaining.HasValue && bytesRemaining.GetValueOrDefault() <= 0) 57readLength = (int)Math.Min(bytesRemaining.GetValueOrDefault(), (long)readLength);
src\aspnetcore\src\Shared\ProblemDetails\ProblemDetailsDefaults.cs (1)
189var status = problemDetails.Status.GetValueOrDefault();
Microsoft.AspNetCore.Http.Results (4)
parent\parent\Shared\StreamCopyOperationInternal.cs (3)
41Debug.Assert(!bytesRemaining.HasValue || bytesRemaining.GetValueOrDefault() >= 0); 47if (bytesRemaining.HasValue && bytesRemaining.GetValueOrDefault() <= 0) 57readLength = (int)Math.Min(bytesRemaining.GetValueOrDefault(), (long)readLength);
src\aspnetcore\src\Shared\ProblemDetails\ProblemDetailsDefaults.cs (1)
189var status = problemDetails.Status.GetValueOrDefault();
Microsoft.AspNetCore.Mvc.Core (1)
src\aspnetcore\src\Shared\ProblemDetails\ProblemDetailsDefaults.cs (1)
189var status = problemDetails.Status.GetValueOrDefault();
Microsoft.AspNetCore.Mvc.Formatters.Xml (2)
XmlDataContractSerializerInputFormatter.cs (1)
123var contentLength = request.ContentLength.GetValueOrDefault();
XmlSerializerInputFormatter.cs (1)
107var contentLength = request.ContentLength.GetValueOrDefault();
Microsoft.AspNetCore.Mvc.NewtonsoftJson (1)
NewtonsoftJsonInputFormatter.cs (1)
123var contentLength = request.ContentLength.GetValueOrDefault();
Microsoft.AspNetCore.Owin (1)
DictionaryStringValuesWrapper.cs (1)
68Inner[HeaderNames.ContentLength] = (StringValues)HeaderUtilities.FormatNonNegativeInt64(value.GetValueOrDefault());
Microsoft.AspNetCore.Razor.Utilities.Shared (2)
src\roslyn\src\Razor\src\Shared\Microsoft.AspNetCore.Razor.SharedUtilities\NullableExtensions.cs (2)
51return value.GetValueOrDefault(); 64return value.GetValueOrDefault();
Microsoft.AspNetCore.Rewrite (1)
RedirectToHttpsRule.cs (1)
21if (SSLPort.HasValue && (port = SSLPort.GetValueOrDefault()) > 0)
Microsoft.AspNetCore.Server.IIS (1)
Core\IISHttpContext.cs (1)
427return RequestHeaders.ContentLength.GetValueOrDefault() > 0;
Microsoft.AspNetCore.Server.Kestrel.Core (31)
Internal\Http\Http1ContentLengthMessageBody.cs (1)
251KestrelBadHttpRequestException.Throw(RequestRejectionReason.RequestBodyTooLarge, maxRequestBodySize.GetValueOrDefault().ToString(CultureInfo.InvariantCulture));
Internal\Http\Http1MessageBody.cs (1)
148&& headers.ContentLength.GetValueOrDefault() == 0
Internal\Http\HttpHeaders.Generated.cs (3)
8649_current = new KeyValuePair<string, StringValues>(HeaderNames.ContentLength, HeaderUtilities.FormatNonNegativeInt64(_collection._contentLength.GetValueOrDefault())); 14819output.WriteNumeric((ulong)ContentLength.GetValueOrDefault()); 15482_current = new KeyValuePair<string, StringValues>(HeaderNames.ContentLength, HeaderUtilities.FormatNonNegativeInt64(_collection._contentLength.GetValueOrDefault()));
Internal\Http2\Http2Connection.cs (6)
1643UpdateHeaderParsingState(value, GetPseudoHeaderField(staticTableIndex.GetValueOrDefault())); 1645_currentHeadersStream.OnHeader(staticTableIndex.GetValueOrDefault(), indexOnly: true, name, value); 1648UpdateHeaderParsingState(value, GetPseudoHeaderField(staticTableIndex.GetValueOrDefault())); 1651_currentHeadersStream.OnHeader(staticTableIndex.GetValueOrDefault(), indexOnly: false, name, value); 1657UpdateHeaderParsingState(value, GetPseudoHeaderField(staticTableIndex.GetValueOrDefault())); 1659_currentHeadersStream.OnHeader(staticTableIndex.GetValueOrDefault(), indexOnly: false, name, value);
Internal\Http2\Http2MessageBody.cs (1)
40KestrelBadHttpRequestException.Throw(RequestRejectionReason.RequestBodyTooLarge, maxRequestBodySize.GetValueOrDefault().ToString(CultureInfo.InvariantCulture));
Internal\Http3\Http3MessageBody.cs (1)
31KestrelBadHttpRequestException.Throw(RequestRejectionReason.RequestBodyTooLarge, maxRequestBodySize.GetValueOrDefault().ToString(CultureInfo.InvariantCulture));
Internal\Http3\Http3Stream.cs (6)
380UpdateHeaderParsingState(value, GetPseudoHeaderField(staticTableIndex.GetValueOrDefault())); 382OnHeader(staticTableIndex.GetValueOrDefault(), indexOnly: true, name, value); 385UpdateHeaderParsingState(value, GetPseudoHeaderField(staticTableIndex.GetValueOrDefault())); 388OnHeader(staticTableIndex.GetValueOrDefault(), indexOnly: false, name, value); 394UpdateHeaderParsingState(value, GetPseudoHeaderField(staticTableIndex.GetValueOrDefault())); 396OnHeader(staticTableIndex.GetValueOrDefault(), indexOnly: false, name, value);
src\aspnetcore\src\Shared\runtime\Http2\Hpack\HPackDecoder.cs (6)
198ReadOnlySpan<byte> headerBytes = data.Slice(_headerNameRange.GetValueOrDefault().start, _headerNameRange.GetValueOrDefault().length); 508: data.Slice(_headerValueRange.GetValueOrDefault().start, _headerValueRange.GetValueOrDefault().length); 523: data.Slice(_headerNameRange.GetValueOrDefault().start, _headerNameRange.GetValueOrDefault().length);
src\aspnetcore\src\Shared\runtime\Http3\QPack\QPackDecoder.cs (6)
249ReadOnlySpan<byte> headerBytes = data.Slice(_headerNameRange.GetValueOrDefault().start, _headerNameRange.GetValueOrDefault().length); 595: data.Slice(_headerValueRange.GetValueOrDefault().start, _headerValueRange.GetValueOrDefault().length); 605: data.Slice(_headerNameRange.GetValueOrDefault().start, _headerNameRange.GetValueOrDefault().length);
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic (3)
Internal\QuicConnectionContext.cs (1)
136QuicLog.ConnectionAborted(_log, this, ex.ApplicationErrorCode.GetValueOrDefault(), ex);
Internal\QuicStreamContext.cs (2)
279QuicLog.StreamAbortedRead(_log, this, ex.ApplicationErrorCode.GetValueOrDefault()); 441QuicLog.StreamAbortedWrite(_log, this, ex.ApplicationErrorCode.GetValueOrDefault());
Microsoft.AspNetCore.WebUtilities (3)
MultipartReaderStream.cs (1)
149LengthLimit.GetValueOrDefault() is var lengthLimit &&
StreamHelperExtensions.cs (2)
67if (limit.HasValue && limit.GetValueOrDefault() - total < read) 69throw new InvalidDataException($"The stream exceeded the data limit {limit.GetValueOrDefault()}.");
Microsoft.Build (16)
BackEnd\Client\MSBuildClient.cs (1)
653startedAt: KnownTelemetry.PartialBuildTelemetry.StartAt.GetValueOrDefault(),
BuildCheck\Infrastructure\EditorConfig\EditorConfigGlobsMatcher.cs (1)
284(string numStart, string numEnd) = rangeOpt.GetValueOrDefault();
ElementLocation\XmlDocumentWithLocation.cs (1)
329public override bool IsReadOnly => _loadAsReadOnly.GetValueOrDefault();
Evaluation\Expander.Function.cs (1)
446args[n] = (string)resolved.GetValueOrDefault();
src\5057ed6cf5d6323b\ImmutableSegmentedDictionary`2.cs (4)
141=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 144=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\5057ed6cf5d6323b\ImmutableSegmentedHashSet`1.cs (4)
102=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 105=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\5057ed6cf5d6323b\ImmutableSegmentedList`1.cs (4)
121=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 124=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
Microsoft.CodeAnalysis (30)
CommandLine\AnalyzerConfig.SectionNameMatching.cs (1)
291(string numStart, string numEnd) = rangeOpt.GetValueOrDefault();
CommandLine\NoThrowStreamDisposer.cs (1)
37return _failed.GetValueOrDefault();
Diagnostic\Diagnostic.cs (1)
524return !filterSpan.HasValue || filterSpan.GetValueOrDefault().IntersectsWith(location.SourceSpan);
DiagnosticAnalyzer\AnalysisScope.cs (11)
161if (filterSpan.HasValue && filterFile.GetValueOrDefault().SourceTree != null) 169if (filterSpan.GetValueOrDefault().Start == 0 && filterSpan.GetValueOrDefault().Length == filterFile.GetValueOrDefault().SourceTree!.Length) 227return !FilterFileOpt.HasValue || FilterFileOpt.GetValueOrDefault().SourceTree == tree; 232return !FilterFileOpt.HasValue || FilterFileOpt.GetValueOrDefault().AdditionalFile == file; 245var filterTree = FilterFileOpt.GetValueOrDefault().SourceTree; 273if (FilterFileOpt.GetValueOrDefault().SourceTree == null) 283return !FilterSpanOpt.HasValue || FilterSpanOpt.GetValueOrDefault().IntersectsWith(filterSpan); 288return !FilterSpanOpt.HasValue || FilterSpanOpt.GetValueOrDefault().Contains(filterSpan); 298var filterFile = FilterFileOpt.GetValueOrDefault();
MetadataReference\AssemblyIdentityComparer.cs (1)
99return eq.GetValueOrDefault() ? ComparisonResult.Equivalent : ComparisonResult.NotEquivalent;
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (4)
141=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 144=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedHashSet`1.cs (4)
102=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 105=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedList`1.cs (4)
121=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 124=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
Syntax\LineDirectiveMap.cs (2)
84unmappedStartPos.Character < entry.UnmappedCharacterOffset.GetValueOrDefault()) 98entry.MappedSpan.Start.Character + unmapped.Character - entry.UnmappedCharacterOffset.GetValueOrDefault() :
Syntax\LineMapping.cs (1)
69builder.Append(CharacterOffset.GetValueOrDefault().ToString(System.Globalization.CultureInfo.InvariantCulture));
Microsoft.CodeAnalysis.Analyzers (16)
MetaAnalyzers\ReleaseTrackingHelper.cs (1)
427return (x?.CompareTo(y)).GetValueOrDefault() * -1;
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (4)
141=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 144=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedHashSet`1.cs (4)
102=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 105=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedList`1.cs (4)
121=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 124=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\RoslynAnalyzers\Utilities\Compiler\CodeMetrics\CodeAnalysisMetricData.AssemblyMetricData.cs (1)
57depthOfInheritance = Math.Max(child.DepthOfInheritance.GetValueOrDefault(), depthOfInheritance);
src\roslyn\src\RoslynAnalyzers\Utilities\Compiler\CodeMetrics\CodeAnalysisMetricData.NamespaceMetricData.cs (1)
55depthOfInheritance = Math.Max(child.DepthOfInheritance.GetValueOrDefault(), depthOfInheritance);
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.TypeParameterSymbolKey.cs (1)
47return resolution.GetValueOrDefault();
Microsoft.CodeAnalysis.AnalyzerUtilities (15)
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (4)
141=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 144=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedHashSet`1.cs (4)
102=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 105=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedList`1.cs (4)
121=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 124=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\RoslynAnalyzers\Utilities\Compiler\CodeMetrics\CodeAnalysisMetricData.AssemblyMetricData.cs (1)
57depthOfInheritance = Math.Max(child.DepthOfInheritance.GetValueOrDefault(), depthOfInheritance);
src\roslyn\src\RoslynAnalyzers\Utilities\Compiler\CodeMetrics\CodeAnalysisMetricData.NamespaceMetricData.cs (1)
55depthOfInheritance = Math.Max(child.DepthOfInheritance.GetValueOrDefault(), depthOfInheritance);
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.TypeParameterSymbolKey.cs (1)
47return resolution.GetValueOrDefault();
Microsoft.CodeAnalysis.CodeStyle (14)
src\roslyn\src\Analyzers\Core\Analyzers\Formatting\AbstractFormattingAnalyzer.cs (1)
51var span = context.FilterSpan.HasValue ? context.FilterSpan.GetValueOrDefault() : root.FullSpan;
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (4)
141=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 144=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedHashSet`1.cs (4)
102=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 105=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedList`1.cs (4)
121=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 124=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.TypeParameterSymbolKey.cs (1)
47return resolution.GetValueOrDefault();
Microsoft.CodeAnalysis.CSharp (66)
Binder\Binder_Conversions.cs (2)
2457var conversion = conversionIfTargetTyped.GetValueOrDefault(); 3037member.GetValueOrDefault(),
Binder\Binder_Expressions.cs (3)
2753memberOpt.GetValueOrDefault(), 10555checkInlineArrayBounds(location, constIndex.GetValueOrDefault(), length, excludeEnd, diagnostics); 11328arguments.Names[0].GetValueOrDefault().Location);
Binder\Binder_Operators.cs (8)
190best = staticExtensionBest.GetValueOrDefault(); 1227best = extensionBest.GetValueOrDefault(); 1529UnaryOperatorAnalysisResult trueFalseOperator = (kind == BinaryOperatorKind.LogicalAnd ? falseOperator : trueOperator).GetValueOrDefault(); 1552trueOperator.GetValueOrDefault().Signature.Method, 1553falseOperator.GetValueOrDefault().Signature.Method, 2074possiblyBest = extensionBest.GetValueOrDefault(); 2283best = extensionBest.GetValueOrDefault(); 3371best = staticExtensionBest.GetValueOrDefault();
Binder\Binder.CapturedParametersFinder.cs (1)
159if (isInsideNameof.GetValueOrDefault())
Binder\DecisionDagBuilder_CheckOrReachability.cs (1)
763disjunction = _disjunction.GetValueOrDefault();
Binder\DecisionDagBuilder.cs (4)
4613return easyOut.GetValueOrDefault(); 4634if (easyOut.GetValueOrDefault()) 4694return easyOut.GetValueOrDefault(); 4710value = Hash.Combine(easyOut.GetValueOrDefault(), value);
Binder\Semantics\Conversions\Conversions.cs (1)
88member.GetValueOrDefault(),
Binder\Semantics\Operators\BinaryOperatorOverloadResolution.cs (4)
1227if (op1.Priority.HasValue && op1.Priority.GetValueOrDefault() != op2.Priority.GetValueOrDefault()) 1229return (op1.Priority.GetValueOrDefault() < op2.Priority.GetValueOrDefault()) ? BetterResult.Left : BetterResult.Right;
Binder\Semantics\OverloadResolution\OverloadResolution_ArgsToParameters.cs (1)
322var name = arguments.Names[argumentPosition].GetValueOrDefault().Name;
Binder\Semantics\OverloadResolution\OverloadResolutionResult.cs (5)
496Location badName = arguments.Names[badArg].GetValueOrDefault().Location; 834(string badName, Location location) = arguments.Names[badArg].GetValueOrDefault(); 854(string badName, Location location) = arguments.Names[badArg].GetValueOrDefault(); 868(string name, Location location) = arguments.Names[result.Result.FirstBadArgument].GetValueOrDefault(); 894(string badName, Location location) = arguments.Names[badArg].GetValueOrDefault();
CodeGen\EmitExpression.cs (7)
614return walker._result.GetValueOrDefault(); 1753else if (BoxNonVerifierReferenceReceiver(parentCallReceiverType, addressKind.GetValueOrDefault())) 1763Debug.Assert(addressKind.GetValueOrDefault() != AddressKind.Constrained); 1773if (UseCallResultAsAddress(call, addressKind.GetValueOrDefault())) 1825Debug.Assert(!HasHome(nested, addressKind.GetValueOrDefault())); 1953Debug.Assert((callKind != CallKind.ConstrainedCallVirt) || (addressKind.GetValueOrDefault() == AddressKind.Constrained) || receiverType.IsVerifierValue()); 1978tempOpt = EmitReceiverRef(receiver, addressKind.GetValueOrDefault());
Compiler\ClsComplianceChecker.cs (2)
134else if (assemblyComplianceValue != moduleDeclaredCompliance.GetValueOrDefault()) 1152compliance = declaredCompliance.GetValueOrDefault() ? Compliance.DeclaredTrue : Compliance.DeclaredFalse;
Emitter\Model\MostCommonNullableValueBuilder.cs (1)
70AddValue(value.GetValueOrDefault());
Emitter\Model\PEModuleBuilder.cs (2)
822var context = contextOpt.GetValueOrDefault(); 1737attribute = SynthesizeNullableAttributeIfNecessary(nullableContextValue, commonValue.GetValueOrDefault());
FlowAnalysis\AbstractFlowPass.cs (1)
2717var data = node.InterpolatedStringHandlerData.GetValueOrDefault();
FlowAnalysis\DefiniteAssignment.VariableIdentifier.cs (1)
57Hash.Combine(thisIndex.GetValueOrDefault(), currentKey) :
FlowAnalysis\NullableWalker.cs (1)
9250return AnonymousTypeManager.GetAnonymousTypeProperty(containingType, memberIndex.GetValueOrDefault());
Lowering\LocalRewriter\LocalRewriter_BinaryOperator.cs (1)
1671MakeBooleanConstant(syntax, value.GetValueOrDefault()));
Lowering\LocalRewriter\LocalRewriter_StringInterpolation.cs (2)
21return VisitExpression(interpolatedString.InterpolationData.GetValueOrDefault().Construction); 215return VisitExpression(node.InterpolationData.GetValueOrDefault().Construction);
Operations\CSharpOperationFactory.cs (1)
1611return boundBinaryOperator.RewriteInterpolatedStringAddition((this, boundBinaryOperator.InterpolatedStringHandlerData.GetValueOrDefault()), createInterpolatedString, createBinaryOperator);
Symbols\MemberSignatureComparer.cs (2)
680isNotNullable1.GetValueOrDefault() != isNotNullable2.GetValueOrDefault())
Symbols\Metadata\PE\NullableTypeDecoder.cs (1)
45defaultTransformFlag = value.GetValueOrDefault();
Symbols\Metadata\PE\PEParameterSymbol.cs (1)
269typeWithAnnotations = NullableTypeDecoder.TransformType(typeWithAnnotations, value.GetValueOrDefault(), default);
Symbols\Source\SourceMemberContainerSymbol_ImplementationChecks.cs (1)
266HasBaseTypeDeclaringInterfaceResult matchResult = hasBaseClassDeclaringInterface.GetValueOrDefault();
Symbols\Source\SourceNamespaceSymbol.AliasesAndUsings.cs (1)
654if (applyIsGlobalFilter.HasValue && usingDirective.GlobalKeyword.IsKind(SyntaxKind.GlobalKeyword) != applyIsGlobalFilter.GetValueOrDefault())
Symbols\Symbol.cs (1)
1731value = localValue.GetValueOrDefault();
Symbols\Synthesized\SynthesizedSimpleProgramEntryPointSymbol.cs (1)
280var span = definedWithinSpan.GetValueOrDefault();
Symbols\TypeSymbol.cs (4)
1031availableVersion.GetValueOrDefault().ToDisplayString(), new CSharpRequiredLanguageVersion(requiredVersion)); 1657availableVersion.GetValueOrDefault().ToDisplayString(), 1758availableVersion.GetValueOrDefault().ToDisplayString(), 2214(((MethodSymbol)member).MethodKind is MethodKind.UserDefinedOperator or MethodKind.Conversion) != isOperator.GetValueOrDefault())
Symbols\TypeWithAnnotations.cs (2)
783return x.HasValue == y.HasValue && (!x.HasValue || x.GetValueOrDefault().IsSameAs(y.GetValueOrDefault()));
Utilities\TypeUnionValueSet.cs (3)
140return _lazyMightIncludeNonNull.GetValueOrDefault(); 164_lazyIncludesNull = result.GetValueOrDefault(); 168return _lazyIncludesNull.GetValueOrDefault();
Microsoft.CodeAnalysis.CSharp.CodeStyle (1)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\NewLineUserSettingFormattingRule.cs (1)
51switch (parentKind.GetValueOrDefault())
Microsoft.CodeAnalysis.CSharp.Features (2)
BraceCompletion\CurlyBraceCompletionService.cs (1)
208switch (parentKind.GetValueOrDefault())
EditAndContinue\BreakpointSpans.cs (1)
106span = candidate.GetValueOrDefault();
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\NewLineUserSettingFormattingRule.cs (1)
51switch (parentKind.GetValueOrDefault())
Microsoft.CodeAnalysis.Extensions.Package (12)
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (4)
141=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 144=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedHashSet`1.cs (4)
102=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 105=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedList`1.cs (4)
121=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 124=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
Microsoft.CodeAnalysis.Features (5)
CodeLens\CodeLensReferencesService.cs (1)
241var mappedSpans = results.GetValueOrDefault();
Completion\CompletionItemRules.cs (2)
137matchPriority.GetValueOrDefault() == Default.MatchPriority && 146matchPriority.GetValueOrDefault(), selectionBehavior);
Navigation\NavigableItemFactory.SymbolLocationNavigableItem.cs (1)
36public ImmutableArray<TaggedText> DisplayTaggedParts { get; } = displayTaggedParts.GetValueOrDefault();
src\roslyn\src\Analyzers\Core\Analyzers\Formatting\AbstractFormattingAnalyzer.cs (1)
51var span = context.FilterSpan.HasValue ? context.FilterSpan.GetValueOrDefault() : root.FullSpan;
Microsoft.CodeAnalysis.NetAnalyzers (4)
Microsoft.NetCore.Analyzers\InteropServices\PlatformCompatibilityAnalyzer.cs (1)
908if (supportedRule.GetValueOrDefault())
Microsoft.NetFramework.Analyzers\Helpers\SecurityDiagnosticHelpers.cs (1)
289if (compilation == null || !IsTypeDeclaredInExpectedAssembly(compilation, "System.String", "mscorlib").GetValueOrDefault())
src\sdk\src\Microsoft.CodeAnalysis.NetAnalyzers\src\Utilities\Compiler\CodeMetrics\CodeAnalysisMetricData.AssemblyMetricData.cs (1)
56depthOfInheritance = Math.Max(child.DepthOfInheritance.GetValueOrDefault(), depthOfInheritance);
src\sdk\src\Microsoft.CodeAnalysis.NetAnalyzers\src\Utilities\Compiler\CodeMetrics\CodeAnalysisMetricData.NamespaceMetricData.cs (1)
54depthOfInheritance = Math.Max(child.DepthOfInheritance.GetValueOrDefault(), depthOfInheritance);
Microsoft.CodeAnalysis.Razor.Compiler (1)
Language\Components\ComponentPageDirectivePass.cs (1)
36directive.Node.AddDiagnostic(ComponentDiagnosticFactory.CreatePageDirective_CannotBeImported(directive.Node.Source.GetValueOrDefault()));
Microsoft.CodeAnalysis.ResxSourceGenerator (15)
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (4)
141=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 144=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedHashSet`1.cs (4)
102=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 105=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedList`1.cs (4)
121=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 124=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\RoslynAnalyzers\Utilities\Compiler\CodeMetrics\CodeAnalysisMetricData.AssemblyMetricData.cs (1)
57depthOfInheritance = Math.Max(child.DepthOfInheritance.GetValueOrDefault(), depthOfInheritance);
src\roslyn\src\RoslynAnalyzers\Utilities\Compiler\CodeMetrics\CodeAnalysisMetricData.NamespaceMetricData.cs (1)
55depthOfInheritance = Math.Max(child.DepthOfInheritance.GetValueOrDefault(), depthOfInheritance);
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.TypeParameterSymbolKey.cs (1)
47return resolution.GetValueOrDefault();
Microsoft.CodeAnalysis.VisualBasic (2)
Compilation\ClsComplianceChecker.vb (1)
688compliance = If(declaredCompliance.GetValueOrDefault(), Compliance.DeclaredTrue, Compliance.DeclaredFalse)
Lowering\UseTwiceRewriter.vb (1)
250Return value.GetValueOrDefault()
Microsoft.CodeAnalysis.VisualBasic.Features (1)
EditAndContinue\BreakpointSpans.vb (1)
87span = candidate.GetValueOrDefault()
Microsoft.CodeAnalysis.VisualBasic.NetAnalyzers (1)
Microsoft.NetCore.Analyzers\Resources\BasicMarkAssembliesWithNeutralResourcesLanguage.vb (1)
38attribute.ArgumentList.Arguments.Count > 0).GetValueOrDefault()
Microsoft.CodeAnalysis.Workspaces (15)
Classification\ClassifierHelper.cs (1)
184var newSpan = new ClassifiedSpan(span.ClassificationType, intersection.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (4)
141=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 144=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedHashSet`1.cs (4)
102=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 105=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedList`1.cs (4)
121=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 124=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.TypeParameterSymbolKey.cs (1)
47return resolution.GetValueOrDefault();
Utilities\NullableStructExtensions.cs (1)
11valueOrDefault = value.GetValueOrDefault();
Microsoft.CSharp (2)
Microsoft\CSharp\RuntimeBinder\Semantics\TypeBind.cs (2)
64if (!ats.ConstraintError.GetValueOrDefault()) 109if (atArg.ConstraintError.GetValueOrDefault())
Microsoft.Data.Analysis (4)
PrimitiveColumnContainer.cs (2)
190mutableBuffer[i] = value.GetValueOrDefault(); 230mutableResultBuffer[i] = value.GetValueOrDefault();
PrimitiveDataFrameColumn.cs (2)
883(ref T value) => value = this[cursor.Position].GetValueOrDefault(); 892(ref ushort value) => value = column[cursor.Position].GetValueOrDefault();
Microsoft.Extensions.AI (1)
Embeddings\OpenTelemetryEmbeddingGenerator.cs (1)
197inputTokens = inputTokens.GetValueOrDefault() + (int)i;
Microsoft.Extensions.AI.Abstractions (2)
Contents\DataContent.cs (2)
282ReadOnlyMemory<byte> data = _data.GetValueOrDefault(); 349return _data.GetValueOrDefault();
Microsoft.Extensions.AI.OpenAI (2)
OpenAIResponsesChatClient.cs (2)
1669rtu.InputTokenDetails.CachedTokenCount = cachedTokenCount.GetValueOrDefault(); 1674rtu.OutputTokenDetails.ReasoningTokenCount = reasoningTokenCount.GetValueOrDefault();
Microsoft.Extensions.Caching.Abstractions (1)
DistributedCacheEntryOptions.cs (1)
83field = value.GetValueOrDefault();
Microsoft.Extensions.Caching.Hybrid.Tests (8)
ServiceConstructionTests.cs (4)
596Expiration = defaultExpiration is null ? null : TimeSpan.FromMinutes(defaultExpiration.GetValueOrDefault()), 597LocalCacheExpiration = defaultLocalCacheExpiration is null ? null : TimeSpan.FromMinutes(defaultLocalCacheExpiration.GetValueOrDefault()), 611Expiration = perItemExpiration is null ? null : TimeSpan.FromMinutes(perItemExpiration.GetValueOrDefault()), 612LocalCacheExpiration = perItemLocalCacheExpiration is null ? null : TimeSpan.FromMinutes(perItemLocalCacheExpiration.GetValueOrDefault()),
SizeTests.cs (4)
38options.MaximumKeyLength = maximumKeyLength.GetValueOrDefault(); 43options.MaximumPayloadBytes = maximumPayloadBytes.GetValueOrDefault(); 107options.MaximumKeyLength = maximumKeyLength.GetValueOrDefault(); 112options.MaximumPayloadBytes = maximumPayloadBytes.GetValueOrDefault();
Microsoft.Extensions.Caching.Memory (3)
CacheEntry.cs (3)
84DateTimeOffset expiration = value.GetValueOrDefault(); 109_absoluteExpirationRelativeToNow = value.GetValueOrDefault(); 130_slidingExpiration = value.GetValueOrDefault();
Microsoft.Extensions.Caching.StackExchangeRedis (6)
RedisCache.cs (6)
188var setTtl = batch.KeyExpireAsync(prefixedKey, TimeSpan.FromSeconds(ttl.GetValueOrDefault())); 237cache.KeyExpireAsync(prefixedKey, TimeSpan.FromSeconds(ttl.GetValueOrDefault())) 416Refresh(cache, key, absExpr, sldExpr.GetValueOrDefault()); 455await RefreshAsync(cache, key, absExpr, sldExpr.GetValueOrDefault(), token).ConfigureAwait(false); 734Refresh(cache, key, absExpr, sldExpr.GetValueOrDefault()); 781await RefreshAsync(cache, key, absExpr, sldExpr.GetValueOrDefault(), token).ConfigureAwait(false);
Microsoft.Extensions.DataIngestion (1)
Chunkers\HeaderChunker.cs (1)
51int headerLevel = header.Level.GetValueOrDefault();
Microsoft.Extensions.DataIngestion.Tests (1)
IngestionPipelineTests.cs (1)
182content: new(image.Content.GetValueOrDefault(), image.MediaType!),
Microsoft.Extensions.VectorData.Abstractions (1)
RecordAttributes\VectorStoreKeyAttribute.cs (1)
35get => IsAutoGeneratedNullable.GetValueOrDefault();
Microsoft.ML.CodeGenerator (4)
Utils.cs (4)
105if (Single.IsNaN(f.GetValueOrDefault())) 110if (Single.IsPositiveInfinity(f.GetValueOrDefault())) 115if (Single.IsNegativeInfinity(f.GetValueOrDefault())) 126return f.GetValueOrDefault() ? "true" : "false";
Microsoft.ML.Core (3)
Data\ProgressReporter.cs (1)
89if (Double.IsNaN(lim.GetValueOrDefault()))
Utilities\Random.cs (2)
54return Create(seed.GetValueOrDefault()); 67return Create(seed.GetValueOrDefault());
Microsoft.ML.Data (4)
Data\SchemaDefinition.cs (1)
445itemType = new KeyDataViewType(dataType, keyAttr.KeyCount.Count.GetValueOrDefault());
DataLoadSave\Database\DatabaseLoader.cs (1)
694keyType = new KeyDataViewType(rawType, keyCount.Count.GetValueOrDefault());
Transforms\SkipTakeFilter.cs (1)
201long afterSkip = count.GetValueOrDefault() - _skip;
Utilities\TypeParsingUtils.cs (1)
66keyType = new KeyDataViewType(rawType, keyCount.Count.GetValueOrDefault());
Microsoft.ML.Mkl.Components (1)
VectorWhitening.cs (1)
249return rows.GetValueOrDefault();
Microsoft.ML.OnnxTransformer (6)
OnnxUtils.cs (6)
212sessionOptions.InterOpNumThreads = interOpNumThreads.HasValue ? interOpNumThreads.GetValueOrDefault() : onnxSessionOptions.InterOpNumThreads; 213sessionOptions.IntraOpNumThreads = intraOpNumThreads.HasValue ? intraOpNumThreads.GetValueOrDefault() : onnxSessionOptions.IntraOpNumThreads; 224sessionOptions.InterOpNumThreads = interOpNumThreads.HasValue ? interOpNumThreads.GetValueOrDefault() : onnxSessionOptions.InterOpNumThreads; 225sessionOptions.IntraOpNumThreads = intraOpNumThreads.HasValue ? intraOpNumThreads.GetValueOrDefault() : onnxSessionOptions.IntraOpNumThreads; 239sessionOptions.InterOpNumThreads = interOpNumThreads.HasValue ? interOpNumThreads.GetValueOrDefault() : onnxSessionOptions.InterOpNumThreads; 240sessionOptions.IntraOpNumThreads = intraOpNumThreads.HasValue ? intraOpNumThreads.GetValueOrDefault() : onnxSessionOptions.IntraOpNumThreads;
Microsoft.ML.Transforms (4)
Dracula\CountTableTransformer.cs (4)
137var labelColumnType = labelCol.GetValueOrDefault().Type; 138var labelClassNames = InitLabelClassNames(_host, labelCol.GetValueOrDefault(), labelCardinality); 148inputColumns[i] = col.GetValueOrDefault(); 168TrainTables(input, cols, multiBuilder, labelCol.GetValueOrDefault());
Microsoft.Net.Http.Headers (36)
CacheControlHeaderValue.cs (8)
355sb.Append(((int)_maxAge.GetValueOrDefault().TotalSeconds).ToString(NumberFormatInfo.InvariantInfo)); 362sb.Append(((int)_sharedMaxAge.GetValueOrDefault().TotalSeconds).ToString(NumberFormatInfo.InvariantInfo)); 371sb.Append(((int)_maxStaleLimit.GetValueOrDefault().TotalSeconds).ToString(NumberFormatInfo.InvariantInfo)); 379sb.Append(((int)_minFresh.GetValueOrDefault().TotalSeconds).ToString(NumberFormatInfo.InvariantInfo)); 451result = result ^ (_maxAge.HasValue ? _maxAge.GetValueOrDefault().GetHashCode() ^ 1 : 0) ^ 452(_sharedMaxAge.HasValue ? _sharedMaxAge.GetValueOrDefault().GetHashCode() ^ 2 : 0) ^ 453(_maxStaleLimit.HasValue ? _maxStaleLimit.GetValueOrDefault().GetHashCode() ^ 4 : 0) ^ 454(_minFresh.HasValue ? _minFresh.GetValueOrDefault().GetHashCode() ^ 8 : 0);
ContentDispositionHeaderValue.cs (3)
185sizeParameter.Value = value.GetValueOrDefault().ToString(CultureInfo.InvariantCulture); 189var sizeString = value.GetValueOrDefault().ToString(CultureInfo.InvariantCulture); 386var dateString = HeaderUtilities.FormatDate(date.GetValueOrDefault(), quoted: true);
ContentRangeHeaderValue.cs (3)
182sb.Append(From.GetValueOrDefault().ToString(NumberFormatInfo.InvariantInfo)); 184sb.Append(To.GetValueOrDefault().ToString(NumberFormatInfo.InvariantInfo)); 194sb.Append(Length.GetValueOrDefault().ToString(NumberFormatInfo.InvariantInfo));
RangeConditionHeaderValue.cs (4)
76return HeaderUtilities.FormatDate(_lastModified.GetValueOrDefault()); 93return (other._lastModified != null) && (_lastModified.GetValueOrDefault() == other._lastModified.GetValueOrDefault()); 104return _lastModified.GetValueOrDefault().GetHashCode();
RangeItemHeaderValue.cs (12)
33if (from.HasValue && (from.GetValueOrDefault() < 0)) 37if (to.HasValue && (to.GetValueOrDefault() < 0)) 41if (from.HasValue && to.HasValue && (from.GetValueOrDefault() > to.GetValueOrDefault())) 71return "-" + _to.GetValueOrDefault().ToString(NumberFormatInfo.InvariantInfo); 75return _from.GetValueOrDefault().ToString(NumberFormatInfo.InvariantInfo) + "-"; 77return _from.GetValueOrDefault().ToString(NumberFormatInfo.InvariantInfo) + "-" + 78_to.GetValueOrDefault().ToString(NumberFormatInfo.InvariantInfo); 92return _to.GetValueOrDefault().GetHashCode(); 96return _from.GetValueOrDefault().GetHashCode(); 98return _from.GetValueOrDefault().GetHashCode() ^ _to.GetValueOrDefault().GetHashCode();
SetCookieHeaderValue.cs (3)
203maxAge = HeaderUtilities.FormatInt64((long)MaxAge.GetValueOrDefault().TotalSeconds); 345AppendSegment(builder, ExpiresToken, HeaderUtilities.FormatDate(Expires.GetValueOrDefault())); 350AppendSegment(builder, MaxAgeToken, HeaderUtilities.FormatInt64((long)MaxAge.GetValueOrDefault().TotalSeconds));
StringWithQualityHeaderValue.cs (3)
73return _value + "; q=" + _quality.GetValueOrDefault().ToString("0.0##", NumberFormatInfo.InvariantInfo); 99return other._quality.HasValue && (_quality.GetValueOrDefault() == other._quality.Value); 114result = result ^ _quality.GetValueOrDefault().GetHashCode();
Microsoft.NET.ProjectData.Generators (2)
DataModelSchemaGenerator.cs (2)
90 $"the file does not contain valid JSON (line {ex.LineNumber.GetValueOrDefault() + 1}, byte {ex.BytePositionInLine.GetValueOrDefault() + 1}).");
Mono.Cecil (1)
Mono.Cecil\AssemblyWriter.cs (1)
2885 low_bounds [i] = dimension.LowerBound.GetValueOrDefault ();
Mono.Cecil.Rocks (1)
Mono.Cecil.Rocks\DocCommentId.cs (1)
198 id.Append (dimension.UpperBound.Value - (dimension.LowerBound.GetValueOrDefault () + 1));
NuGet.Packaging (3)
Signing\Timestamp\Accuracy.cs (3)
90return Seconds.GetValueOrDefault() * 1_000_000L + 91Milliseconds.GetValueOrDefault() * 1_000L + 92Microseconds.GetValueOrDefault();
Roslyn.Diagnostics.Analyzers (15)
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (4)
141=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 144=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedHashSet`1.cs (4)
102=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 105=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\Dependencies\Collections\Segmented\ImmutableSegmentedList`1.cs (4)
121=> left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 124=> !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
src\roslyn\src\RoslynAnalyzers\Utilities\Compiler\CodeMetrics\CodeAnalysisMetricData.AssemblyMetricData.cs (1)
57depthOfInheritance = Math.Max(child.DepthOfInheritance.GetValueOrDefault(), depthOfInheritance);
src\roslyn\src\RoslynAnalyzers\Utilities\Compiler\CodeMetrics\CodeAnalysisMetricData.NamespaceMetricData.cs (1)
55depthOfInheritance = Math.Max(child.DepthOfInheritance.GetValueOrDefault(), depthOfInheritance);
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.TypeParameterSymbolKey.cs (1)
47return resolution.GetValueOrDefault();
Roslyn.Diagnostics.CSharp.Analyzers (1)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\NewLineUserSettingFormattingRule.cs (1)
51switch (parentKind.GetValueOrDefault())
rzc (2)
Json\NullableExtensions.cs (2)
51return value.GetValueOrDefault(); 64return value.GetValueOrDefault();
System.Collections.Immutable (4)
System\Collections\Immutable\ImmutableArray_1.Minimal.cs (4)
99return left.GetValueOrDefault().Equals(right.GetValueOrDefault()); 110return !left.GetValueOrDefault().Equals(right.GetValueOrDefault());
System.ComponentModel.Annotations (3)
System\ComponentModel\DataAnnotations\DisplayAttribute.cs (3)
215return _autoGenerateField.GetValueOrDefault(); 244return _autoGenerateFilter.GetValueOrDefault(); 272return _order.GetValueOrDefault();
System.Data.Common (7)
System\Data\SQLTypes\SQLGuid.cs (7)
93return _value.GetValueOrDefault().ToByteArray(); 101return _value.GetValueOrDefault().ToString(); 123bool xWrote = x._value.GetValueOrDefault().TryWriteBytes(xBytes); 127bool yWrote = y._value.GetValueOrDefault().TryWriteBytes(yBytes); 163new SqlBoolean(x._value.GetValueOrDefault() == y._value.GetValueOrDefault()); 318writer.WriteString(XmlConvert.ToString(_value.GetValueOrDefault()));
System.Linq (33)
System\Linq\Average.cs (4)
148TAccumulator sum = TAccumulator.CreateChecked(value.GetValueOrDefault()); 156checked { sum += TAccumulator.CreateChecked(value.GetValueOrDefault()); } 244TAccumulator sum = TAccumulator.CreateChecked(value.GetValueOrDefault()); 252checked { sum += TAccumulator.CreateChecked(value.GetValueOrDefault()); }
System\Linq\Max.cs (16)
60T valueVal = value.GetValueOrDefault(); 72T x = cur.GetValueOrDefault(); 85T x = cur.GetValueOrDefault(); 196T valueVal = value.GetValueOrDefault(); 207valueVal = (value = cur).GetValueOrDefault(); 214T x = cur.GetValueOrDefault(); 296decimal valueVal = value.GetValueOrDefault(); 300decimal x = cur.GetValueOrDefault(); 602TResult valueVal = value.GetValueOrDefault(); 614TResult x = cur.GetValueOrDefault(); 627TResult x = cur.GetValueOrDefault(); 717TResult valueVal = value.GetValueOrDefault(); 728valueVal = (value = cur).GetValueOrDefault(); 735TResult x = cur.GetValueOrDefault(); 806decimal valueVal = value.GetValueOrDefault(); 810decimal x = cur.GetValueOrDefault();
System\Linq\Min.cs (12)
64T valueVal = value.GetValueOrDefault(); 68T x = cur.GetValueOrDefault(); 181T valueVal = value.GetValueOrDefault(); 192T x = cur.GetValueOrDefault(); 275decimal valueVal = value.GetValueOrDefault(); 279decimal x = cur.GetValueOrDefault(); 585TResult valueVal = value.GetValueOrDefault(); 589TResult x = cur.GetValueOrDefault(); 686TResult valueVal = value.GetValueOrDefault(); 697TResult x = cur.GetValueOrDefault(); 770decimal valueVal = value.GetValueOrDefault(); 774decimal x = cur.GetValueOrDefault();
System\Linq\Sum.cs (1)
199checked { sum += TAccumulator.CreateChecked(value.GetValueOrDefault()); }
System.Linq.AsyncEnumerable (7)
System\Linq\MinAsync.cs (2)
228if (value == null || x < value || float.IsNaN(x.GetValueOrDefault())) 253if (value == null || x < value || double.IsNaN(x.GetValueOrDefault()))
System\Linq\SumAsync.cs (5)
162checked { sum += item.GetValueOrDefault(); } 191checked { sum += item.GetValueOrDefault(); } 219sum += item.GetValueOrDefault(); 247sum += item.GetValueOrDefault(); 275sum += item.GetValueOrDefault();
System.Linq.Expressions (8)
System\Linq\Expressions\Interpreter\LightCompiler.cs (8)
2292_instructions.EmitStoreLocal(objTmp.GetValueOrDefault().Index); 2330_instructions.EmitStoreLocal(memberTemp.GetValueOrDefault().Index); 3216object? obj = _object == null ? null : frame.Data[_object.GetValueOrDefault().Index]; 3224locals.UndefineLocal(_object.GetValueOrDefault(), instructions.Count); 3243object? obj = _object == null ? null : frame.Data[_object.GetValueOrDefault().Index]; 3260locals.UndefineLocal(_object.GetValueOrDefault(), instructions.Count); 3288object? instance = _obj == null ? null : frame.Data[_obj.GetValueOrDefault().Index]; 3305locals.UndefineLocal(_obj.GetValueOrDefault(), instructions.Count);
System.Linq.Parallel (25)
System\Linq\Parallel\QueryOperators\Inlined\NullableDecimalAverageAggregationOperator.cs (1)
123sum += current.GetValueOrDefault();
System\Linq\Parallel\QueryOperators\Inlined\NullableDecimalSumAggregationOperator.cs (2)
49sum += enumerator.Current.GetValueOrDefault(); 108tempSum += element.GetValueOrDefault();
System\Linq\Parallel\QueryOperators\Inlined\NullableDoubleAverageAggregationOperator.cs (1)
123sum += current.GetValueOrDefault();
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\Linq\Parallel\QueryOperators\Inlined\NullableDoubleSumAggregationOperator.cs (2)
49sum += enumerator.Current.GetValueOrDefault(); 108tempSum += element.GetValueOrDefault();
System\Linq\Parallel\QueryOperators\Inlined\NullableFloatAverageAggregationOperator.cs (1)
124sum += current.GetValueOrDefault();
System\Linq\Parallel\QueryOperators\Inlined\NullableFloatMinMaxAggregationOperator.cs (4)
70if (best == null || current < best || float.IsNaN(current.GetValueOrDefault())) 82if (best == null || current > best || float.IsNaN(best.GetValueOrDefault())) 150if (currentElement == null || elem < currentElement || float.IsNaN(elem.GetValueOrDefault())) 165if (currentElement == null || elem > currentElement || float.IsNaN(currentElement.GetValueOrDefault()))
System\Linq\Parallel\QueryOperators\Inlined\NullableFloatSumAggregationOperator.cs (2)
49sum += enumerator.Current.GetValueOrDefault(); 108tempSum += element.GetValueOrDefault();
System\Linq\Parallel\QueryOperators\Inlined\NullableIntAverageAggregationOperator.cs (1)
124sum += current.GetValueOrDefault();
System\Linq\Parallel\QueryOperators\Inlined\NullableIntSumAggregationOperator.cs (2)
51sum += enumerator.Current.GetValueOrDefault(); 112tempSum += element.GetValueOrDefault();
System\Linq\Parallel\QueryOperators\Inlined\NullableLongAverageAggregationOperator.cs (1)
124sum += current.GetValueOrDefault();
System\Linq\Parallel\QueryOperators\Inlined\NullableLongSumAggregationOperator.cs (2)
51sum += enumerator.Current.GetValueOrDefault(); 114tempSum += element.GetValueOrDefault();
System\Linq\Parallel\QueryOperators\QueryOperator.cs (1)
153PartitionedStreamMerger<TOutput> merger = new PartitionedStreamMerger<TOutput>(forEffect, mergeOptions.GetValueOrDefault(),
System\Linq\Parallel\QueryOperators\ScanQueryOperator.cs (1)
63return new ListQueryResults<TElement>(dataAsList, settings.DegreeOfParallelism.GetValueOrDefault(), preferStriping);
System.Linq.Queryable (1)
System\Linq\TypeHelper.cs (1)
25if (definitionIsInterface.GetValueOrDefault())
System.Net.Http (37)
src\runtime\src\libraries\Common\src\System\Net\Http\aspnetcore\Http2\Hpack\HPackDecoder.cs (6)
198ReadOnlySpan<byte> headerBytes = data.Slice(_headerNameRange.GetValueOrDefault().start, _headerNameRange.GetValueOrDefault().length); 508: data.Slice(_headerValueRange.GetValueOrDefault().start, _headerValueRange.GetValueOrDefault().length); 523: data.Slice(_headerNameRange.GetValueOrDefault().start, _headerNameRange.GetValueOrDefault().length);
src\runtime\src\libraries\Common\src\System\Net\Http\aspnetcore\Http3\QPack\QPackDecoder.cs (6)
249ReadOnlySpan<byte> headerBytes = data.Slice(_headerNameRange.GetValueOrDefault().start, _headerNameRange.GetValueOrDefault().length); 595: data.Slice(_headerValueRange.GetValueOrDefault().start, _headerValueRange.GetValueOrDefault().length); 605: data.Slice(_headerNameRange.GetValueOrDefault().start, _headerNameRange.GetValueOrDefault().length);
System\Net\Http\Headers\AltSvcHeaderParser.cs (1)
140maxAge = Math.Min(maxAge.GetValueOrDefault(), maxAgeTmp);
System\Net\Http\Headers\CacheControlHeaderValue.cs (1)
61fieldRef = value.GetValueOrDefault();
System\Net\Http\Headers\ContentDispositionHeaderValue.cs (2)
109ArgumentOutOfRangeException.ThrowIfNegative(value.GetValueOrDefault()); 314string dateString = $"\"{date.GetValueOrDefault():r}\"";
System\Net\Http\Headers\HeaderUtilities.cs (1)
42double d = value.GetValueOrDefault();
System\Net\Http\Headers\KnownHeader.Http2And3.cs (2)
16HPackEncoder.EncodeLiteralHeaderFieldWithoutIndexingToAllocatedArray(http2StaticTableIndex.GetValueOrDefault()) : 20QPack.QPackEncoder.EncodeLiteralHeaderFieldWithStaticNameReferenceToArray(http3StaticTableIndex.GetValueOrDefault()) :
System\Net\Http\Headers\RangeHeaderValue.cs (2)
75if (range.From.HasValue) sb.AppendSpanFormattable(range.From.GetValueOrDefault()); 77if (range.To.HasValue) sb.AppendSpanFormattable(range.To.GetValueOrDefault());
System\Net\Http\Headers\RangeItemHeaderValue.cs (4)
29ArgumentOutOfRangeException.ThrowIfNegative(from.GetValueOrDefault(), nameof(from)); 33ArgumentOutOfRangeException.ThrowIfNegative(to.GetValueOrDefault(), nameof(to)); 37ArgumentOutOfRangeException.ThrowIfGreaterThan(from.GetValueOrDefault(), to.GetValueOrDefault(), nameof(from));
System\Net\Http\Headers\WarningHeaderValue.cs (1)
37_date = date.GetValueOrDefault();
System\Net\Http\HttpClient.cs (2)
210c.Headers.ContentLength.GetValueOrDefault(), 288c.Headers.ContentLength.GetValueOrDefault(),
System\Net\Http\HttpContent.cs (1)
621long contentLength = Headers.ContentLength.GetValueOrDefault();
System\Net\Http\SocketsHttpHandler\AuthenticationHelper.NtAuth.cs (1)
68if (response.Headers.ConnectionClose.GetValueOrDefault())
System\Net\Http\SocketsHttpHandler\ConnectionPool\HttpConnectionPool.Http3.cs (1)
697authorityMaxAge -= responseAge.GetValueOrDefault();
System\Net\Http\SocketsHttpHandler\Http3RequestStream.cs (1)
494long contentLength = content.Headers.ContentLength.GetValueOrDefault();
System\Net\Http\SocketsHttpHandler\HttpConnection.cs (4)
732(request.Content.Headers.ContentLength == null || request.Content.Headers.ContentLength.GetValueOrDefault() > Expect100ErrorSendThreshold) && 758if (response.Headers.ConnectionClose.GetValueOrDefault()) 820long contentLength = response.Content.Headers.ContentLength.GetValueOrDefault(); 953new ContentLengthWriteStream(this, request.Content.Headers.ContentLength.GetValueOrDefault());
System\Net\Http\SocketsHttpHandler\SocketsHttpHandler.cs (1)
716if (request.HasHeaders && request.Headers.TransferEncodingChunked.GetValueOrDefault())
System.Net.ServerSentEvents (2)
System\Net\ServerSentEvents\SseParser_1.cs (2)
124yield return sseItem.GetValueOrDefault(); 172yield return sseItem.GetValueOrDefault();
System.Net.Sockets (1)
System\Net\Sockets\TCPListener.cs (1)
283SetIPProtectionLevel(_allowNatTraversal.GetValueOrDefault());
System.Net.WebSockets (2)
System\Net\WebSockets\Compression\WebSocketInflater.cs (1)
187output[written] = _remainingByte.GetValueOrDefault();
System\Net\WebSockets\ManagedWebSocket.cs (1)
682headerLength = maskOffset.GetValueOrDefault() + MaskLength;
System.Private.CoreLib (10)
src\runtime\src\libraries\System.Private.CoreLib\src\System\TimeZoneInfo.Unix.cs (10)
723TimeSpan baseOffset = parsedBaseOffset.GetValueOrDefault().Negate(); // offsets are backwards in POSIX notation 738daylightSavingsTimeSpan = parsedDaylightSavings.GetValueOrDefault().Negate(); // offsets are backwards in POSIX notation 755dstStart.GetValueOrDefault(), 756dstEnd.GetValueOrDefault(), 809result = result.GetValueOrDefault().Negate(); 826timeOffset = new TimeSpan(timeOffset.GetValueOrDefault().Hours, timeOffset.GetValueOrDefault().Minutes, timeOffset.GetValueOrDefault().Seconds); 827if (timeOffset.GetValueOrDefault() < TimeSpan.Zero) 836timeOfDay += timeOffset.GetValueOrDefault();
System.Runtime.InteropServices (1)
System\Runtime\InteropServices\Marshalling\ComInterfaceMarshaller.cs (1)
82throw new InvalidCastException($"Unable to cast the provided managed object to a COM interface with ID '{TargetInterfaceIID.GetValueOrDefault():B}'");
System.Security.Cryptography (15)
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Asn1\PssParamsAsn.manual.cs (1)
44int saltSize = digestValueLength.GetValueOrDefault();
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs\Pkcs12Info.cs (1)
93authSafeBytes = signedData.EncapContentInfo.Content.GetValueOrDefault();
src\runtime\src\libraries\Common\src\System\Security\Cryptography\X509Certificates\Pkcs12LoaderLimits.cs (1)
395CheckNonNegative(value.GetValueOrDefault(), paramName);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\X509Certificates\X509CertificateLoader.cs (1)
645totalLength = decoded.GetValueOrDefault() + decodedLength + 1;
src\runtime\src\libraries\Common\src\System\Security\Cryptography\X509Certificates\X509CertificateLoader.Pkcs12.cs (1)
416attr.AttrValues[i] = providerName.GetValueOrDefault().AttrValues[0];
System\Security\Cryptography\X509Certificates\Asn1\TimeAsn.manual.cs (1)
27public DateTimeOffset GetValue() => (UtcTime ?? GeneralTime).GetValueOrDefault();
System\Security\Cryptography\X509Certificates\CertificateRevocationListBuilder.Build.cs (1)
358Helpers.ValidateDer(signatureAlgorithmAsn.Parameters.GetValueOrDefault().Span);
System\Security\Cryptography\X509Certificates\CertificateRevocationListBuilder.cs (1)
155X509RevocationReason reasonValue = reason.GetValueOrDefault();
System\Security\Cryptography\X509Certificates\FindPal.Windows.cs (1)
464if (!verified.GetValueOrDefault())
System\Security\Cryptography\X509Certificates\X500DistinguishedNameBuilder.cs (1)
395return stringEncodingType.GetValueOrDefault();
System\Security\Cryptography\X509Certificates\X509AuthorityKeyIdentifierExtension.cs (1)
560decoded.DirectoryName.GetValueOrDefault().Span);
System\Security\Cryptography\X509Certificates\X509BasicConstraintsExtension.cs (2)
90pathLengthConstraint.GetValueOrDefault(), 171pathLengthConstraint = constraints.PathLengthConstraint.GetValueOrDefault();
System\Security\Cryptography\X509Certificates\X509SubjectAlternativeNameExtension.cs (2)
98ReadOnlySpan<byte> value = item.IPAddress.GetValueOrDefault().Span; 124switch (item.IPAddress.GetValueOrDefault().Length)
System.Security.Cryptography.Cose (3)
System\Security\Cryptography\Cose\CoseMessage.cs (1)
359List<CoseSignature> signatures = new List<CoseSignature>(signaturesLength.GetValueOrDefault());
System\Security\Cryptography\Cose\CoseMultiSignMessage.cs (1)
602CoseHelpers.WriteContent(writer, Content.GetValueOrDefault().Span, !Content.HasValue);
System\Security\Cryptography\Cose\CoseSign1Message.cs (1)
1018CoseHelpers.WriteContent(writer, Content.GetValueOrDefault().Span, !Content.HasValue);
System.Security.Cryptography.Pkcs (7)
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Asn1\PssParamsAsn.manual.cs (1)
44int saltSize = digestValueLength.GetValueOrDefault();
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs\Pkcs12Info.cs (1)
93authSafeBytes = signedData.EncapContentInfo.Content.GetValueOrDefault();
System\Security\Cryptography\Pkcs\Asn1\Rfc3161Accuracy.manual.cs (3)
511_000_000L * Seconds.GetValueOrDefault() + 521000L * Millis.GetValueOrDefault() + 53Micros.GetValueOrDefault();
System\Security\Cryptography\Pkcs\Rfc3161TimestampRequest.cs (2)
123resp.Status.FailInfo.GetValueOrDefault())); 130if (!Rfc3161TimestampToken.TryDecode(resp.TimeStampToken.GetValueOrDefault(), out token, out _))
System.Text.RegularExpressions (3)
System\Text\RegularExpressions\RegexFindOptimizations.cs (2)
664(char low, char high) = primarySet.Range.GetValueOrDefault(); 820(RegexNode loopNode, (char Char, string? String, StringComparison StringComparison, char[]? Chars) literal) = LiteralAfterLoop.GetValueOrDefault();
System\Text\RegularExpressions\Symbolic\BitVector.cs (1)
183return _hashcode.GetValueOrDefault();