]> Savannah Git Hosting - gnulib.git/commit
attribute: const/pure defaults to unsequenced/reproducible
authorPaul Eggert <eggert@cs.ucla.edu>
Tue, 28 May 2024 15:36:28 +0000 (08:36 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Tue, 28 May 2024 15:37:22 +0000 (08:37 -0700)
commit2afd8b474071dd8ee66ee9bbaf1480b599390ddd
tree6928c64b8a44b88fa946f39a69e7dacd3453995d
parentad61731042a23c0ca31e14b6666e99c0dcc49468
attribute: const/pure defaults to unsequenced/reproducible

Also, update the commentary to reflect the fact that unsequenced
and reproducible functions can inspect and update storage
addressed by their arguments, and clarify the business about
returning once, and about REPRODUCIBLE and UNSEQUENCED applying to
pointers to functions and to function types.  It’s not clear that
we should encourage the use of REPRODUCIBLE and UNSEQUENCED yet,
as the support is not there and the likely benefits are small.
* m4/gnulib-common.m4 (_GL_ATTRIBUTE_CONST): Default to
_GL_ATTRIBUTE_UNSEQUENCED if the const attribute is lacking,
as every const function is also unsequenced.
(_GL_ATTRIBUTE_PURE): Similarly, default to _GL_ATTRIBUTE_REPRODUCIBLE
as every pure function is reproducible.
ChangeLog
m4/gnulib-common.m4