[customization.point.object] (original) (raw)
16 Library introduction [library]
16.3 Method of description [description]
16.3.3 Other conventions [conventions]
16.3.3.3 Type descriptions [type.descriptions]
16.3.3.3.5 Customization Point Object types [customization.point.object]
A customization point object is a function object ([function.objects]) with a literal class type that interacts with program-defined types while enforcing semantic requirements on that interaction.
All instances of a specific customization point object type shall be equal ([concepts.equality]).
The effects of invoking different instances of a specific customization point object type on the same arguments are equivalent.
The type T of a customization point object, ignoring cv-qualifiers, shall modelinvocable<T&, Args...>,invocable<const T&, Args...>,invocable<T, Args...>, andinvocable<const T, Args...> ([concept.invocable]) when the types in Args... meet the requirements specified in that customization point object's definition.
When the types of Args... do not meet the customization point object's requirements, T shall not have a function call operator that participates in overload resolution.
For a given customization point object o, let p be a variable initialized as if by auto p = o;.
Then for any sequence of arguments args..., the following expressions have effects equivalent to o(args...):
- p(args...)
- as_const(p)(args...)
- std::move(p)(args...)
- std::move(as_const(p))(args...)