@@ -1707,13 +1707,15 @@ impl<'a, K, V, S> RawEntryMut<'a, K, V, S> {
17071707impl < ' a , K , V , S > RawOccupiedEntryMut < ' a , K , V , S > {
17081708 /// Gets a reference to the key in the entry.
17091709 #[ inline]
1710+ #[ must_use]
17101711 #[ unstable( feature = "hash_raw_entry" , issue = "56167" ) ]
17111712 pub fn key ( & self ) -> & K {
17121713 self . base . key ( )
17131714 }
17141715
17151716 /// Gets a mutable reference to the key in the entry.
17161717 #[ inline]
1718+ #[ must_use]
17171719 #[ unstable( feature = "hash_raw_entry" , issue = "56167" ) ]
17181720 pub fn key_mut ( & mut self ) -> & mut K {
17191721 self . base . key_mut ( )
@@ -1730,6 +1732,7 @@ impl<'a, K, V, S> RawOccupiedEntryMut<'a, K, V, S> {
17301732
17311733 /// Gets a reference to the value in the entry.
17321734 #[ inline]
1735+ #[ must_use]
17331736 #[ unstable( feature = "hash_raw_entry" , issue = "56167" ) ]
17341737 pub fn get ( & self ) -> & V {
17351738 self . base . get ( )
@@ -1746,13 +1749,15 @@ impl<'a, K, V, S> RawOccupiedEntryMut<'a, K, V, S> {
17461749
17471750 /// Gets a mutable reference to the value in the entry.
17481751 #[ inline]
1752+ #[ must_use]
17491753 #[ unstable( feature = "hash_raw_entry" , issue = "56167" ) ]
17501754 pub fn get_mut ( & mut self ) -> & mut V {
17511755 self . base . get_mut ( )
17521756 }
17531757
17541758 /// Gets a reference to the key and value in the entry.
17551759 #[ inline]
1760+ #[ must_use]
17561761 #[ unstable( feature = "hash_raw_entry" , issue = "56167" ) ]
17571762 pub fn get_key_value ( & mut self ) -> ( & K , & V ) {
17581763 self . base . get_key_value ( )
0 commit comments