]> git.lizzy.rs Git - rust.git/blobdiff - src/libcore/hash/sip.rs
Rollup merge of #27039 - bluss:siphash-tests, r=alexcrichton
[rust.git] / src / libcore / hash / sip.rs
index be419e2cdadb0ed9c33a86eb708c6d513063f029..d26e9ab7072055d9a7a24f38e2e31ca58fa10409 100644 (file)
@@ -10,8 +10,6 @@
 
 //! An implementation of SipHash 2-4.
 
-#![allow(deprecated)] // until the next snapshot for inherent wrapping ops
-
 use prelude::*;
 use super::Hasher;
 
@@ -111,6 +109,7 @@ pub fn new_with_keys(key0: u64, key1: u64) -> SipHasher {
         state
     }
 
+    #[inline]
     fn reset(&mut self) {
         self.length = 0;
         self.v0 = self.k0 ^ 0x736f6d6570736575;
@@ -120,6 +119,7 @@ fn reset(&mut self) {
         self.ntail = 0;
     }
 
+    #[inline]
     fn write(&mut self, msg: &[u8]) {
         let length = msg.len();
         self.length += length;
@@ -173,6 +173,7 @@ fn write(&mut self, msg: &[u8]) {
         self.write(msg)
     }
 
+    #[inline]
     fn finish(&self) -> u64 {
         let mut v0 = self.v0;
         let mut v1 = self.v1;