Title
Clarify `expr` and `fn` for `meta::reflect_object` and `meta::reflect_function`
Status
wp
Section
[meta.reflection.result]
Submitter
Tomasz Kamiński

Created on 2025-11-04.00:00:00 last changed 1 month ago

Messages

Date: 2025-11-11.10:48:55

Proposed resolution:

This wording is relative to N5014.

  1. Modify [meta.reflection.result] as indicated:

    template<class T>
      consteval info reflect_object(T& expr);
    

    -7- Mandates: `T` is an object type.

    -8- Returns: A reflection of the object designated by `expr`.

    -9- Throws: `meta::exception` unless `expr` is if `E` is not suitable for use as a constant template argument for a constant template parameter of type T& ([temp.arg.nontype]) , where `E` is an lvalue constant expression that computes the object that `expr` refers to.

    template<class T>
      consteval info reflect_function(T& fn);
    

    -10- Mandates: `T` is an function type.

    -11- Returns: A reflection of the function designated by `fn`.

    -12- Throws: `meta::exception` unless `fn` is if `F` is not suitable for use as a constant template argument for a constant template parameter of type T& ([temp.arg.nontype]) , where `F` is an lvalue constant expression that computes the function that `fn` refers to.

Date: 2025-11-11.10:48:55

[ Kona 2025-11-08; Status changed: Immediate → WP. ]

Date: 2025-11-04.19:48:09

[ Kona 2025-11-04; approved by LWG. Status changed: New → Immediate. ]

Date: 2025-11-04.00:00:00
Addresses US 118-179

This should talk about the object/function designated by `expr`/`fn`, rather than `expr`/`fn`.

History
Date User Action Args
2025-11-11 10:48:55adminsetmessages: + msg15695
2025-11-11 10:48:55adminsetstatus: immediate -> wp
2025-11-04 19:48:09adminsetmessages: + msg15499
2025-11-04 19:48:09adminsetstatus: new -> immediate
2025-11-04 19:36:20adminsetmessages: + msg15496
2025-11-04 00:00:00admincreate