@@ -1646,7 +1646,7 @@ The default is {DEFAULT_EDITION} and the latest stable edition is {LATEST_STABLE
16461646static PRINT_HELP : LazyLock < String > = LazyLock :: new ( || {
16471647 format ! (
16481648 "Compiler information to print on stdout (or to a file)\n \
1649- INFO may be one of ({}) .",
1649+ INFO may be one of <{}> .",
16501650 PRINT_KINDS . iter( ) . map( |( name, _) | format!( "{name}" ) ) . collect:: <Vec <_>>( ) . join( "|" )
16511651 )
16521652} ) ;
@@ -1679,66 +1679,73 @@ pub fn rustc_optgroups() -> Vec<RustcOptGroup> {
16791679 "" ,
16801680 "cfg" ,
16811681 "Configure the compilation environment.\n \
1682- SPEC supports the syntax `NAME[=\" VALUE\" ]`.",
1683- "SPEC" ,
1682+ SPEC supports the syntax `< NAME> [=\" VALUE\" ]`.",
1683+ "< SPEC> " ,
16841684 ) ,
1685- opt( Stable , Multi , "" , "check-cfg" , "Provide list of expected cfgs for checking" , "SPEC" ) ,
1685+ opt( Stable , Multi , "" , "check-cfg" , "Provide list of expected cfgs for checking" , "< SPEC> " ) ,
16861686 opt(
16871687 Stable ,
16881688 Multi ,
16891689 "L" ,
16901690 "" ,
16911691 "Add a directory to the library search path. \
1692- The optional KIND can be one of dependency, crate, native, framework, or all (the default).",
1693- "[KIND=] PATH" ,
1692+ The optional < KIND> can be one of < dependency| crate| native| framework| all> ( default: all ).",
1693+ "[< KIND>=]< PATH> " ,
16941694 ) ,
16951695 opt(
16961696 Stable ,
16971697 Multi ,
16981698 "l" ,
16991699 "" ,
17001700 "Link the generated crate(s) to the specified native\n \
1701- library NAME. The optional KIND can be one of\n \
1702- static, framework, or dylib (the default).\n \
1703- Optional comma separated MODIFIERS\n \
1704- ( bundle|verbatim|whole-archive|as-needed) \n \
1701+ library < NAME> . The optional < KIND> can be one of\n \
1702+ < static| framework| dylib> ( default: dylib ).\n \
1703+ Optional comma separated < MODIFIERS> \n \
1704+ < bundle|verbatim|whole-archive|as-needed> \n \
17051705 may be specified each with a prefix of either '+' to\n \
17061706 enable or '-' to disable.",
1707- "[KIND[: MODIFIERS]=]NAME[: RENAME]" ,
1707+ "[< KIND>[:< MODIFIERS> ]=]< NAME>[:< RENAME> ]" ,
17081708 ) ,
17091709 make_crate_type_option( ) ,
1710- opt( Stable , Opt , "" , "crate-name" , "Specify the name of the crate being built" , "NAME" ) ,
1710+ opt( Stable , Opt , "" , "crate-name" , "Specify the name of the crate being built" , "< NAME> " ) ,
17111711 opt( Stable , Opt , "" , "edition" , & EDITION_STRING , EDITION_NAME_LIST ) ,
1712- opt( Stable , Multi , "" , "emit" , & EMIT_HELP , "TYPE[= FILE]" ) ,
1713- opt( Stable , Multi , "" , "print" , & PRINT_HELP , "INFO[= FILE]" ) ,
1712+ opt( Stable , Multi , "" , "emit" , & EMIT_HELP , "< TYPE>[=< FILE> ]" ) ,
1713+ opt( Stable , Multi , "" , "print" , & PRINT_HELP , "< INFO>[=< FILE> ]" ) ,
17141714 opt( Stable , FlagMulti , "g" , "" , "Equivalent to -C debuginfo=2" , "" ) ,
17151715 opt( Stable , FlagMulti , "O" , "" , "Equivalent to -C opt-level=3" , "" ) ,
1716- opt( Stable , Opt , "o" , "" , "Write output to <filename>" , "FILENAME" ) ,
1717- opt( Stable , Opt , "" , "out-dir" , "Write output to compiler-chosen filename in <dir>" , "DIR" ) ,
1716+ opt( Stable , Opt , "o" , "" , "Write output to <FILENAME>" , "<FILENAME>" ) ,
1717+ opt(
1718+ Stable ,
1719+ Opt ,
1720+ "" ,
1721+ "out-dir" ,
1722+ "Write output to compiler-chosen filename in <DIR>" ,
1723+ "<DIR>" ,
1724+ ) ,
17181725 opt(
17191726 Stable ,
17201727 Opt ,
17211728 "" ,
17221729 "explain" ,
17231730 "Provide a detailed explanation of an error message" ,
1724- "OPT" ,
1731+ "< OPT> " ,
17251732 ) ,
17261733 opt( Stable , Flag , "" , "test" , "Build a test harness" , "" ) ,
1727- opt( Stable , Opt , "" , "target" , "Target triple for which the code is compiled" , "TARGET" ) ,
1728- opt( Stable , Multi , "A" , "allow" , "Set lint allowed" , "LINT" ) ,
1729- opt( Stable , Multi , "W" , "warn" , "Set lint warnings" , "LINT" ) ,
1730- opt( Stable , Multi , "" , "force-warn" , "Set lint force-warn" , "LINT" ) ,
1731- opt( Stable , Multi , "D" , "deny" , "Set lint denied" , "LINT" ) ,
1732- opt( Stable , Multi , "F" , "forbid" , "Set lint forbidden" , "LINT" ) ,
1734+ opt( Stable , Opt , "" , "target" , "Target triple for which the code is compiled" , "< TARGET> " ) ,
1735+ opt( Stable , Multi , "A" , "allow" , "Set lint allowed" , "< LINT> " ) ,
1736+ opt( Stable , Multi , "W" , "warn" , "Set lint warnings" , "< LINT> " ) ,
1737+ opt( Stable , Multi , "" , "force-warn" , "Set lint force-warn" , "< LINT> " ) ,
1738+ opt( Stable , Multi , "D" , "deny" , "Set lint denied" , "< LINT> " ) ,
1739+ opt( Stable , Multi , "F" , "forbid" , "Set lint forbidden" , "< LINT> " ) ,
17331740 opt(
17341741 Stable ,
17351742 Multi ,
17361743 "" ,
17371744 "cap-lints" ,
17381745 "Set the most restrictive lint level. More restrictive lints are capped at this level" ,
1739- "LEVEL" ,
1746+ "< LEVEL> " ,
17401747 ) ,
1741- opt( Stable , Multi , "C" , "codegen" , "Set a codegen option" , "OPT[= VALUE]" ) ,
1748+ opt( Stable , Multi , "C" , "codegen" , "Set a codegen option" , "< OPT>[=< VALUE> ]" ) ,
17421749 opt( Stable , Flag , "V" , "version" , "Print version info and exit" , "" ) ,
17431750 opt( Stable , Flag , "v" , "verbose" , "Use verbose output" , "" ) ,
17441751 ] ;
@@ -1752,47 +1759,47 @@ pub fn rustc_optgroups() -> Vec<RustcOptGroup> {
17521759 "" ,
17531760 "extern" ,
17541761 "Specify where an external rust library is located" ,
1755- "NAME[= PATH]" ,
1762+ "< NAME>[=< PATH> ]" ,
17561763 ) ,
1757- opt ( Stable , Opt , "" , "sysroot" , "Override the system root" , "PATH" ) ,
1758- opt ( Unstable , Multi , "Z" , "" , "Set unstable / perma-unstable options" , "FLAG" ) ,
1764+ opt ( Stable , Opt , "" , "sysroot" , "Override the system root" , "< PATH> " ) ,
1765+ opt ( Unstable , Multi , "Z" , "" , "Set unstable / perma-unstable options" , "< FLAG> " ) ,
17591766 opt (
17601767 Stable ,
17611768 Opt ,
17621769 "" ,
17631770 "error-format" ,
17641771 "How errors and other messages are produced" ,
1765- "human|json|short" ,
1772+ "< human|json|short> " ,
17661773 ) ,
1767- opt ( Stable , Multi , "" , "json" , "Configure the JSON output of the compiler" , "CONFIG" ) ,
1774+ opt ( Stable , Multi , "" , "json" , "Configure the JSON output of the compiler" , "< CONFIG> " ) ,
17681775 opt (
17691776 Stable ,
17701777 Opt ,
17711778 "" ,
17721779 "color" ,
17731780 "Configure coloring of output:
1774- auto = colorize, if output goes to a tty (default);
1775- always = always colorize output;
1776- never = never colorize output" ,
1777- "auto|always|never" ,
1781+ * auto = colorize, if output goes to a tty (default);
1782+ * always = always colorize output;
1783+ * never = never colorize output" ,
1784+ "< auto|always|never> " ,
17781785 ) ,
17791786 opt (
17801787 Stable ,
17811788 Opt ,
17821789 "" ,
17831790 "diagnostic-width" ,
17841791 "Inform rustc of the width of the output so that diagnostics can be truncated to fit" ,
1785- "WIDTH" ,
1792+ "< WIDTH> " ,
17861793 ) ,
17871794 opt (
17881795 Stable ,
17891796 Multi ,
17901797 "" ,
17911798 "remap-path-prefix" ,
17921799 "Remap source names in all output (compiler messages and output files)" ,
1793- "FROM=TO " ,
1800+ "< FROM>=<TO> " ,
17941801 ) ,
1795- opt ( Unstable , Multi , "" , "env-set" , "Inject an environment variable" , "VAR= VALUE" ) ,
1802+ opt ( Unstable , Multi , "" , "env-set" , "Inject an environment variable" , "< VAR>=< VALUE> " ) ,
17961803 ] ;
17971804 options. extend ( verbose_only. into_iter ( ) . map ( |mut opt| {
17981805 opt. is_verbose_help_only = true ;
@@ -2792,7 +2799,7 @@ pub fn make_crate_type_option() -> RustcOptGroup {
27922799 "crate-type" ,
27932800 "Comma separated list of types of crates
27942801 for the compiler to emit" ,
2795- "[ bin|lib|rlib|dylib|cdylib|staticlib|proc-macro] " ,
2802+ "< bin|lib|rlib|dylib|cdylib|staticlib|proc-macro> " ,
27962803 )
27972804}
27982805
0 commit comments