[#BloombergLP-bslstl-Function_ArgTypes-06] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslstl.adoc[bslstl]::Function_ArgTypes :relfileprefix: ../../ :mrdocs: This component‐private struct template provides the following nested typedefs for `bsl::function` for a specified `PROTOTYPE` which must be a function type: ` argument_type ‐‐ Only if PROTOTYPE takes exactly one argument first_argument_type ‐‐ Only if PROTOTYPE takes exactly two arguments second_argument_type ‐‐ Only if PROTOTYPE takes exactly two arguments ` The C++ Standard requires that `function` define these typedefs for compatibility with one‐ and two‐argument legacy (now deprecated) functor adaptors. `bsl::function` publicly inherits from an instantiation of this template in order to conditionally declare the above nested types. This primary (unspecialized) template provides no typedefs. == Synopsis Declared in `<bslstl_function.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class PROTOTYPE> struct Function_ArgTypes; ---- == Specializations [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bslstl/Function_ArgTypes-05.adoc[`Function_ArgTypes<RET(ARG)>`] | This component‐private specialization of `Function_ArgTypes` is for function prototypes that take exactly one argument and provides an `argument_type` nested typedef. | xref:BloombergLP/bslstl/Function_ArgTypes-0d.adoc[`Function_ArgTypes<RET(ARG1, ARG2)>`] | This component‐private specialization of `Function_ArgTypes` is for functions that take exactly two arguments and provides `first_argument_type` and `second_argument_type` nested typedefs. |=== == Derived Classes [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bslstl/Function_Variadic-08.adoc[`Function_Variadic<RET(ARGS...)>`] | This component‐private class template contains the physical representation and provides the variadic interfaces for `bsl::function` (see class and component documentation for `bsl::function`). `bsl::function` publicly inherits from an instantiation of this template. This implementation class exists to 1) minimize the amount of variadic template expansion required in C++03 using the `sim_cpp11_features.pl` utility and 2) work around issues with the Sun CC compiler, which has trouble with argument type deduction when a template argument has a partial specialization (as `Function_Variadic` does). `bsl::function` does not have a partial specialization and delegates to the `Function_Variadic` base class only those parts of the interface and implementation that depend on decomposing the function prototype into a return type and variadic list of argument types. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#