diff --git a/.editorconfig b/.editorconfig
index e3b598cca..42fdb0221 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -43,6 +43,19 @@ dotnet_diagnostic.CA2009.severity=error
dotnet_diagnostic.CA2008.severity=error
dotnet_diagnostic.CA2007.severity=warning
dotnet_diagnostic.CA2000.severity=suggestion
+dotnet_style_coalesce_expression = true:suggestion
+dotnet_style_null_propagation = true:suggestion
+dotnet_style_prefer_is_null_check_over_reference_equality_method = true:suggestion
+dotnet_style_prefer_auto_properties = true:silent
+dotnet_style_object_initializer = true:suggestion
+dotnet_style_collection_initializer = true:suggestion
+dotnet_style_prefer_simplified_boolean_expressions = true:suggestion
+dotnet_style_prefer_conditional_expression_over_assignment = true:silent
+dotnet_style_prefer_conditional_expression_over_return = true:silent
+dotnet_style_operator_placement_when_wrapping = beginning_of_line
+tab_width = 4
+end_of_line = crlf
+dotnet_style_explicit_tuple_names = true:suggestion
[project.json]
indent_size = 2
@@ -66,7 +79,7 @@ csharp_indent_braces = false
csharp_indent_case_contents = true
csharp_indent_case_contents_when_block = true
csharp_indent_switch_labels = true
-csharp_indent_labels = one_less_than_current
+csharp_indent_labels = no_change
# Modifier preferences
csharp_preferred_modifier_order = public,private,protected,internal,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,volatile,async:suggestion
@@ -117,13 +130,13 @@ dotnet_naming_style.camel_case_underscore_style.required_prefix = _
dotnet_naming_style.camel_case_underscore_style.capitalization = camel_case
# Code style defaults
-csharp_using_directive_placement = outside_namespace:suggestion
+csharp_using_directive_placement = outside_namespace:silent
dotnet_sort_system_directives_first = true
csharp_prefer_braces = true:silent
csharp_preserve_single_line_blocks = true:none
csharp_preserve_single_line_statements = false:none
csharp_prefer_static_local_function = true:suggestion
-csharp_prefer_simple_using_statement = false:none
+csharp_prefer_simple_using_statement = true:suggestion
csharp_style_prefer_switch_expression = true:suggestion
csharp_style_namespace_declarations = block_scoped:silent
csharp_style_prefer_method_group_conversion = true:silent
@@ -155,14 +168,14 @@ dotnet_style_prefer_simplified_interpolation = true:suggestion
dotnet_style_namespace_match_folder = true:suggestion
# Expression-bodied members
-csharp_style_expression_bodied_methods = true:suggestion
-csharp_style_expression_bodied_constructors = true:suggestion
-csharp_style_expression_bodied_operators = true:suggestion
-csharp_style_expression_bodied_properties = true:suggestion
-csharp_style_expression_bodied_indexers = true:suggestion
-csharp_style_expression_bodied_accessors = true:suggestion
-csharp_style_expression_bodied_lambdas = true:suggestion
-csharp_style_expression_bodied_local_functions = true:suggestion
+csharp_style_expression_bodied_methods = false:silent
+csharp_style_expression_bodied_constructors = false:silent
+csharp_style_expression_bodied_operators = false:silent
+csharp_style_expression_bodied_properties = true:silent
+csharp_style_expression_bodied_indexers = true:silent
+csharp_style_expression_bodied_accessors = true:silent
+csharp_style_expression_bodied_lambdas = true:silent
+csharp_style_expression_bodied_local_functions = false:silent
# Pattern matching
csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion
@@ -519,6 +532,7 @@ dotnet_diagnostic.RCS1195.severity=error
dotnet_diagnostic.RCS1214.severity=error
dotnet_diagnostic.IDE1006.severity=none
+csharp_prefer_system_threading_lock = true:suggestion
# C++ Files
[*.{cpp,h,in}]
diff --git a/src/Directory.Build.props b/src/Directory.Build.props
index 1b0d302cf..85a98f0e0 100644
--- a/src/Directory.Build.props
+++ b/src/Directory.Build.props
@@ -64,7 +64,7 @@
-
+
diff --git a/src/Directory.build.targets b/src/Directory.build.targets
index c03d9f4f1..f2fe77ec6 100644
--- a/src/Directory.build.targets
+++ b/src/Directory.build.targets
@@ -34,4 +34,7 @@
$(DefineConstants);NETSTANDARD;PORTABLE;P_LINQ;SUPPORTS_BINDINGLIST
+
+ $(DefineConstants);NETSTANDARD;PORTABLE;P_LINQ;SUPPORTS_BINDINGLIST
+
diff --git a/src/DynamicData.Tests/API/ApiApprovalTests.DynamicDataTests.DotNet9_0.verified.txt b/src/DynamicData.Tests/API/ApiApprovalTests.DynamicDataTests.DotNet9_0.verified.txt
new file mode 100644
index 000000000..e594d8a78
--- /dev/null
+++ b/src/DynamicData.Tests/API/ApiApprovalTests.DynamicDataTests.DotNet9_0.verified.txt
@@ -0,0 +1,3113 @@
+[assembly: System.Runtime.CompilerServices.InternalsVisibleTo("DynamicData.Profile")]
+[assembly: System.Runtime.CompilerServices.InternalsVisibleTo("DynamicData.ReactiveUI")]
+[assembly: System.Runtime.CompilerServices.InternalsVisibleTo("DynamicData.Tests")]
+[assembly: System.Runtime.Versioning.TargetFramework(".NETCoreApp,Version=v9.0", FrameworkDisplayName=".NET 9.0")]
+namespace DynamicData.Aggregation
+{
+ public readonly struct AggregateItem : System.IEquatable>
+ {
+ public AggregateItem(DynamicData.Aggregation.AggregateType type, TObject item) { }
+ public TObject Item { get; }
+ public DynamicData.Aggregation.AggregateType Type { get; }
+ public bool Equals(DynamicData.Aggregation.AggregateItem other) { }
+ public override bool Equals(object? obj) { }
+ public override int GetHashCode() { }
+ public static bool operator !=(in DynamicData.Aggregation.AggregateItem left, in DynamicData.Aggregation.AggregateItem right) { }
+ public static bool operator ==(in DynamicData.Aggregation.AggregateItem left, in DynamicData.Aggregation.AggregateItem right) { }
+ }
+ public enum AggregateType
+ {
+ Add = 0,
+ Remove = 1,
+ }
+ public static class AggregationEx
+ {
+ public static System.IObservable> ForAggregation(this System.IObservable> source)
+ where TObject : notnull { }
+ public static System.IObservable> ForAggregation(this System.IObservable> source)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable InvalidateWhen(this System.IObservable source, System.IObservable invalidate) { }
+ public static System.IObservable InvalidateWhen(this System.IObservable source, System.IObservable invalidate) { }
+ }
+ public static class AvgEx
+ {
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, [System.Runtime.CompilerServices.DecimalConstant(0, 0, 0u, 0u, 0u)] decimal emptyValue) { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, [System.Runtime.CompilerServices.DecimalConstant(0, 0, 0u, 0u, 0u)] decimal emptyValue) { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, double emptyValue = 0) { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, double emptyValue = 0) { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, float emptyValue = 0) { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, float emptyValue = 0) { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, int emptyValue = 0) { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, int emptyValue = 0) { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, long emptyValue = 0) { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, long emptyValue = 0) { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, [System.Runtime.CompilerServices.DecimalConstant(0, 0, 0u, 0u, 0u)] decimal emptyValue)
+ where T : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, [System.Runtime.CompilerServices.DecimalConstant(0, 0, 0u, 0u, 0u)] decimal emptyValue)
+ where T : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, double emptyValue = 0)
+ where T : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, double emptyValue = 0)
+ where T : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, float emptyValue = 0)
+ where T : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, float emptyValue = 0)
+ where T : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, int emptyValue = 0)
+ where T : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, int emptyValue = 0)
+ where T : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, long emptyValue = 0)
+ where T : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, long emptyValue = 0)
+ where T : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, [System.Runtime.CompilerServices.DecimalConstant(0, 0, 0u, 0u, 0u)] decimal emptyValue)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, [System.Runtime.CompilerServices.DecimalConstant(0, 0, 0u, 0u, 0u)] decimal emptyValue)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, double emptyValue = 0)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, double emptyValue = 0)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, float emptyValue = 0)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, float emptyValue = 0)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, int emptyValue = 0)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, int emptyValue = 0)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, long emptyValue = 0)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable Avg(this System.IObservable> source, System.Func valueSelector, long emptyValue = 0)
+ where TObject : notnull
+ where TKey : notnull { }
+ }
+ public static class CountEx
+ {
+ public static System.IObservable Count(this System.IObservable> source) { }
+ public static System.IObservable Count(this System.IObservable> source)
+ where TObject : notnull { }
+ public static System.IObservable Count(this System.IObservable> source)
+ where TObject : notnull { }
+ public static System.IObservable Count(this System.IObservable> source)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable IsEmpty(this System.IObservable> source)
+ where TObject : notnull { }
+ public static System.IObservable IsEmpty(this System.IObservable> source)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable IsNotEmpty(this System.IObservable> source)
+ where TObject : notnull { }
+ public static System.IObservable IsNotEmpty(this System.IObservable> source)
+ where TObject : notnull
+ where TKey : notnull { }
+ }
+ public interface IAggregateChangeSet : System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable { }
+ public static class MaxEx
+ {
+ public static System.IObservable Maximum(this System.IObservable> source, System.Func valueSelector, TResult emptyValue = default)
+ where TObject : notnull
+ where TResult : struct, System.IComparable { }
+ public static System.IObservable Maximum(this System.IObservable> source, System.Func valueSelector, TResult emptyValue = default)
+ where TObject : notnull
+ where TKey : notnull
+ where TResult : struct, System.IComparable { }
+ public static System.IObservable Minimum(this System.IObservable> source, System.Func valueSelector, TResult emptyValue = default)
+ where TObject : notnull
+ where TResult : struct, System.IComparable { }
+ public static System.IObservable Minimum(this System.IObservable> source, System.Func valueSelector, TResult emptyValue = default)
+ where TObject : notnull
+ where TKey : notnull
+ where TResult : struct, System.IComparable { }
+ }
+ public static class StdDevEx
+ {
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, [System.Runtime.CompilerServices.DecimalConstant(0, 0, 0u, 0u, 0u)] decimal fallbackValue) { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, double fallbackValue = 0) { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, float fallbackValue = 0) { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, int fallbackValue = 0) { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, long fallbackValue = 0) { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, decimal fallbackValue)
+ where T : notnull { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, double fallbackValue)
+ where T : notnull { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, float fallbackValue = 0)
+ where T : notnull { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, int fallbackValue)
+ where T : notnull { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, long fallbackValue)
+ where T : notnull { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, decimal fallbackValue)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, double fallbackValue)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, float fallbackValue = 0)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, int fallbackValue)
+ where TObject : notnull
+ where TKey : notnull { }
+ public static System.IObservable StdDev(this System.IObservable> source, System.Func valueSelector, long fallbackValue)
+ where TObject : notnull
+ where TKey : notnull { }
+ }
+ public static class SumEx
+ {
+ public static System.IObservable Sum(this System.IObservable> source, System.Func valueSelector) { }
+ public static System.IObservable Sum(this System.IObservable