Skip to content

Commit

Permalink
API diff between .NET 10 Preview1 and .NET 10 Preview2 (#9771)
Browse files Browse the repository at this point in the history
* Readme
* AspNetCore
* NETCore
* WindowsDesktop
* Fix table of contents title, sort the assemblies
* Updated the tool to remove method and property bodies as requested. Also removed private dummy fields.
* Fix the fully qualified names
  • Loading branch information
carlossanlop authored Mar 10, 2025
1 parent c0fdf08 commit b771197
Show file tree
Hide file tree
Showing 15 changed files with 244 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# API difference between .NET 10.0 Preview 1 and .NET 10.0 Preview 2

API listing follows standard diff formatting.
Lines preceded by a '+' are additions and a '-' indicates removal.

* [Microsoft.AspNetCore.Components.Web](10.0-preview2_Microsoft.AspNetCore.Components.Web.md)
* [Microsoft.Extensions.Identity.Core](10.0-preview2_Microsoft.Extensions.Identity.Core.md)

Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Microsoft.AspNetCore.Components.Web

```diff
namespace Microsoft.AspNetCore.Components.Routing
{
public class NavLink : Microsoft.AspNetCore.Components.ComponentBase
{
+ protected virtual bool ShouldMatch(string currentUriAbsolute);
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Microsoft.Extensions.Identity.Core

```diff
namespace Microsoft.AspNetCore.Identity
{
public class UserLoginInfo
{
- public UserLoginInfo(string loginProvider, string providerKey, string? displayName);
+ public UserLoginInfo(string loginProvider, string providerKey, string? providerDisplayName);
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# API difference between .NET 10.0 Preview 1 and .NET 10.0 Preview 2

API listing follows standard diff formatting.
Lines preceded by a '+' are additions and a '-' indicates removal.

* [System.Collections.Immutable](10.0-preview2_System.Collections.Immutable.md)
* [System.Linq](10.0-preview2_System.Linq.md)
* [System.Linq.AsyncEnumerable](10.0-preview2_System.Linq.AsyncEnumerable.md)
* [System.Linq.Queryable](10.0-preview2_System.Linq.Queryable.md)
* [System.Numerics.Vectors](10.0-preview2_System.Numerics.Vectors.md)
* [System.Reflection.Metadata](10.0-preview2_System.Reflection.Metadata.md)
* [System.Runtime](10.0-preview2_System.Runtime.md)

Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# System.Collections.Immutable

```diff
namespace System.Runtime.InteropServices
{
public static class ImmutableCollectionsMarshal
{
+ public static System.Memory<T> AsMemory<T>(System.Collections.Immutable.ImmutableArray<T>.Builder? builder);
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# System.Linq.AsyncEnumerable

```diff
namespace System.Linq
{
public static class AsyncEnumerable
{
+ public static System.Collections.Generic.IAsyncEnumerable<TSource> Shuffle<TSource>(this System.Collections.Generic.IAsyncEnumerable<TSource> source);
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# System.Linq.Queryable

```diff
namespace System.Linq
{
public static class Queryable
{
+ public static System.Linq.IQueryable<TSource> Shuffle<TSource>(this System.Linq.IQueryable<TSource> source);
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# System.Linq

```diff
namespace System.Linq
{
public static class Enumerable
{
+ public static System.Collections.Generic.IEnumerable<TSource> Shuffle<TSource>(this System.Collections.Generic.IEnumerable<TSource> source);
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# System.Numerics.Vectors

```diff
namespace System.Numerics
{
public struct Vector2 : System.IEquatable<System.Numerics.Vector2>, System.IFormattable
{
+ public static float Cross(System.Numerics.Vector2 value1, System.Numerics.Vector2 value2);
}
public struct Vector4 : System.IEquatable<System.Numerics.Vector4>, System.IFormattable
{
+ public static System.Numerics.Vector4 Cross(System.Numerics.Vector4 vector1, System.Numerics.Vector4 vector2);
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# System.Reflection.Metadata

```diff
namespace System.Reflection.Metadata
{
public readonly struct EventDefinition
{
+ public readonly System.Reflection.Metadata.TypeDefinitionHandle GetDeclaringType();
}
public readonly struct PropertyDefinition
{
+ public readonly System.Reflection.Metadata.TypeDefinitionHandle GetDeclaringType();
}
public sealed class TypeName
{
+ public static string Unescape(string name);
+ public string Namespace { get; }
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# System.Runtime

```diff
namespace System.Runtime.CompilerServices
{
public sealed class ConditionalWeakTable<TKey, TValue> : System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<TKey, TValue>>, System.Collections.IEnumerable where TKey : class where TValue : class
{
+ [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
public TValue GetOrCreateValue(TKey key);
+ [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
public TValue GetValue(TKey key, System.Runtime.CompilerServices.ConditionalWeakTable<TKey, TValue>.CreateValueCallback createValueCallback);
+ [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
public delegate TValue CreateValueCallback(TKey key);
+ public TValue GetOrAdd(TKey key, TValue value);
+ public TValue GetOrAdd(TKey key, System.Func<TKey, TValue> valueFactory);
+ public TValue GetOrAdd<TArg>(TKey key, System.Func<TKey, TArg, TValue> valueFactory, TArg factoryArgument);
}
}
namespace System.Runtime.InteropServices
{
+ public struct GCHandle<T> : System.IDisposable, System.IEquatable<System.Runtime.InteropServices.GCHandle<T>> where T : class
+ {
+ public GCHandle(T target);
+ public void Dispose();
+ public override readonly bool Equals(object? obj);
+ public readonly bool Equals(System.Runtime.InteropServices.GCHandle<T> other);
+ public static System.Runtime.InteropServices.GCHandle<T> FromIntPtr(nint value);
+ public override readonly int GetHashCode();
+ public static nint ToIntPtr(System.Runtime.InteropServices.GCHandle<T> value);
+ public bool IsAllocated { get; }
+ public T Target { get; set; }
+ }
+ public static class GCHandleExtensions
+ {
+ [System.CLSCompliantAttribute(false)]
+ public static unsafe T* GetAddressOfArrayData<T>(this System.Runtime.InteropServices.PinnedGCHandle<T[]> handle);
+ [System.CLSCompliantAttribute(false)]
+ public static unsafe char* GetAddressOfStringData(this System.Runtime.InteropServices.PinnedGCHandle<string> handle);
+ }
+ public struct PinnedGCHandle<T> : System.IDisposable, System.IEquatable<System.Runtime.InteropServices.PinnedGCHandle<T>> where T : class
+ {
+ public PinnedGCHandle(T target);
+ public void Dispose();
+ public override readonly bool Equals(object? obj);
+ public readonly bool Equals(System.Runtime.InteropServices.PinnedGCHandle<T> other);
+ public static System.Runtime.InteropServices.PinnedGCHandle<T> FromIntPtr(nint value);
+ [System.CLSCompliantAttribute(false)]
+ public readonly unsafe void* GetAddressOfObjectData();
+ public override readonly int GetHashCode();
+ public static nint ToIntPtr(System.Runtime.InteropServices.PinnedGCHandle<T> value);
+ public bool IsAllocated { get; }
+ public T Target { get; set; }
+ }
+ public struct WeakGCHandle<T> : System.IDisposable, System.IEquatable<System.Runtime.InteropServices.WeakGCHandle<T>> where T : class
+ {
+ public WeakGCHandle(T target, bool trackResurrection = false);
+ public void Dispose();
+ public override readonly bool Equals(object? obj);
+ public readonly bool Equals(System.Runtime.InteropServices.WeakGCHandle<T> other);
+ public static System.Runtime.InteropServices.WeakGCHandle<T> FromIntPtr(nint value);
+ public override readonly int GetHashCode();
+ public readonly void SetTarget(T target);
+ public static nint ToIntPtr(System.Runtime.InteropServices.WeakGCHandle<T> value);
+ public readonly bool TryGetTarget(out T? target);
+ public bool IsAllocated { get; }
+ }
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# API difference between .NET 10.0 Preview 1 and .NET 10.0 Preview 2

API listing follows standard diff formatting.
Lines preceded by a '+' are additions and a '-' indicates removal.

* [System.Windows.Forms](10.0-preview2_System.Windows.Forms.md)
* [System.Windows.Forms.Design](10.0-preview2_System.Windows.Forms.Design.md)

Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# System.Windows.Forms.Design

```diff
namespace System.ComponentModel.Design
{
public class ArrayEditor : System.ComponentModel.Design.CollectionEditor
{
- protected override object[] GetItems(object editValue);
- protected override object SetItems(object editValue, object[] value);
+ protected override object[] GetItems(object? editValue);
+ protected override object? SetItems(object? editValue, object[]? value);
}
}
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# System.Windows.Forms

```diff
namespace System.Windows.Forms
{
public static class Clipboard
{
- public static bool TryGetData<T>(string format, System.Func<System.Reflection.Metadata.TypeName, System.Type> resolver, out T data);
+ public static bool TryGetData<T>(string format, System.Func<System.Reflection.Metadata.TypeName, System.Type?> resolver, out T data);
}
public class DataObject : System.Windows.Forms.ITypedDataObject, System.Windows.Forms.IDataObject
{
- public bool TryGetData<T>(string format, System.Func<System.Reflection.Metadata.TypeName, System.Type> resolver, bool autoConvert, out T data);
- protected virtual bool TryGetDataCore<T>(string format, System.Func<System.Reflection.Metadata.TypeName, System.Type>? resolver, bool autoConvert, out T data);
+ public bool TryGetData<T>(string format, System.Func<System.Reflection.Metadata.TypeName, System.Type?> resolver, bool autoConvert, out T data);
+ protected virtual bool TryGetDataCore<T>(string format, System.Func<System.Reflection.Metadata.TypeName, System.Type?>? resolver, bool autoConvert, out T data);
}
public static class DataObjectExtensions
{
- public static bool TryGetData<T>(this System.Windows.Forms.IDataObject dataObject, string format, System.Func<System.Reflection.Metadata.TypeName, System.Type> resolver, bool autoConvert, out T data);
+ public static bool TryGetData<T>(this System.Windows.Forms.IDataObject dataObject, string format, System.Func<System.Reflection.Metadata.TypeName, System.Type?> resolver, bool autoConvert, out T data);
}
}
```
7 changes: 7 additions & 0 deletions release-notes/10.0/preview/preview2/api-diff/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# .NET 10.0 Preview 2 API Changes

The following API changes were made in .NET 10.0 Preview 2:

- [Microsoft.NETCore.App](./Microsoft.NETCore.App/10.0-preview2.md)
- [Microsoft.AspNetCore.App](./Microsoft.AspNetCore.App/10.0-preview2.md)
- [Microsoft.WindowsDesktop.App](./Microsoft.WindowsDesktop.App/10.0-preview2.md)

0 comments on commit b771197

Please sign in to comment.