This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/18487] Warnings for pure and const functions that are not actually pure or const
- From: "jakub at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 22 Jan 2015 07:17:11 +0000
- Subject: [Bug tree-optimization/18487] Warnings for pure and const functions that are not actually pure or const
- Auto-submitted: auto-generated
- References: <bug-18487-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=18487
--- Comment #12 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
And then there is the case of endless loops in such functions (either
unconditional, or ones the compiler is not able to detect), exit calls, both
either directly in the const/pure function or in some function it calls. So in
all, I'm afraid such a warning would diagnose only the most trivial cases.