-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Extract non-generic members from frequently used generic types (#16585)
* Extract EffectiveValue notification methods to reduce code size * Extract non-generic members from frequently used generic types
- Loading branch information
Showing
11 changed files
with
165 additions
and
77 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
src/Avalonia.Base/PropertyStore/BindingEntryBaseNonGenericHelper.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
using System; | ||
using Avalonia.Reactive; | ||
|
||
namespace Avalonia.PropertyStore; | ||
|
||
/// <summary> | ||
/// Contains fields for <see cref="BindingEntryBase{TValue,TSource}"/> that aren't using generic arguments. | ||
/// Separated to avoid unnecessary generic instantiations. | ||
/// </summary> | ||
internal static class BindingEntryBaseNonGenericHelper | ||
{ | ||
public static readonly IDisposable Creating = Disposable.Empty; | ||
public static readonly IDisposable CreatingQuiet = Disposable.Create(() => { }); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
src/Avalonia.Base/Reactive/AnonymousObserverNonGenericHelper.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
using System; | ||
|
||
namespace Avalonia.Reactive; | ||
|
||
/// <summary> | ||
/// Contains fields for <see cref="AnonymousObserver{T}"/> that aren't using generic arguments. | ||
/// Separated to avoid unnecessary generic instantiations. | ||
/// </summary> | ||
internal static class AnonymousObserverNonGenericHelper | ||
{ | ||
public static readonly Action<Exception> ThrowsOnError = ex => throw ex; | ||
public static readonly Action NoOpCompleted = () => { }; | ||
} |
Oops, something went wrong.