public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/50720] New: "deprecated" doesn't work as expected for functions returning pointer
@ 2011-10-13 20:25 bhelgaas at google dot com
2012-01-07 22:23 ` [Bug c/50720] " pinskia at gcc dot gnu.org
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: bhelgaas at google dot com @ 2011-10-13 20:25 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50720
Bug #: 50720
Summary: "deprecated" doesn't work as expected for functions
returning pointer
Classification: Unclassified
Product: gcc
Version: 4.4.3
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: bhelgaas@google.com
I expected warnings on each of the four function calls below, but I only got
three warnings (the one for "old_fn1a" is missing).
$ cat x.c
struct foo { int bar; };
struct foo * __attribute__ ((deprecated)) old_fn1a();
struct foo * old_fn1b() __attribute__ ((deprecated));
int __attribute__ ((deprecated)) old_fn2a();
int old_fn2b() __attribute__ ((deprecated));
void test(void)
{
old_fn1a();
old_fn1b();
old_fn2a();
old_fn2b();
}
$ cc -c x.c
x.c: In function ‘test’:
x.c:12: warning: ‘old_fn1b’ is deprecated (declared at x.c:4)
x.c:13: warning: ‘old_fn2a’ is deprecated (declared at x.c:6)
x.c:14: warning: ‘old_fn2b’ is deprecated (declared at x.c:7)
$ cc -v
Using built-in specs.
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 4.4.3-4ubuntu5'
--with-bugurl=file:///usr/share/doc/gcc-4.4/README.Bugs
--enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --enable-shared
--enable-multiarch --enable-linker-build-id --with-system-zlib
--libexecdir=/usr/lib --without-included-gettext --enable-threads=posix
--with-gxx-include-dir=/usr/include/c++/4.4 --program-suffix=-4.4 --enable-nls
--enable-clocale=gnu --enable-libstdcxx-debug --enable-plugin --enable-objc-gc
--disable-werror --with-arch-32=i486 --with-tune=generic
--enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu
--target=x86_64-linux-gnu
Thread model: posix
gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5)
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c/50720] "deprecated" doesn't work as expected for functions returning pointer
2011-10-13 20:25 [Bug c/50720] New: "deprecated" doesn't work as expected for functions returning pointer bhelgaas at google dot com
@ 2012-01-07 22:23 ` pinskia at gcc dot gnu.org
2013-03-22 14:47 ` jakub at gcc dot gnu.org
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu.org @ 2012-01-07 22:23 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50720
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |4.8.0
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> 2012-01-07 22:23:37 UTC ---
struct foo * __attribute__ ((deprecated)) old_fn1a();
The attribute there applies to the pointer ...
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c/50720] "deprecated" doesn't work as expected for functions returning pointer
2011-10-13 20:25 [Bug c/50720] New: "deprecated" doesn't work as expected for functions returning pointer bhelgaas at google dot com
2012-01-07 22:23 ` [Bug c/50720] " pinskia at gcc dot gnu.org
@ 2013-03-22 14:47 ` jakub at gcc dot gnu.org
2013-05-31 11:00 ` jakub at gcc dot gnu.org
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: jakub at gcc dot gnu.org @ 2013-03-22 14:47 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50720
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.8.0 |4.8.1
--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> 2013-03-22 14:45:34 UTC ---
GCC 4.8.0 is being released, adjusting target milestone.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c/50720] "deprecated" doesn't work as expected for functions returning pointer
2011-10-13 20:25 [Bug c/50720] New: "deprecated" doesn't work as expected for functions returning pointer bhelgaas at google dot com
2012-01-07 22:23 ` [Bug c/50720] " pinskia at gcc dot gnu.org
2013-03-22 14:47 ` jakub at gcc dot gnu.org
@ 2013-05-31 11:00 ` jakub at gcc dot gnu.org
2013-10-16 9:50 ` jakub at gcc dot gnu.org
2015-06-22 14:26 ` rguenth at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: jakub at gcc dot gnu.org @ 2013-05-31 11:00 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50720
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.8.1 |4.8.2
--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 4.8.1 has been released.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c/50720] "deprecated" doesn't work as expected for functions returning pointer
2011-10-13 20:25 [Bug c/50720] New: "deprecated" doesn't work as expected for functions returning pointer bhelgaas at google dot com
` (2 preceding siblings ...)
2013-05-31 11:00 ` jakub at gcc dot gnu.org
@ 2013-10-16 9:50 ` jakub at gcc dot gnu.org
2015-06-22 14:26 ` rguenth at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: jakub at gcc dot gnu.org @ 2013-10-16 9:50 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50720
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.8.2 |4.8.3
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 4.8.2 has been released.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c/50720] "deprecated" doesn't work as expected for functions returning pointer
2011-10-13 20:25 [Bug c/50720] New: "deprecated" doesn't work as expected for functions returning pointer bhelgaas at google dot com
` (3 preceding siblings ...)
2013-10-16 9:50 ` jakub at gcc dot gnu.org
@ 2015-06-22 14:26 ` rguenth at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: rguenth at gcc dot gnu.org @ 2015-06-22 14:26 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=50720
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.8.3 |---
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2015-06-22 14:26 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-10-13 20:25 [Bug c/50720] New: "deprecated" doesn't work as expected for functions returning pointer bhelgaas at google dot com
2012-01-07 22:23 ` [Bug c/50720] " pinskia at gcc dot gnu.org
2013-03-22 14:47 ` jakub at gcc dot gnu.org
2013-05-31 11:00 ` jakub at gcc dot gnu.org
2013-10-16 9:50 ` jakub at gcc dot gnu.org
2015-06-22 14:26 ` rguenth at gcc dot gnu.org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).