bloomberg / clang-p2996

Experimental clang support for WG21 P2996 (Reflection).
https://github.com/bloomberg/clang-p2996/tree/p2996/P2996.md
51 stars 8 forks source link

Rename RK_const_value to RK_expr_result #47

Closed katzdm closed 3 months ago

katzdm commented 3 months ago

P2996R3 drops "reflections of expressions", and makes it clear that what's reflected is a "result of evaluating an expression" - which can either be a value (if evaluated from a prvalue) or an object (if evaluated from an lvalue). As a bit of cleanup, it'd be nice to everywhere change the nomenclature from RK_const_value (and getReflectedConstValueExpr, etc) to RK_expr_result.

Still not clear whether storing this in a ConstantExpr was the smartest decision, but it doesn't seem to be getting in the way as of yet.