This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug ada/35503] New: Warning about restricted pointers?
- From: "samuel dot thibault at ens-lyon dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 8 Mar 2008 01:49:12 -0000
- Subject: [Bug ada/35503] New: Warning about restricted pointers?
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
I've again seen some code like this: sprintf(buf, "%s-%s", buf, to_add); and
gcc doesn't complain, even though the declaration of sprintf is extern int
sprintf (char *__restrict __s, __const char *__restrict __format, ...);
Wouldn't it be possible for gcc to check the enforcement of restricted pointer,
at least in the trivial cases like this one?
--
Summary: Warning about restricted pointers?
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: ada
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: samuel dot thibault at ens-lyon dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35503