public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug other/10138] -Wuninitialized could catch const* parameters
[not found] <20030318174600.10138.h.b.furuseth@usit.uio.no>
@ 2003-05-24 14:46 ` pinskia@physics.uc.edu
2003-05-24 15:10 ` [Bug other/10138] -Wuninitialized could catch uninitialized arrays pinskia@physics.uc.edu
` (7 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: pinskia@physics.uc.edu @ 2003-05-24 14:46 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10138
------- Additional Comments From pinskia@physics.uc.edu 2003-05-24 14:37 -------
Created an attachment (id=4065)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=4065&action=view)
reduced testcase with one extra case
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/10138] -Wuninitialized could catch uninitialized arrays
[not found] <20030318174600.10138.h.b.furuseth@usit.uio.no>
2003-05-24 14:46 ` [Bug other/10138] -Wuninitialized could catch const* parameters pinskia@physics.uc.edu
@ 2003-05-24 15:10 ` pinskia@physics.uc.edu
2003-05-26 16:47 ` h.b.furuseth@usit.uio.no
` (6 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: pinskia@physics.uc.edu @ 2003-05-24 15:10 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10138
pinskia@physics.uc.edu changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2003-05-24 14:40:31
date| |
Summary|-Wuninitialized could catch |-Wuninitialized could catch
|const* parameters |uninitialized arrays
------- Additional Comments From pinskia@physics.uc.edu 2003-05-24 14:40 -------
confirmed on mainline (20030524). Change title to reflect real bug.
Added another case to the testcases.
gcc should warn about buf in foo and a in g when -Wuninitialized is on.
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/10138] -Wuninitialized could catch uninitialized arrays
[not found] <20030318174600.10138.h.b.furuseth@usit.uio.no>
2003-05-24 14:46 ` [Bug other/10138] -Wuninitialized could catch const* parameters pinskia@physics.uc.edu
2003-05-24 15:10 ` [Bug other/10138] -Wuninitialized could catch uninitialized arrays pinskia@physics.uc.edu
@ 2003-05-26 16:47 ` h.b.furuseth@usit.uio.no
2003-05-26 16:59 ` pinskia@physics.uc.edu
` (5 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: h.b.furuseth@usit.uio.no @ 2003-05-26 16:47 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10138
------- Additional Comments From h.b.furuseth@usit.uio.no 2003-05-26 16:38 -------
Subject: Re: [Bug other/10138] -Wuninitialized could catch uninitialized arrays
pinskia@physics.uc.edu writes:
> Change title to reflect real bug.
Oops, I have reported several suggestions which should be split up:
1) It could report use of uninitialized arrays as you say,
2) it could report pointers to uninitialized variables passed
as const* arguments - as I said, that's almost always an error:
void use(const int *);
void foo(void)
{
int i;
use(&i);
}
3) Finally it could report the combination, as in my original example.
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/10138] -Wuninitialized could catch uninitialized arrays
[not found] <20030318174600.10138.h.b.furuseth@usit.uio.no>
` (2 preceding siblings ...)
2003-05-26 16:47 ` h.b.furuseth@usit.uio.no
@ 2003-05-26 16:59 ` pinskia@physics.uc.edu
2003-05-26 19:11 ` h.b.furuseth@usit.uio.no
` (4 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: pinskia@physics.uc.edu @ 2003-05-26 16:59 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10138
------- Additional Comments From pinskia@physics.uc.edu 2003-05-26 16:48 -------
The second suggestion is already a different bug, and that is why I just changed it to this
one(see bug 179).
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/10138] -Wuninitialized could catch uninitialized arrays
[not found] <20030318174600.10138.h.b.furuseth@usit.uio.no>
` (3 preceding siblings ...)
2003-05-26 16:59 ` pinskia@physics.uc.edu
@ 2003-05-26 19:11 ` h.b.furuseth@usit.uio.no
2004-06-08 19:39 ` [Bug middle-end/10138] " pinskia at gcc dot gnu dot org
` (3 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: h.b.furuseth@usit.uio.no @ 2003-05-26 19:11 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10138
------- Additional Comments From h.b.furuseth@usit.uio.no 2003-05-26 19:05 -------
Subject: Re: [Bug other/10138] -Wuninitialized could catch uninitialized arrays
pinskia@physics.uc.edu writes:
> The second suggestion is already a different bug, and that is why I
> just changed it to this one(see bug 179).
No, bug 179 is a another bug, where - use(&i) would actually prevent
a preceding -Wuninitialized warning. What I'd like is for use(&i)
itself to give a warning.
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug middle-end/10138] -Wuninitialized could catch uninitialized arrays
[not found] <20030318174600.10138.h.b.furuseth@usit.uio.no>
` (4 preceding siblings ...)
2003-05-26 19:11 ` h.b.furuseth@usit.uio.no
@ 2004-06-08 19:39 ` pinskia at gcc dot gnu dot org
2004-09-07 16:57 ` pinskia at gcc dot gnu dot org
` (2 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-06-08 19:39 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-06-08 19:39 -------
*** Bug 15880 has been marked as a duplicate of this bug. ***
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |bangerth at dealii dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10138
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug middle-end/10138] -Wuninitialized could catch uninitialized arrays
[not found] <20030318174600.10138.h.b.furuseth@usit.uio.no>
` (5 preceding siblings ...)
2004-06-08 19:39 ` [Bug middle-end/10138] " pinskia at gcc dot gnu dot org
@ 2004-09-07 16:57 ` pinskia at gcc dot gnu dot org
2004-09-07 22:41 ` bangerth at dealii dot org
2004-10-13 13:39 ` pinskia at gcc dot gnu dot org
8 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-09-07 16:57 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-09-07 16:57 -------
Actually in both cases in this report we don't know if it is really used as an input parameter at all so this
is invalid (even though there is a cast but still).
--
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |INVALID
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10138
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug middle-end/10138] -Wuninitialized could catch uninitialized arrays
[not found] <20030318174600.10138.h.b.furuseth@usit.uio.no>
` (6 preceding siblings ...)
2004-09-07 16:57 ` pinskia at gcc dot gnu dot org
@ 2004-09-07 22:41 ` bangerth at dealii dot org
2004-10-13 13:39 ` pinskia at gcc dot gnu dot org
8 siblings, 0 replies; 9+ messages in thread
From: bangerth at dealii dot org @ 2004-09-07 22:41 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bangerth at dealii dot org 2004-09-07 22:41 -------
I disagree -- the question whether an argument is actually used or not is secondary,
the fact that we pass an uninitialized variable to which only read access is possible
is definitely worth a warning.
W.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|INVALID |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10138
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug middle-end/10138] -Wuninitialized could catch uninitialized arrays
[not found] <20030318174600.10138.h.b.furuseth@usit.uio.no>
` (7 preceding siblings ...)
2004-09-07 22:41 ` bangerth at dealii dot org
@ 2004-10-13 13:39 ` pinskia at gcc dot gnu dot org
8 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-10-13 13:39 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |NEW
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10138
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2004-10-13 13:39 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <20030318174600.10138.h.b.furuseth@usit.uio.no>
2003-05-24 14:46 ` [Bug other/10138] -Wuninitialized could catch const* parameters pinskia@physics.uc.edu
2003-05-24 15:10 ` [Bug other/10138] -Wuninitialized could catch uninitialized arrays pinskia@physics.uc.edu
2003-05-26 16:47 ` h.b.furuseth@usit.uio.no
2003-05-26 16:59 ` pinskia@physics.uc.edu
2003-05-26 19:11 ` h.b.furuseth@usit.uio.no
2004-06-08 19:39 ` [Bug middle-end/10138] " pinskia at gcc dot gnu dot org
2004-09-07 16:57 ` pinskia at gcc dot gnu dot org
2004-09-07 22:41 ` bangerth at dealii dot org
2004-10-13 13:39 ` pinskia at gcc dot gnu dot 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).