File tree Expand file tree Collapse file tree 3 files changed +6
-6
lines changed Expand file tree Collapse file tree 3 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -58,7 +58,7 @@ pub struct CargoConfig {
58
58
pub load_out_dirs_from_check : bool ,
59
59
60
60
/// rustc target
61
- pub default_target : Option < String > ,
61
+ pub target : Option < String > ,
62
62
}
63
63
64
64
impl Default for CargoConfig {
@@ -68,7 +68,7 @@ impl Default for CargoConfig {
68
68
all_features : true ,
69
69
features : Vec :: new ( ) ,
70
70
load_out_dirs_from_check : false ,
71
- default_target : None ,
71
+ target : None ,
72
72
}
73
73
}
74
74
}
@@ -164,7 +164,7 @@ impl CargoWorkspace {
164
164
if let Some ( parent) = cargo_toml. parent ( ) {
165
165
meta. current_dir ( parent) ;
166
166
}
167
- if let Some ( target) = cargo_features. default_target . as_ref ( ) {
167
+ if let Some ( target) = cargo_features. target . as_ref ( ) {
168
168
meta. other_options ( & [ String :: from ( "--filter-platform" ) , target. clone ( ) ] ) ;
169
169
}
170
170
let meta = meta. exec ( ) . with_context ( || {
Original file line number Diff line number Diff line change @@ -134,7 +134,7 @@ impl Config {
134
134
set ( value, "/cargo/allFeatures" , & mut self . cargo . all_features ) ;
135
135
set ( value, "/cargo/features" , & mut self . cargo . features ) ;
136
136
set ( value, "/cargo/loadOutDirsFromCheck" , & mut self . cargo . load_out_dirs_from_check ) ;
137
- set ( value, "/cargo/defaultTarget " , & mut self . cargo . default_target ) ;
137
+ set ( value, "/cargo/target " , & mut self . cargo . target ) ;
138
138
139
139
match get ( value, "/procMacro/enable" ) {
140
140
Some ( true ) => {
Original file line number Diff line number Diff line change 237
237
"default" : false ,
238
238
"markdownDescription" : " Run `cargo check` on startup to get the correct value for package OUT_DIRs"
239
239
},
240
- "rust-analyzer.cargo.defaultTarget " : {
240
+ "rust-analyzer.cargo.target " : {
241
241
"type" : [
242
242
" null" ,
243
243
" string"
244
244
],
245
245
"default" : null ,
246
- "description" : " Specify the default target"
246
+ "description" : " Specify the compilation target"
247
247
},
248
248
"rust-analyzer.rustfmt.extraArgs" : {
249
249
"type" : " array" ,
You can’t perform that action at this time.
0 commit comments