[PATCH] D105786: [lld-macho][nfc] Avoid using std::map for PlatformKinds
Jez Ng via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Jul 11 15:22:18 PDT 2021
int3 marked an inline comment as done.
int3 added inline comments.
================
Comment at: lld/MachO/Driver.cpp:854
- static const std::map<PlatformKind, VersionTuple> minVersion = {
+ static const std::vector<std::pair<PlatformKind, VersionTuple>> minVersion = {
{PlatformKind::macOS, VersionTuple(10, 15)},
{PlatformKind::iOS, VersionTuple(13, 0)},
----------------
thakis wrote:
> I agree that a switch seems like the obvious fit here, but *shrug*
okay yeah I forgot that we don't need an extra line for `break` since we can return early. changing
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105786/new/
https://reviews.llvm.org/D105786
More information about the llvm-commits
mailing list