diff options
author | Andrew Arnott <andrewarnott@gmail.com> | 2012-12-26 20:20:46 -0800 |
---|---|---|
committer | Andrew Arnott <andrewarnott@gmail.com> | 2012-12-26 20:20:46 -0800 |
commit | 3475fab579db0f6a1454ebc83d2e8a9c271e4c18 (patch) | |
tree | bc1cc264acba9edc486eefbbfbb5fd4822111fb1 /src/DotNetOpenAuth.Core/RequiresEx.cs | |
parent | 002ce0e39af3b684ce6060dce60805e3333420fa (diff) | |
download | DotNetOpenAuth-3475fab579db0f6a1454ebc83d2e8a9c271e4c18.zip DotNetOpenAuth-3475fab579db0f6a1454ebc83d2e8a9c271e4c18.tar.gz DotNetOpenAuth-3475fab579db0f6a1454ebc83d2e8a9c271e4c18.tar.bz2 |
Removes more remnants of Code Contracts.
Diffstat (limited to 'src/DotNetOpenAuth.Core/RequiresEx.cs')
-rw-r--r-- | src/DotNetOpenAuth.Core/RequiresEx.cs | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/src/DotNetOpenAuth.Core/RequiresEx.cs b/src/DotNetOpenAuth.Core/RequiresEx.cs index 8779b2f..1a077c4 100644 --- a/src/DotNetOpenAuth.Core/RequiresEx.cs +++ b/src/DotNetOpenAuth.Core/RequiresEx.cs @@ -23,16 +23,11 @@ namespace DotNetOpenAuth { /// Validates some expression describing the acceptable condition for an argument evaluates to true. /// </summary> /// <param name="condition">The expression that must evaluate to true to avoid an <see cref="InvalidOperationException"/>.</param> -#if !CLR4 - [ContractArgumentValidator] -#endif [Pure, DebuggerStepThrough] internal static void ValidState(bool condition) { if (!condition) { throw new InvalidOperationException(); } - - Contract.EndContractBlock(); } /// <summary> @@ -40,16 +35,11 @@ namespace DotNetOpenAuth { /// </summary> /// <param name="condition">The expression that must evaluate to true to avoid an <see cref="InvalidOperationException"/>.</param> /// <param name="message">The message to include with the exception.</param> -#if !CLR4 - [ContractArgumentValidator] -#endif [Pure, DebuggerStepThrough] internal static void ValidState(bool condition, string message) { if (!condition) { throw new InvalidOperationException(message); } - - Contract.EndContractBlock(); } /// <summary> @@ -58,16 +48,11 @@ namespace DotNetOpenAuth { /// <param name="condition">The expression that must evaluate to true to avoid an <see cref="InvalidOperationException"/>.</param> /// <param name="unformattedMessage">The unformatted message.</param> /// <param name="args">Formatting arguments.</param> -#if !CLR4 - [ContractArgumentValidator] -#endif [Pure, DebuggerStepThrough] internal static void ValidState(bool condition, string unformattedMessage, params object[] args) { if (!condition) { throw new InvalidOperationException(string.Format(CultureInfo.CurrentCulture, unformattedMessage, args)); } - - Contract.EndContractBlock(); } /// <summary> @@ -76,15 +61,10 @@ namespace DotNetOpenAuth { /// <typeparam name="T">The type that the argument must be or derive from.</typeparam> /// <param name="type">The type given in the argument.</param> /// <param name="parameterName">Name of the parameter.</param> -#if !CLR4 - [ContractArgumentValidator] -#endif [Pure, DebuggerStepThrough] internal static void NotNullSubtype<T>(Type type, string parameterName) { Requires.NotNull(type, parameterName); Requires.That(typeof(T).IsAssignableFrom(type), parameterName, MessagingStrings.UnexpectedType, typeof(T).FullName, type.FullName); - - Contract.EndContractBlock(); } /// <summary> @@ -92,16 +72,11 @@ namespace DotNetOpenAuth { /// </summary> /// <param name="condition">The expression that must evaluate to true to avoid an <see cref="FormatException"/>.</param> /// <param name="message">The message.</param> -#if !CLR4 - [ContractArgumentValidator] -#endif [Pure, DebuggerStepThrough] internal static void Format(bool condition, string message) { if (!condition) { throw new FormatException(message); } - - Contract.EndContractBlock(); } /// <summary> |