Skip to content

Commit 30e45f3

Browse files
[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
1 parent b068d19 commit 30e45f3

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

flang/test/Driver/help.f90

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
! RUN: %f18 -h 2>&1 | FileCheck %s
12
! RUN: %f18 -help 2>&1 | FileCheck %s
23
! RUN: %f18 --help 2>&1 | FileCheck %s
34
! RUN: %f18 -? 2>&1 | FileCheck %s

flang/tools/f18/f18.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -603,7 +603,7 @@ int main(int argc, char *const argv[]) {
603603
driver.getSymbolsSources = true;
604604
} else if (arg == "-byteswapio") {
605605
driver.byteswapio = true; // TODO: Pass to lowering, generate call
606-
} else if (arg == "-help" || arg == "--help" || arg == "-?") {
606+
} else if (arg == "-h" || arg == "-help" || arg == "--help" || arg == "-?") {
607607
llvm::errs()
608608
<< "f18: LLVM Fortran compiler\n"
609609
<< "\n"

0 commit comments

Comments
 (0)