@@ -24,7 +24,8 @@ use mem;
24
24
///
25
25
/// See: https://131002.net/siphash/
26
26
#[ unstable( feature = "sip_hash_13" , issue = "34767" ) ]
27
- #[ rustc_deprecated( since = "1.13.0" , reason = "use `DefaultHasher` instead" ) ]
27
+ #[ rustc_deprecated( since = "1.13.0" ,
28
+ reason = "use `std::collections::hash_map::DefaultHasher` instead" ) ]
28
29
#[ derive( Debug , Clone , Default ) ]
29
30
pub struct SipHasher13 {
30
31
hasher : Hasher < Sip13Rounds > ,
@@ -34,7 +35,8 @@ pub struct SipHasher13 {
34
35
///
35
36
/// See: https://131002.net/siphash/
36
37
#[ unstable( feature = "sip_hash_13" , issue = "34767" ) ]
37
- #[ rustc_deprecated( since = "1.13.0" , reason = "use `DefaultHasher` instead" ) ]
38
+ #[ rustc_deprecated( since = "1.13.0" ,
39
+ reason = "use `std::collections::hash_map::DefaultHasher` instead" ) ]
38
40
#[ derive( Debug , Clone , Default ) ]
39
41
pub struct SipHasher24 {
40
42
hasher : Hasher < Sip24Rounds > ,
@@ -53,7 +55,8 @@ pub struct SipHasher24 {
53
55
/// it is not intended for cryptographic purposes. As such, all
54
56
/// cryptographic uses of this implementation are _strongly discouraged_.
55
57
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
56
- #[ rustc_deprecated( since = "1.13.0" , reason = "use `DefaultHasher` instead" ) ]
58
+ #[ rustc_deprecated( since = "1.13.0" ,
59
+ reason = "use `std::collections::hash_map::DefaultHasher` instead" ) ]
57
60
#[ derive( Debug , Clone , Default ) ]
58
61
pub struct SipHasher ( SipHasher24 ) ;
59
62
@@ -140,15 +143,17 @@ impl SipHasher {
140
143
/// Creates a new `SipHasher` with the two initial keys set to 0.
141
144
#[ inline]
142
145
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
143
- #[ rustc_deprecated( since = "1.13.0" , reason = "use `DefaultHasher` instead" ) ]
146
+ #[ rustc_deprecated( since = "1.13.0" ,
147
+ reason = "use `std::collections::hash_map::DefaultHasher` instead" ) ]
144
148
pub fn new ( ) -> SipHasher {
145
149
SipHasher :: new_with_keys ( 0 , 0 )
146
150
}
147
151
148
152
/// Creates a `SipHasher` that is keyed off the provided keys.
149
153
#[ inline]
150
154
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
151
- #[ rustc_deprecated( since = "1.13.0" , reason = "use `DefaultHasher` instead" ) ]
155
+ #[ rustc_deprecated( since = "1.13.0" ,
156
+ reason = "use `std::collections::hash_map::DefaultHasher` instead" ) ]
152
157
pub fn new_with_keys ( key0 : u64 , key1 : u64 ) -> SipHasher {
153
158
SipHasher ( SipHasher24 :: new_with_keys ( key0, key1) )
154
159
}
@@ -158,15 +163,17 @@ impl SipHasher13 {
158
163
/// Creates a new `SipHasher13` with the two initial keys set to 0.
159
164
#[ inline]
160
165
#[ unstable( feature = "sip_hash_13" , issue = "34767" ) ]
161
- #[ rustc_deprecated( since = "1.13.0" , reason = "use `DefaultHasher` instead" ) ]
166
+ #[ rustc_deprecated( since = "1.13.0" ,
167
+ reason = "use `std::collections::hash_map::DefaultHasher` instead" ) ]
162
168
pub fn new ( ) -> SipHasher13 {
163
169
SipHasher13 :: new_with_keys ( 0 , 0 )
164
170
}
165
171
166
172
/// Creates a `SipHasher13` that is keyed off the provided keys.
167
173
#[ inline]
168
174
#[ unstable( feature = "sip_hash_13" , issue = "34767" ) ]
169
- #[ rustc_deprecated( since = "1.13.0" , reason = "use `DefaultHasher` instead" ) ]
175
+ #[ rustc_deprecated( since = "1.13.0" ,
176
+ reason = "use `std::collections::hash_map::DefaultHasher` instead" ) ]
170
177
pub fn new_with_keys ( key0 : u64 , key1 : u64 ) -> SipHasher13 {
171
178
SipHasher13 {
172
179
hasher : Hasher :: new_with_keys ( key0, key1)
@@ -178,15 +185,17 @@ impl SipHasher24 {
178
185
/// Creates a new `SipHasher24` with the two initial keys set to 0.
179
186
#[ inline]
180
187
#[ unstable( feature = "sip_hash_13" , issue = "34767" ) ]
181
- #[ rustc_deprecated( since = "1.13.0" , reason = "use `DefaultHasher` instead" ) ]
188
+ #[ rustc_deprecated( since = "1.13.0" ,
189
+ reason = "use `std::collections::hash_map::DefaultHasher` instead" ) ]
182
190
pub fn new ( ) -> SipHasher24 {
183
191
SipHasher24 :: new_with_keys ( 0 , 0 )
184
192
}
185
193
186
194
/// Creates a `SipHasher24` that is keyed off the provided keys.
187
195
#[ inline]
188
196
#[ unstable( feature = "sip_hash_13" , issue = "34767" ) ]
189
- #[ rustc_deprecated( since = "1.13.0" , reason = "use `DefaultHasher` instead" ) ]
197
+ #[ rustc_deprecated( since = "1.13.0" ,
198
+ reason = "use `std::collections::hash_map::DefaultHasher` instead" ) ]
190
199
pub fn new_with_keys ( key0 : u64 , key1 : u64 ) -> SipHasher24 {
191
200
SipHasher24 {
192
201
hasher : Hasher :: new_with_keys ( key0, key1)
0 commit comments