Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[repo] Remove #nullable enable #2290

Merged
merged 2 commits into from
Nov 4, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Remove #nullable enable
Kielek committed Nov 4, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
commit efea6c419794a85192d31af270e40cae0b70657b
2 changes: 0 additions & 2 deletions src/OpenTelemetry.Instrumentation.Process/ProcessMetrics.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics.Metrics;
using System.Reflection;
using OpenTelemetry.Internal;
2 changes: 0 additions & 2 deletions src/Shared/ActivityHelperExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
using System.Runtime.CompilerServices;

2 changes: 0 additions & 2 deletions src/Shared/ActivityInstrumentationHelper.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;

namespace OpenTelemetry.Instrumentation;
2 changes: 0 additions & 2 deletions src/Shared/AssemblyVersionExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
using System.Reflection;

2 changes: 0 additions & 2 deletions src/Shared/Configuration/IConfigurationExtensionsLogger.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

namespace Microsoft.Extensions.Configuration;

internal interface IConfigurationExtensionsLogger
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
#if NET || NETSTANDARD2_1
using System.Diagnostics.CodeAnalysis;
2 changes: 0 additions & 2 deletions src/Shared/DatabaseSemanticConventionHelper.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics.CodeAnalysis;
using Microsoft.Extensions.Configuration;

2 changes: 0 additions & 2 deletions src/Shared/DiagnosticSourceListener.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
using OpenTelemetry.Internal;

2 changes: 0 additions & 2 deletions src/Shared/DiagnosticSourceSubscriber.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
using OpenTelemetry.Internal;

2 changes: 0 additions & 2 deletions src/Shared/ExceptionExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Globalization;

namespace OpenTelemetry.Internal;
2 changes: 0 additions & 2 deletions src/Shared/GrpcStatusCanonicalCode.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

namespace OpenTelemetry.Instrumentation;

/// <summary>
2 changes: 0 additions & 2 deletions src/Shared/GrpcTagHelper.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
using System.Text.RegularExpressions;
using OpenTelemetry.Trace;
2 changes: 0 additions & 2 deletions src/Shared/Guard.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

// Note: For some targets this file will contain more than one type/namespace.
#pragma warning disable IDE0161 // Convert to file-scoped namespace

2 changes: 0 additions & 2 deletions src/Shared/ListenerHandler.cs
Original file line number Diff line number Diff line change
@@ -3,8 +3,6 @@

using System.Diagnostics;

#nullable enable

namespace OpenTelemetry.Instrumentation;

/// <summary>
2 changes: 0 additions & 2 deletions src/Shared/MultiTypePropertyFetcher.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Collections.Concurrent;
using System.Reflection;

Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
#if NET
using System.Diagnostics.CodeAnalysis;
2 changes: 0 additions & 2 deletions src/Shared/Options/SingletonOptionsManager.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

#if NET
using System.Diagnostics.CodeAnalysis;
#endif
2 changes: 0 additions & 2 deletions src/Shared/PropertyFetcher.AOT.cs
Original file line number Diff line number Diff line change
@@ -5,8 +5,6 @@
// Usages of the non-AOT-compatible version can be moved over to this one when they need to support AOT/trimming.
// Copied from https://github.com/open-telemetry/opentelemetry-dotnet/blob/86a6ba0b7f7ed1f5e84e5a6610e640989cd3ae9f/src/Shared/DiagnosticSourceInstrumentation/PropertyFetcher.cs#L30

#nullable enable

#if NETSTANDARD2_1_0_OR_GREATER || NET
using System.Diagnostics.CodeAnalysis;
#endif
2 changes: 0 additions & 2 deletions src/Shared/RedactionHelper.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Text;

namespace OpenTelemetry.Internal;
2 changes: 0 additions & 2 deletions src/Shared/RequestDataHelper.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

#if NET
using System.Collections.Frozen;
#endif
Original file line number Diff line number Diff line change
@@ -3,8 +3,6 @@

#if NET6_0_OR_GREATER

#nullable enable

using System.Diagnostics;
using System.Globalization;
using System.Text.RegularExpressions;
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
using OpenTelemetry.Exporter.Instana.Implementation;
using OpenTelemetry.Exporter.Instana.Implementation.Processors;
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Reflection;
using System.Text.Json;
using System.Text.Json.Serialization;
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Globalization;
using System.Text;
using Microsoft.AspNetCore.Builder;
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Text.Json;
using System.Text.Json.Serialization;
using RouteTests.TestApplication;
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
using OpenTelemetry;
using OpenTelemetry.Metrics;
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable
using System.Text.Json.Serialization;
using Microsoft.AspNetCore.Mvc.Abstractions;
using Microsoft.AspNetCore.Mvc.Controllers;
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable
using System.Text.Json.Serialization;

namespace RouteTests.TestApplication;
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable
using System.Text.Json.Serialization;

namespace RouteTests.TestApplication;
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Text.Json.Serialization;
using Microsoft.AspNetCore.Http;
#if NET
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc.Diagnostics;
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Diagnostics;
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable
using RouteTests.TestApplication;

namespace RouteTests;
2 changes: 0 additions & 2 deletions test/Shared/CustomTextMapPropagator.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;
using OpenTelemetry.Context.Propagation;

2 changes: 0 additions & 2 deletions test/Shared/EventSourceTestHelper.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics.Tracing;
using System.Globalization;
using System.Reflection;
2 changes: 0 additions & 2 deletions test/Shared/InMemoryEventListener.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Collections.Concurrent;
using System.Diagnostics.Tracing;

2 changes: 0 additions & 2 deletions test/Shared/PlatformHelpers.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

#pragma warning disable SA1649 // File name should match first type name
#pragma warning disable SA1402 // File may only contain a single type

2 changes: 0 additions & 2 deletions test/Shared/SkipUnlessEnvVarFoundFactAttribute.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using Xunit;

namespace OpenTelemetry.Tests;
2 changes: 0 additions & 2 deletions test/Shared/SkipUnlessEnvVarFoundTheoryAttribute.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using Xunit;

namespace OpenTelemetry.Tests;
2 changes: 0 additions & 2 deletions test/Shared/TestActivityExportProcessor.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;

namespace OpenTelemetry.Tests;
2 changes: 0 additions & 2 deletions test/Shared/TestActivityProcessor.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics;

namespace OpenTelemetry.Tests;
2 changes: 0 additions & 2 deletions test/Shared/TestEventListener.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using System.Diagnostics.Tracing;

namespace OpenTelemetry.Tests;
2 changes: 0 additions & 2 deletions test/Shared/TestHttpServer.cs
Original file line number Diff line number Diff line change
@@ -4,8 +4,6 @@
// Note: When implicit usings are enabled in a project this file will generate
// warnings/errors without this suppression.

#nullable enable

using System.Net;
#if !NETFRAMEWORK
using System.Security.Cryptography;
2 changes: 0 additions & 2 deletions test/Shared/TestSampler.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

#nullable enable

using OpenTelemetry.Trace;

namespace OpenTelemetry.Tests;
Loading