Skip to content

Commit

Permalink
AssertCondition in Code class
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewvk committed May 23, 2016
1 parent 8903692 commit b07d07a
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions Main/src/Assertions/Code.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public static partial class Code
[DebuggerHidden, MethodImpl(AggressiveInlining)]
[AssertionMethod]
public static void NotNull<T>(
[CanBeNull, NoEnumeration] T arg,
[CanBeNull, NoEnumeration, AssertionCondition(AssertionConditionType.IS_NOT_NULL)] T arg,
[NotNull, InvokerParameterName] string argName) where T : class
{
if (arg == null)
Expand All @@ -36,7 +36,7 @@ public static void NotNull<T>(
[DebuggerHidden, MethodImpl(AggressiveInlining)]
[AssertionMethod]
public static void NotNull<T>(
[CanBeNull] T? arg,
[CanBeNull, AssertionCondition(AssertionConditionType.IS_NOT_NULL)] T? arg,
[NotNull, InvokerParameterName] string argName) where T : struct
{
if (arg == null)
Expand Down Expand Up @@ -76,7 +76,7 @@ public static void NotNullNorWhiteSpace(
[DebuggerHidden, MethodImpl(AggressiveInlining)]
[AssertionMethod]
public static void AssertArgument(
bool condition,
[AssertionCondition(AssertionConditionType.IS_TRUE)] bool condition,
[NotNull, InvokerParameterName] string argName,
[NotNull] string message)
{
Expand All @@ -92,7 +92,7 @@ public static void AssertArgument(
[DebuggerHidden, MethodImpl(AggressiveInlining)]
[AssertionMethod, StringFormatMethod("messageFormat")]
public static void AssertArgument(
bool condition,
[AssertionCondition(AssertionConditionType.IS_TRUE)] bool condition,
[NotNull, InvokerParameterName] string argName,
[NotNull] string messageFormat,
[CanBeNull] params object[] args)
Expand Down Expand Up @@ -217,7 +217,7 @@ public static void ValidIndexAndCount(
[DebuggerHidden, MethodImpl(AggressiveInlining)]
[AssertionMethod]
public static void AssertState(
bool condition,
[AssertionCondition(AssertionConditionType.IS_TRUE)] bool condition,
[NotNull] string message)
{
if (!condition)
Expand All @@ -231,7 +231,7 @@ public static void AssertState(
[DebuggerHidden, MethodImpl(AggressiveInlining)]
[AssertionMethod, StringFormatMethod("messageFormat")]
public static void AssertState(
bool condition,
[AssertionCondition(AssertionConditionType.IS_TRUE)] bool condition,
[NotNull] string messageFormat,
[CanBeNull] params object[] args)
{
Expand Down

0 comments on commit b07d07a

Please sign in to comment.