1
- use std:: collections:: BTreeMap ;
1
+ use std:: collections:: { BTreeMap , HashMap } ;
2
2
use std:: collections:: HashSet ;
3
3
use std:: { cmp, env, fmt, hash} ;
4
4
@@ -18,8 +18,8 @@ pub struct Profiles {
18
18
/// - `CARGO_INCREMENTAL` environment variable.
19
19
/// - `build.incremental` config value.
20
20
incremental : Option < bool > ,
21
- dir_names : BTreeMap < String , String > ,
22
- by_name : BTreeMap < String , ProfileMaker > ,
21
+ dir_names : HashMap < String , String > ,
22
+ by_name : HashMap < String , ProfileMaker > ,
23
23
}
24
24
25
25
impl Profiles {
@@ -43,7 +43,7 @@ impl Profiles {
43
43
let mut profile_makers = Profiles {
44
44
incremental,
45
45
dir_names : Self :: predefined_dir_names ( ) ,
46
- by_name : BTreeMap :: new ( ) ,
46
+ by_name : HashMap :: new ( ) ,
47
47
} ;
48
48
49
49
Self :: add_root_profiles ( & mut profile_makers, profiles, config_profiles) ;
@@ -98,8 +98,8 @@ impl Profiles {
98
98
Ok ( profile_makers)
99
99
}
100
100
101
- fn predefined_dir_names ( ) -> BTreeMap < String , String > {
102
- let mut dir_names = BTreeMap :: new ( ) ;
101
+ fn predefined_dir_names ( ) -> HashMap < String , String > {
102
+ let mut dir_names = HashMap :: new ( ) ;
103
103
dir_names. insert ( "dev" . to_owned ( ) , "debug" . to_owned ( ) ) ;
104
104
dir_names. insert ( "check" . to_owned ( ) , "debug" . to_owned ( ) ) ;
105
105
dir_names. insert ( "test" . to_owned ( ) , "debug" . to_owned ( ) ) ;
0 commit comments