[PATCH] D35477: [ELF] - Print options aliases in --help
Rafael Avila de Espindola via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 25 10:16:19 PDT 2017
LGTM
George Rimar via Phabricator <reviews at reviews.llvm.org> writes:
> grimar updated this revision to Diff 108099.
> grimar added a comment.
>
> - Reduced testcase.
>
>
> https://reviews.llvm.org/D35477
>
> Files:
> ELF/DriverUtils.cpp
> test/ELF/help.s
>
>
> Index: test/ELF/help.s
> ===================================================================
> --- test/ELF/help.s
> +++ test/ELF/help.s
> @@ -0,0 +1,5 @@
> +# RUN: ld.lld --help 2>&1 | FileCheck -check-prefix=HELP %s
> +# HELP: OPTIONS:
> +# HELP: --output=<value> Path to file to write output
> +# HELP: --output <value> Path to file to write output
> +# HELP: -o <path> Path to file to write output
> Index: ELF/DriverUtils.cpp
> ===================================================================
> --- ELF/DriverUtils.cpp
> +++ ELF/DriverUtils.cpp
> @@ -116,7 +116,8 @@
>
> void elf::printHelp(const char *Argv0) {
> ELFOptTable Table;
> - Table.PrintHelp(outs(), Argv0, "lld", false);
> + Table.PrintHelp(outs(), Argv0, "lld", false /*ShowHidden*/,
> + true /*ShowAllAliases*/);
> outs() << "\n";
>
> // Scripts generated by Libtool versions up to at least 2.4.6 (the most
>
>
> Index: test/ELF/help.s
> ===================================================================
> --- test/ELF/help.s
> +++ test/ELF/help.s
> @@ -0,0 +1,5 @@
> +# RUN: ld.lld --help 2>&1 | FileCheck -check-prefix=HELP %s
> +# HELP: OPTIONS:
> +# HELP: --output=<value> Path to file to write output
> +# HELP: --output <value> Path to file to write output
> +# HELP: -o <path> Path to file to write output
> Index: ELF/DriverUtils.cpp
> ===================================================================
> --- ELF/DriverUtils.cpp
> +++ ELF/DriverUtils.cpp
> @@ -116,7 +116,8 @@
>
> void elf::printHelp(const char *Argv0) {
> ELFOptTable Table;
> - Table.PrintHelp(outs(), Argv0, "lld", false);
> + Table.PrintHelp(outs(), Argv0, "lld", false /*ShowHidden*/,
> + true /*ShowAllAliases*/);
> outs() << "\n";
>
> // Scripts generated by Libtool versions up to at least 2.4.6 (the most
More information about the llvm-commits
mailing list