summaryrefslogtreecommitdiff
path: root/libiberty/regex.c
diff options
context:
space:
mode:
authorMartin Thuresson <martint@google.com>2009-10-01 01:20:13 +0000
committerNeil Vachharajani <nvachhar@gcc.gnu.org>2009-10-01 01:20:13 +0000
commit4578037eb7b14062b4c1a5bafccc13893c11561c (patch)
tree84d1914db546f894b1634e8556a864003486304a /libiberty/regex.c
parentf2f49be3bba2c893e23b6933cb376c1de1f0b917 (diff)
downloadgcc-4578037eb7b14062b4c1a5bafccc13893c11561c.tar.gz
regex.c (byte_re_match_2_internal): Split declaration and assignment to avoid -Wc++-compat warning due to goto.
2009-09-30 Martin Thuresson <martint@google.com> * regex.c (byte_re_match_2_internal): Split declaration and assignment to avoid -Wc++-compat warning due to goto. From-SVN: r152354
Diffstat (limited to 'libiberty/regex.c')
-rw-r--r--libiberty/regex.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/libiberty/regex.c b/libiberty/regex.c
index fa1df197ce9..ad496846904 100644
--- a/libiberty/regex.c
+++ b/libiberty/regex.c
@@ -5910,11 +5910,14 @@ byte_re_match_2_internal (struct re_pattern_buffer *bufp,
{
/* 1 if this match ends in the same string (string1 or string2)
as the best previous match. */
- boolean same_str_p = (FIRST_STRING_P (match_end)
- == MATCHING_IN_FIRST_STRING);
+ boolean same_str_p;
+
/* 1 if this match is the best seen so far. */
boolean best_match_p;
+ same_str_p = (FIRST_STRING_P (match_end)
+ == MATCHING_IN_FIRST_STRING);
+
/* AIX compiler got confused when this was combined
with the previous declaration. */
if (same_str_p)