Full name of submitter (unless configured in github; will be published with the issue): Yin Xinyu
[basic.stc.dynamic.allocation]/1 says
... An allocation function can be a function template. Such a template shall declare its return type and first parameter as specified above (that is, template parameter types shall not be used in the return type and first parameter type). Allocation function templates shall have two or more parameters.
[basic.stc.dynamic.deallocation]/3 says
... A deallocation function may be an instance of a function template. Neither the first parameter nor the return type shall depend on a template parameter. A deallocation function template shall have two or more function parameters. A template instance is never a usual deallocation function, regardless of its signature.
Is it intentional that
- "allocation function" includes two kinds of entities (functions and function templates), but
- "deallocation function" includes only functions (including instances of a function template)?
Suggested resolution:
Change [basic.stc.dynamic.allocation]/1
... An allocation function can may be an instance of a function template. Such a template shall declare its return type and first parameter as specified above (that is, template parameter types shall not be used in the return type and first parameter type). Allocation function templates shall have two or more parameters.
Full name of submitter (unless configured in github; will be published with the issue): Yin Xinyu
[basic.stc.dynamic.allocation]/1 says
[basic.stc.dynamic.deallocation]/3 says
Is it intentional that
Suggested resolution:
Change [basic.stc.dynamic.allocation]/1