@@ -33,7 +33,7 @@ public static partial class DebugCode
3333 [ Conditional ( DebugCondition ) , DebuggerHidden , MethodImpl ( AggressiveInlining ) ]
3434 [ AssertionMethod ]
3535 public static void NotNull < T > (
36- [ CanBeNull , NoEnumeration ] T arg ,
36+ [ CanBeNull , NoEnumeration , AssertionCondition ( AssertionConditionType . IS_NOT_NULL ) ] T arg ,
3737 [ NotNull , InvokerParameterName ] string argName ) where T : class
3838 {
3939 if ( arg == null )
@@ -47,7 +47,7 @@ public static void NotNull<T>(
4747 [ Conditional ( DebugCondition ) , DebuggerHidden , MethodImpl ( AggressiveInlining ) ]
4848 [ AssertionMethod ]
4949 public static void NotNull < T > (
50- [ CanBeNull ] T ? arg ,
50+ [ CanBeNull , AssertionCondition ( AssertionConditionType . IS_NOT_NULL ) ] T ? arg ,
5151 [ NotNull , InvokerParameterName ] string argName ) where T : struct
5252 {
5353 if ( arg == null )
@@ -87,7 +87,7 @@ public static void NotNullNorWhiteSpace(
8787 [ Conditional ( DebugCondition ) , DebuggerHidden , MethodImpl ( AggressiveInlining ) ]
8888 [ AssertionMethod ]
8989 public static void AssertArgument (
90- bool condition ,
90+ [ AssertionCondition ( AssertionConditionType . IS_TRUE ) ] bool condition ,
9191 [ NotNull , InvokerParameterName ] string argName ,
9292 [ NotNull ] string message )
9393 {
@@ -103,7 +103,7 @@ public static void AssertArgument(
103103 [ Conditional ( DebugCondition ) , DebuggerHidden , MethodImpl ( AggressiveInlining ) ]
104104 [ AssertionMethod , StringFormatMethod ( "messageFormat" ) ]
105105 public static void AssertArgument (
106- bool condition ,
106+ [ AssertionCondition ( AssertionConditionType . IS_TRUE ) ] bool condition ,
107107 [ NotNull , InvokerParameterName ] string argName ,
108108 [ NotNull ] string messageFormat ,
109109 [ CanBeNull ] params object [ ] args )
@@ -228,7 +228,7 @@ public static void ValidIndexAndCount(
228228 [ Conditional ( DebugCondition ) , DebuggerHidden , MethodImpl ( AggressiveInlining ) ]
229229 [ AssertionMethod ]
230230 public static void AssertState (
231- bool condition ,
231+ [ AssertionCondition ( AssertionConditionType . IS_TRUE ) ] bool condition ,
232232 [ NotNull ] string message )
233233 {
234234 if ( ! condition )
@@ -242,7 +242,7 @@ public static void AssertState(
242242 [ Conditional ( DebugCondition ) , DebuggerHidden , MethodImpl ( AggressiveInlining ) ]
243243 [ AssertionMethod , StringFormatMethod ( "messageFormat" ) ]
244244 public static void AssertState (
245- bool condition ,
245+ [ AssertionCondition ( AssertionConditionType . IS_TRUE ) ] bool condition ,
246246 [ NotNull ] string messageFormat ,
247247 [ CanBeNull ] params object [ ] args )
248248 {
0 commit comments