Am Dienstag, 3. März 2026, 16:59:12 Mitteleuropäische Normalzeit schrieb Marek Polacek: > Interesting, thanks. Dan pointed me to > https://cplusplus.github.io/LWG/issue4496 > so we should be saying "reachable" rather than "precedes" which is about > name lookup.
But, as far as i can tell, there is no direct effect on members-of-precedes.
I would argue, that using reachable here would break module boundaries:
export module A;
namespace NS {
struct impl_with_side_effects {
// ...
}
export class S {
protected:
const std::unique_ptr<impl_with_side_effects> impl;
// ....
}
// main.c
import A;
import std;
consteval void reflect_ns() {
for (auto member : members_of(^^NS)) {
// [[: member ]] into existence
}
}
Would this be legal? Are there any limitations on slice operations?
Thomas
signature.asc
Description: This is a digitally signed message part.
