This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/47319] New: typo in gcc/except.c from r151696?
- From: "howarth at nitro dot med.uc.edu" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 16 Jan 2011 19:53:56 +0000
- Subject: [Bug middle-end/47319] New: typo in gcc/except.c from r151696?
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47319
Summary: typo in gcc/except.c from r151696?
Product: gcc
Version: 4.6.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: middle-end
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: howarth@nitro.med.uc.edu
While building gcc trunk with --enable-build-with-cxx, the additional g++
warnings highlighted a potential typo in gcc/except.c from r151696.
g++ -c -g -DIN_GCC -W -Wall -Wwrite-strings -Wcast-qual
-Wmissing-format-attribute -pedantic -Wno-long-long -Wno-variadic-macros
-Wno-overlength-strings -fno-common -DHAVE_CONFIG_H -I. -I.
-I../../gcc-4.6-20110116/gcc -I../../gcc-4.6-20110116/gcc/.
-I../../gcc-4.6-20110116/gcc/../include
-I../../gcc-4.6-20110116/gcc/../libcpp/include -I/sw/include -I/sw/include
-I../../gcc-4.6-20110116/gcc/../libdecnumber
-I../../gcc-4.6-20110116/gcc/../libdecnumber/dpd -I../libdecnumber
-I/sw/include -I/sw/include -DCLOOG_INT_GMP -DCLOOG_ORG -I/sw/include
../../gcc-4.6-20110116/gcc/fixed-value.c -o fixed-value.o
../../gcc-4.6-20110116/gcc/except.c: In function 'void dump_eh_tree(FILE*,
function*)':
../../gcc-4.6-20110116/gcc/except.c:3197: warning: suggest a space before ';'
or explicit braces around empty body in 'for' statement
../../gcc-4.6-20110116/gcc/dwarf2out.c: In function 'void
output_die(die_struct*)':
../../gcc-4.6-20110116/gcc/dwarf2out.c:11184: warning: format not a string
literal and no format arguments
highlights a bracing oddity in dump_eh_tree() introduced by...
r151696 | rth | 2009-09-14 15:18:58 -0400 (Mon, 14 Sep 2009) | 1 line
Squash commit of EH in gimple
where we now have...
if (i->landing_pads)
{
eh_landing_pad lp;
fprintf (out, " land:");
if (current_ir_type () == IR_GIMPLE)
{
for (lp = i->landing_pads; lp ; lp = lp->next_lp)
{
fprintf (out, "{%i,", lp->index);
print_generic_expr (out, lp->post_landing_pad, 0);
fputc ('}', out);
if (lp->next_lp)
fputc (',', out);
}
}
else
{
for (lp = i->landing_pads; lp ; lp = lp->next_lp);
{
fprintf (out, "{%i,", lp->index);
if (lp->landing_pad)
fprintf (out, "%i%s,", INSN_UID (lp->landing_pad),
NOTE_P (lp->landing_pad) ? "(del)" : "");
else
fprintf (out, "(nil),");
if (lp->post_landing_pad)
{
rtx lab = label_rtx (lp->post_landing_pad);
fprintf (out, "%i%s}", INSN_UID (lab),
NOTE_P (lab) ? "(del)" : "");
}
else
fprintf (out, "(nil)}");
if (lp->next_lp)
fputc (',', out);
}
}
}
and the line
for (lp = i->landing_pads; lp ; lp = lp->next_lp);
seems odd given the existing bracing that follows.