Adjust some comments, add some explicit fall through comments or explicit
returns where necessary to not get implicit-fallthrough warnings.
All fall throughs were deliberate. In one case I added an explicit return
false for clarity instead of falling through a default case (that also
would return false).
libiberty/ChangeLog:
* cplus-dem.c (demangle_signature): Move fall through comment.
(demangle_fund_type): Add fall through comment between 'G' and 'I'.
* hashtab.c (iterative_hash): Add fall through comments.
* regex.c (regex_compile): Add Fall through comment after '+'/'?'.
(byte_re_match_2_internal): Add Fall through comment after jump_n.
Change "Note fall through" to "Fall through".
(common_op_match_null_string_p): Return false after set_number_at
instead of fall through.
From-SVN: r241864
* regex.c (bzero) [!_LIBC]: Define without coma expression.
(regerror): Cast the call to memcpy to (void) to avoid unused
value warnings.
From-SVN: r208553
Change "if (E) free (E);" to "free (E);" everywhere except in the
libgo/, intl/, zlib/ and classpath/ directories.
Also transform equivalent variants like
"if (E != NULL) free (E);" and allow an extra cast on the
argument to free. Otherwise, the tested and freed "E"
expressions must be identical, modulo white space.
From-SVN: r172785
* tree-ssa-pre.c (my_rev_post_order_compute): Remove set but not
used count variable.
* genemit.c (gen_expand, gen_split): Avoid set but not used warnings
when operandN variables aren't used in the body of the expander
or splitter.
* tree-outof-ssa.c (FOR_EACH_ELIM_GRAPH_SUCC,
FOR_EACH_ELIM_GRAPH_PRED): Avoid set but not used warnings.
* tree-ssa-operands.h (FOR_EACH_SSA_TREE_OPERAND): Likewise.
* tree-flow.h (FOR_EACH_IMM_USE_FAST, FOR_EACH_IMM_USE_STMT,
FOR_EACH_IMM_USE_ON_STMT): Likewise.
* tree.h (FOR_EACH_CONSTRUCTOR_ELT): Likewise.
* tree.c (PROCESS_ARG): Likewise.
fortran/
* parse.c (parse_derived, parse_enum): Avoid set but not used
warning.
java/
* expr.c (process_jvm_instruction): Avoid set but not used warning.
* builtins.c (compareAndSwapInt_builtin, compareAndSwapLong_builtin,
getVolatile_builtin): Likewise.
libjava/
* exception.cc (_Jv_Throw): Avoid set but not used warning.
* include/java-assert.h (JvAssertMessage, JvAssert): Use argument in
sizeof to avoid set but not used warnings.
libjava/classpath/
* native/jni/midi-alsa/gnu_javax_sound_midi_alsa_AlsaPortDevice.c
(Java_gnu_javax_sound_midi_alsa_AlsaPortDevice_run_1receiver_1thread_1):
Avoid set but not used warning.
libiberty/
* regex.c (byte_re_match_2_internal): Avoid set but not used
warning.
gcc/testsuite/
* gcc.dg/builtin-choose-expr.c: Avoid set but not used warnings.
* gcc.dg/trunc-1.c: Likewise.
* gcc.dg/vla-9.c: Likewise.
* gcc.dg/dfp/composite-type.c: Likewise.
libffi/
* testsuite/libffi.call/err_bad_abi.c: Remove unused args variable.
From-SVN: r158084
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
* objalloc.c, strsignal.c, xstrerror.c: Include "config.h" before
"ansidecl.h" to avoid redeclaration errors with native compilers.
* regex.c: Protect config.h from multiple inclusion.
From-SVN: r90954
* regex.c (re_error_msgid): Just use a simple array of strings.
(re_compile_pattern): Compensate.
(re_comp): Likewise.
(re_comp): Likewise.
(regerror): Likewise.
From-SVN: r56106
* config.in (HAVE_UINTPTR_T): Provide autoconf stub.
* configure.in (HAVE_UINTPTR_T): Test for system defining
uintptr_t and define HAVE_UINTPTR_T appropriately.
* regex.c (uintptr_t): Do not provide a definition if the
system provided one.
From-SVN: r47068
2001-11-12 Jim Meyering <meyering@lucent.com>
* obstack.c (_): Honor the setting of ENABLE_NLS. Otherwise,
this code would end up calling gettext even in packages built
with --disable-nls.
* getopt.c (_): Likewise.
* regex.c (_): Likewise.
From-SVN: r46975
Merge from libc:
* regex.c (wcs_regex_compile): Use appropriate string
to compare with collating element.
Fix the padding for the alignment.
From-SVN: r44838
Merge from glibc:
* regex.c: Declare wcs functions only if compiling with
MBS_SUPPORT.
Don't use #elif for traditional C.
* regex.c: Revamp memory allocation for WCHAR functions to
not use too much stack.
From-SVN: r44471