https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83503

--- Comment #12 from Martin Sebor <msebor at gcc dot gnu.org> ---
AFAIK, specifying attribute const and pure on a function definition has no
effect on the code emitted for the function itself or on its callers in other
translation units, so what you describe doesn't sound meaningful.

It's fine, though pointless, to declare a function pure and define it so that
it meets stricter requirements under some conditions, just as long as the
attributes don't clash.

Reply via email to