[llvm] r219121 - Make the MD5 result name consistent between functions, header and source.

Yaron Keren yaron.keren at gmail.com
Mon Oct 6 06:48:08 PDT 2014


Author: yrnkrn
Date: Mon Oct  6 08:48:07 2014
New Revision: 219121

URL: http://llvm.org/viewvc/llvm-project?rev=219121&view=rev
Log:
Make the MD5 result name consistent between functions, header and source.


Modified:
    llvm/trunk/include/llvm/Support/MD5.h
    llvm/trunk/lib/Support/MD5.cpp

Modified: llvm/trunk/include/llvm/Support/MD5.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/MD5.h?rev=219121&r1=219120&r2=219121&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/MD5.h (original)
+++ llvm/trunk/include/llvm/Support/MD5.h Mon Oct  6 08:48:07 2014
@@ -55,11 +55,11 @@ public:
   void update(StringRef Str);
 
   /// \brief Finishes off the hash and puts the result in result.
-  void final(MD5Result &result);
+  void final(MD5Result &Result);
 
   /// \brief Translates the bytes in \p Res to a hex string that is
   /// deposited into \p Str. The result will be of length 32.
-  static void stringifyResult(MD5Result &Res, SmallString<32> &Str);
+  static void stringifyResult(MD5Result &Result, SmallString<32> &Str);
 
 private:
   const uint8_t *body(ArrayRef<uint8_t> Data);

Modified: llvm/trunk/lib/Support/MD5.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/MD5.cpp?rev=219121&r1=219120&r2=219121&view=diff
==============================================================================
--- llvm/trunk/lib/Support/MD5.cpp (original)
+++ llvm/trunk/lib/Support/MD5.cpp Mon Oct  6 08:48:07 2014
@@ -229,7 +229,7 @@ void MD5::update(StringRef Str) {
 
 /// \brief Finish the hash and place the resulting hash into \p result.
 /// \param result is assumed to be a minimum of 16-bytes in size.
-void MD5::final(MD5Result &result) {
+void MD5::final(MD5Result &Result) {
   unsigned long used, free;
 
   used = lo & 0x3f;
@@ -259,28 +259,28 @@ void MD5::final(MD5Result &result) {
 
   body(makeArrayRef(buffer, 64));
 
-  result[0] = a;
-  result[1] = a >> 8;
-  result[2] = a >> 16;
-  result[3] = a >> 24;
-  result[4] = b;
-  result[5] = b >> 8;
-  result[6] = b >> 16;
-  result[7] = b >> 24;
-  result[8] = c;
-  result[9] = c >> 8;
-  result[10] = c >> 16;
-  result[11] = c >> 24;
-  result[12] = d;
-  result[13] = d >> 8;
-  result[14] = d >> 16;
-  result[15] = d >> 24;
+  Result[0] = a;
+  Result[1] = a >> 8;
+  Result[2] = a >> 16;
+  Result[3] = a >> 24;
+  Result[4] = b;
+  Result[5] = b >> 8;
+  Result[6] = b >> 16;
+  Result[7] = b >> 24;
+  Result[8] = c;
+  Result[9] = c >> 8;
+  Result[10] = c >> 16;
+  Result[11] = c >> 24;
+  Result[12] = d;
+  Result[13] = d >> 8;
+  Result[14] = d >> 16;
+  Result[15] = d >> 24;
 }
 
-void MD5::stringifyResult(MD5Result &result, SmallString<32> &Str) {
+void MD5::stringifyResult(MD5Result &Result, SmallString<32> &Str) {
   raw_svector_ostream Res(Str);
   for (int i = 0; i < 16; ++i)
-    Res << format("%.2x", result[i]);
+    Res << format("%.2x", Result[i]);
 }
 
 }





More information about the llvm-commits mailing list