File tree Expand file tree Collapse file tree 2 files changed +18
-15
lines changed Expand file tree Collapse file tree 2 files changed +18
-15
lines changed Original file line number Diff line number Diff line change @@ -109,18 +109,3 @@ macro_rules! format {
109109 } )
110110 }
111111}
112-
113- #[ macro_export]
114- #[ allow_internal_unstable( hint_must_use) ]
115- #[ rustc_diagnostic_item = "hash_map_macro" ]
116- macro_rules! hash_map {
117- ( ) => { {
118- :: std:: collections:: HashMap :: new( )
119- } } ;
120-
121- ( $( $key: expr => $value: expr ) ,* $( , ) ? ) => { {
122- let mut __map = :: std:: collections:: HashMap :: new( ) ;
123- $( __map. insert( $key, $value) ; ) *
124- __map
125- } }
126- }
Original file line number Diff line number Diff line change @@ -379,3 +379,21 @@ macro_rules! dbg {
379379 ( $( $crate:: dbg!( $val) ) ,+, )
380380 } ;
381381}
382+
383+ /// Creates a [`HashMap`]
384+ ///
385+ /// [`HashMap`]: crate::collections::HashMap
386+ #[ macro_export]
387+ #[ allow_internal_unstable( hint_must_use) ]
388+ #[ rustc_diagnostic_item = "hash_map_macro" ]
389+ macro_rules! hash_map {
390+ ( ) => { {
391+ :: std:: collections:: HashMap :: new( )
392+ } } ;
393+
394+ ( $( $key: expr => $value: expr ) ,* $( , ) ? ) => { {
395+ let mut __map = :: std:: collections:: HashMap :: new( ) ;
396+ $( __map. insert( $key, $value) ; ) *
397+ __map
398+ } }
399+ }
You can’t perform that action at this time.
0 commit comments