[libcxx-commits] [PATCH] D99789: [libc++] Add fallback standard flags and normalize corresponding feature.
Louis Dionne via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Apr 6 09:10:39 PDT 2021
ldionne added inline comments.
================
Comment at: libcxx/utils/libcxx/test/params.py:58-62
+ Parameter(name='std', choices=_allStandardsAndFallbacks, type=str,
help="The version of the standard to compile the test suite with.",
- default=lambda cfg: next(s for s in reversed(_allStandards) if hasCompileFlag(cfg, '-std='+s)),
+ default=lambda cfg: getLatestStdFlag(cfg),
actions=lambda std: [
+ AddFeature(_undoStandardFallback[std] if std in _undoStandardFallback else std),
----------------
curdeius wrote:
> curdeius wrote:
> > curdeius wrote:
> > > ldionne wrote:
> > > >
> > > Unless I'm mistaken, we still need to call `AddFeature`, no? @ldionne
> > Also, in actions, I don't have `cfg`, only `std`...
> WDYT about:
> ```
> AddFeature(next((s for s, f in reversed(_allStandards) if f == std), std)),
> ```
> ?
Yeah, it seems I really botched my code change suggestion :-).
Basically anything that works is fine by me, but I found the logic with multiple variables at the beginning of the file to be hard to follow.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D99789/new/
https://reviews.llvm.org/D99789
More information about the libcxx-commits
mailing list