@@ -1646,7 +1646,7 @@ The default is {DEFAULT_EDITION} and the latest stable edition is {LATEST_STABLE
1646
1646
static PRINT_HELP : LazyLock < String > = LazyLock :: new ( || {
1647
1647
format ! (
1648
1648
"Compiler information to print on stdout (or to a file)\n \
1649
- INFO may be one of ({}) .",
1649
+ INFO may be one of <{}> .",
1650
1650
PRINT_KINDS . iter( ) . map( |( name, _) | format!( "{name}" ) ) . collect:: <Vec <_>>( ) . join( "|" )
1651
1651
)
1652
1652
} ) ;
@@ -1679,66 +1679,85 @@ pub fn rustc_optgroups() -> Vec<RustcOptGroup> {
1679
1679
"" ,
1680
1680
"cfg" ,
1681
1681
"Configure the compilation environment.\n \
1682
- SPEC supports the syntax `NAME[=\" VALUE\" ]`.",
1683
- "SPEC" ,
1682
+ SPEC supports the syntax `< NAME> [=\" VALUE\" ]`.",
1683
+ "< SPEC> " ,
1684
1684
) ,
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> " ) ,
1686
1686
opt(
1687
1687
Stable ,
1688
1688
Multi ,
1689
1689
"L" ,
1690
1690
"" ,
1691
1691
"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> " ,
1694
1694
) ,
1695
1695
opt(
1696
1696
Stable ,
1697
1697
Multi ,
1698
1698
"l" ,
1699
1699
"" ,
1700
1700
"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 \
1705
1705
may be specified each with a prefix of either '+' to\n \
1706
1706
enable or '-' to disable.",
1707
- "[KIND[: MODIFIERS]=]NAME[: RENAME]" ,
1707
+ "[< KIND>[:< MODIFIERS> ]=]< NAME>[:< RENAME> ]" ,
1708
1708
) ,
1709
1709
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> " ) ,
1711
1711
opt( Stable , Opt , "" , "edition" , & EDITION_STRING , EDITION_NAME_LIST ) ,
1712
- opt( Stable , Multi , "" , "emit" , & EMIT_HELP , "TYPE[=FILE]" ) ,
1712
+ opt( Stable , Multi , "" , "emit" , & EMIT_HELP , "<TYPE>[=<FILE>]" ) ,
1713
+ opt( Stable , Multi , "" , "print" , & PRINT_HELP , "<INFO>[=<FILE>]" ) ,
1714
+ opt( Stable , FlagMulti , "g" , "" , "Equivalent to -C debuginfo=2" , "" ) ,
1715
+ opt( Stable , FlagMulti , "O" , "" , "Equivalent to -C opt-level=3" , "" ) ,
1716
+ opt( Stable , Opt , "o" , "" , "Write output to <FILENAME>" , "<FILENAME>" ) ,
1717
+ opt(
1718
+ Stable ,
1719
+ Opt ,
1720
+ "" ,
1721
+ "emit" ,
1722
+ "Comma separated list of types of output for the compiler to emit" ,
1723
+ "[asm|llvm-bc|llvm-ir|obj|metadata|link|dep-info|mir]" ,
1724
+ ) ,
1713
1725
opt( Stable , Multi , "" , "print" , & PRINT_HELP , "INFO[=FILE]" ) ,
1714
1726
opt( Stable , FlagMulti , "g" , "" , "Equivalent to -C debuginfo=2" , "" ) ,
1715
1727
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" ) ,
1728
+ opt( Stable , Opt , "o" , "" , "Write output to <FILENAME>" , "<FILENAME>" ) ,
1729
+ opt(
1730
+ Stable ,
1731
+ Opt ,
1732
+ "" ,
1733
+ "out-dir" ,
1734
+ "Write output to compiler-chosen filename in <DIR>" ,
1735
+ "<DIR>" ,
1736
+ ) ,
1718
1737
opt(
1719
1738
Stable ,
1720
1739
Opt ,
1721
1740
"" ,
1722
1741
"explain" ,
1723
1742
"Provide a detailed explanation of an error message" ,
1724
- "OPT" ,
1743
+ "< OPT> " ,
1725
1744
) ,
1726
1745
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" ) ,
1746
+ opt( Stable , Opt , "" , "target" , "Target triple for which the code is compiled" , "< TARGET> " ) ,
1747
+ opt( Stable , Multi , "A" , "allow" , "Set lint allowed" , "< LINT> " ) ,
1748
+ opt( Stable , Multi , "W" , "warn" , "Set lint warnings" , "< LINT> " ) ,
1749
+ opt( Stable , Multi , "" , "force-warn" , "Set lint force-warn" , "< LINT> " ) ,
1750
+ opt( Stable , Multi , "D" , "deny" , "Set lint denied" , "< LINT> " ) ,
1751
+ opt( Stable , Multi , "F" , "forbid" , "Set lint forbidden" , "< LINT> " ) ,
1733
1752
opt(
1734
1753
Stable ,
1735
1754
Multi ,
1736
1755
"" ,
1737
1756
"cap-lints" ,
1738
1757
"Set the most restrictive lint level. More restrictive lints are capped at this level" ,
1739
- "LEVEL" ,
1758
+ "< LEVEL> " ,
1740
1759
) ,
1741
- opt( Stable , Multi , "C" , "codegen" , "Set a codegen option" , "OPT[= VALUE]" ) ,
1760
+ opt( Stable , Multi , "C" , "codegen" , "Set a codegen option" , "< OPT>[=< VALUE> ]" ) ,
1742
1761
opt( Stable , Flag , "V" , "version" , "Print version info and exit" , "" ) ,
1743
1762
opt( Stable , Flag , "v" , "verbose" , "Use verbose output" , "" ) ,
1744
1763
] ;
@@ -1752,47 +1771,47 @@ pub fn rustc_optgroups() -> Vec<RustcOptGroup> {
1752
1771
"" ,
1753
1772
"extern" ,
1754
1773
"Specify where an external rust library is located" ,
1755
- "NAME[= PATH]" ,
1774
+ "< NAME>[=< PATH> ]" ,
1756
1775
) ,
1757
- opt ( Stable , Opt , "" , "sysroot" , "Override the system root" , "PATH" ) ,
1758
- opt ( Unstable , Multi , "Z" , "" , "Set unstable / perma-unstable options" , "FLAG" ) ,
1776
+ opt ( Stable , Opt , "" , "sysroot" , "Override the system root" , "< PATH> " ) ,
1777
+ opt ( Unstable , Multi , "Z" , "" , "Set unstable / perma-unstable options" , "< FLAG> " ) ,
1759
1778
opt (
1760
1779
Stable ,
1761
1780
Opt ,
1762
1781
"" ,
1763
1782
"error-format" ,
1764
1783
"How errors and other messages are produced" ,
1765
- "human|json|short" ,
1784
+ "< human|json|short> " ,
1766
1785
) ,
1767
- opt ( Stable , Multi , "" , "json" , "Configure the JSON output of the compiler" , "CONFIG" ) ,
1786
+ opt ( Stable , Multi , "" , "json" , "Configure the JSON output of the compiler" , "< CONFIG> " ) ,
1768
1787
opt (
1769
1788
Stable ,
1770
1789
Opt ,
1771
1790
"" ,
1772
1791
"color" ,
1773
1792
"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" ,
1793
+ * auto = colorize, if output goes to a tty (default);
1794
+ * always = always colorize output;
1795
+ * never = never colorize output" ,
1796
+ "< auto|always|never> " ,
1778
1797
) ,
1779
1798
opt (
1780
1799
Stable ,
1781
1800
Opt ,
1782
1801
"" ,
1783
1802
"diagnostic-width" ,
1784
1803
"Inform rustc of the width of the output so that diagnostics can be truncated to fit" ,
1785
- "WIDTH" ,
1804
+ "< WIDTH> " ,
1786
1805
) ,
1787
1806
opt (
1788
1807
Stable ,
1789
1808
Multi ,
1790
1809
"" ,
1791
1810
"remap-path-prefix" ,
1792
1811
"Remap source names in all output (compiler messages and output files)" ,
1793
- "FROM=TO " ,
1812
+ "< FROM>=<TO> " ,
1794
1813
) ,
1795
- opt ( Unstable , Multi , "" , "env-set" , "Inject an environment variable" , "VAR= VALUE" ) ,
1814
+ opt ( Unstable , Multi , "" , "env-set" , "Inject an environment variable" , "< VAR>=< VALUE> " ) ,
1796
1815
] ;
1797
1816
options. extend ( verbose_only. into_iter ( ) . map ( |mut opt| {
1798
1817
opt. is_verbose_help_only = true ;
@@ -2792,7 +2811,7 @@ pub fn make_crate_type_option() -> RustcOptGroup {
2792
2811
"crate-type" ,
2793
2812
"Comma separated list of types of crates
2794
2813
for the compiler to emit" ,
2795
- "[ bin|lib|rlib|dylib|cdylib|staticlib|proc-macro] " ,
2814
+ "< bin|lib|rlib|dylib|cdylib|staticlib|proc-macro> " ,
2796
2815
)
2797
2816
}
2798
2817
0 commit comments