@@ -390,7 +390,7 @@ mod desc {
390
390
pub const parse_stack_protector: & str =
391
391
"one of (`none` (default), `basic`, `strong`, or `all`)" ;
392
392
pub const parse_branch_protection: & str =
393
- "a `+ ` separated combination of `bti`, `b-key`, `pac-ret`, or `leaf`" ;
393
+ "a `, ` separated combination of `bti`, `b-key`, `pac-ret`, or `leaf`" ;
394
394
}
395
395
396
396
mod parse {
@@ -935,7 +935,7 @@ mod parse {
935
935
crate fn parse_branch_protection ( slot : & mut BranchProtection , v : Option < & str > ) -> bool {
936
936
match v {
937
937
Some ( s) => {
938
- for opt in s. split ( '+ ' ) {
938
+ for opt in s. split ( ', ' ) {
939
939
match opt {
940
940
"bti" => slot. bti = true ,
941
941
"pac-ret" if slot. pac_ret . is_none ( ) => {
@@ -953,7 +953,6 @@ mod parse {
953
953
} ;
954
954
}
955
955
}
956
-
957
956
_ => return false ,
958
957
}
959
958
true
@@ -971,8 +970,6 @@ options! {
971
970
972
971
ar: String = ( String :: new( ) , parse_string, [ UNTRACKED ] ,
973
972
"this option is deprecated and does nothing" ) ,
974
- branch_protection: BranchProtection = ( BranchProtection :: default ( ) , parse_branch_protection, [ TRACKED ] ,
975
- "set options for branch target identification and pointer authentication on AArch64" ) ,
976
973
code_model: Option <CodeModel > = ( None , parse_code_model, [ TRACKED ] ,
977
974
"choose the code model to use (`rustc --print code-models` for details)" ) ,
978
975
codegen_units: Option <usize > = ( None , parse_opt_number, [ UNTRACKED ] ,
@@ -1101,6 +1098,8 @@ options! {
1101
1098
(default: no)") ,
1102
1099
borrowck: String = ( "migrate" . to_string( ) , parse_string, [ UNTRACKED ] ,
1103
1100
"select which borrowck is used (`mir` or `migrate`) (default: `migrate`)" ) ,
1101
+ branch_protection: BranchProtection = ( BranchProtection :: default ( ) , parse_branch_protection, [ TRACKED ] ,
1102
+ "set options for branch target identification and pointer authentication on AArch64" ) ,
1104
1103
cgu_partitioning_strategy: Option <String > = ( None , parse_opt_string, [ TRACKED ] ,
1105
1104
"the codegen unit partitioning strategy to use" ) ,
1106
1105
chalk: bool = ( false , parse_bool, [ TRACKED ] ,
0 commit comments