[PATCH] D25068: [coroutines] Switch to using std::experimental namespace per P0057R5

Richard Smith via cfe-commits cfe-commits at lists.llvm.org
Fri Sep 30 16:29:38 PDT 2016

rsmith added inline comments.

> SemaDeclCXX.cpp:8157-8160
> +               CurContext->getRedeclContext()->isStdNamespace()) {
> +      PrevNS = getStdExperimentalNamespace();
> +      IsStdExperimental = true;
> +      AddToKnown = !IsInline;

If you're going to track the namespace on creation, you need to add serialization code for your `Sema::StdExperimentalNamespace` storage. But I'd suggest taking a different approach: just treat this as a cache, and do a lookup for `experimental` within namespace `std` if the namespace is requested and not in the cache.


More information about the cfe-commits mailing list