[flang] Add -h as a synonym for help

As expected by user in http://lists.llvm.org/pipermail/flang-dev/2020-June/000404.html

Depends on D84856

Differential Revision: https://reviews.llvm.org/D84857
This commit is contained in:
Richard Barton 2020-07-18 14:22:18 +01:00
parent b068d19a15
commit 30e45f339e
2 changed files with 2 additions and 1 deletions

View File

@ -1,3 +1,4 @@
! RUN: %f18 -h 2>&1 | FileCheck %s
! RUN: %f18 -help 2>&1 | FileCheck %s
! RUN: %f18 --help 2>&1 | FileCheck %s
! RUN: %f18 -? 2>&1 | FileCheck %s

View File

@ -603,7 +603,7 @@ int main(int argc, char *const argv[]) {
driver.getSymbolsSources = true;
} else if (arg == "-byteswapio") {
driver.byteswapio = true; // TODO: Pass to lowering, generate call
} else if (arg == "-help" || arg == "--help" || arg == "-?") {
} else if (arg == "-h" || arg == "-help" || arg == "--help" || arg == "-?") {
llvm::errs()
<< "f18: LLVM Fortran compiler\n"
<< "\n"