Now prints the list of known archs. This requires plumbing a Driver
arg through a few functions.
Also add two more convenience insert() overlods to StringMap.
Paths
| Differential D109105
[clang-cl] Emit nicer warning on unknown /arch: arguments ClosedPublic Authored by thakis on Sep 1 2021, 4:05 PM.
Details Summary Now prints the list of known archs. This requires plumbing a Driver Also add two more convenience insert() overlods to StringMap.
Diff Detail Event TimelineHerald added subscribers: dexonsmith, Jim, atanasyan and 5 others. · View Herald TranscriptSep 1 2021, 4:05 PM Comment Actions lgtm, nice!
This revision is now accepted and ready to land.Sep 2 2021, 7:01 AM Closed by commit rG973519826edb: [clang-cl] Emit nicer warning on unknown /arch: arguments (authored by thakis). · Explain WhySep 2 2021, 7:37 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 370128 clang/include/clang/Basic/DiagnosticDriverKinds.td
clang/lib/Driver/ToolChains/AVR.cpp
clang/lib/Driver/ToolChains/Arch/Mips.h
clang/lib/Driver/ToolChains/Arch/Mips.cpp
clang/lib/Driver/ToolChains/Arch/X86.h
clang/lib/Driver/ToolChains/Arch/X86.cpp
clang/lib/Driver/ToolChains/Clang.cpp
clang/lib/Driver/ToolChains/CommonArgs.h
clang/lib/Driver/ToolChains/CommonArgs.cpp
clang/lib/Driver/ToolChains/FreeBSD.cpp
clang/lib/Driver/ToolChains/Gnu.cpp
clang/lib/Driver/ToolChains/Linux.cpp
clang/lib/Driver/ToolChains/NetBSD.cpp
clang/lib/Driver/ToolChains/OpenBSD.cpp
clang/test/Driver/cl-x86-flags.c
llvm/include/llvm/ADT/StringMap.h
|
nit: i think typename is more common than class in llvm code
unittests/ADT/StringMapTest.cpp has tests for the insert methods, maybe it's worth adding one for this too (or the initializer_list one perhaps) even though it's pretty trivial?