1 files changed, 12 insertions, 0 deletions
diff --git a/crypto/src/util/Integers.cs b/crypto/src/util/Integers.cs
index ccbf872c4..e746b0ef4 100644
--- a/crypto/src/util/Integers.cs
+++ b/crypto/src/util/Integers.cs
@@ -9,9 +9,21 @@ namespace Org.BouncyCastle.Utilities
return (i << distance) ^ (int)((uint)i >> -distance);
}
+ [CLSCompliantAttribute(false)]
+ public static uint RotateLeft(uint i, int distance)
+ {
+ return (i << distance) ^ (i >> -distance);
+ }
+
public static int RotateRight(int i, int distance)
{
return (int)((uint)i >> distance) ^ (i << -distance);
}
+
+ [CLSCompliantAttribute(false)]
+ public static uint RotateRight(uint i, int distance)
+ {
+ return (i >> distance) ^ (i << -distance);
+ }
}
}
|