Commit 77f6c1eb by Ryan T. Sammartino Committed by Jason Merrill

invoke.texi: explicitly list the style guidelines that -Weffc++ checks for.

        * doc/invoke.texi: explicitly list the style guidelines that
        -Weffc++ checks for.

From-SVN: r49866
parent fd973d56
2002-02-19 Ryan T. Sammartino <ryants@shaw.ca>
* doc/invoke.texi: explicitly list the style guidelines that
-Weffc++ checks for.
Tue Feb 19 12:37:23 CET 2002 Jan Hubicka <jh@suse.cz> Tue Feb 19 12:37:23 CET 2002 Jan Hubicka <jh@suse.cz>
* regmove.c (regmove_optimize): Avoid increasing of register pressure. * regmove.c (regmove_optimize): Avoid increasing of register pressure.
...@@ -660,17 +665,17 @@ Tue Feb 12 10:12:56 2002 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> ...@@ -660,17 +665,17 @@ Tue Feb 12 10:12:56 2002 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
2002-02-11 Aldy Hernandez <aldyh@redhat.com> 2002-02-11 Aldy Hernandez <aldyh@redhat.com>
* config/rs6000/rs6000.c (altivec_init_builtins): Handle * config/rs6000/rs6000.c (altivec_init_builtins): Handle
__builtin_altivec_abs*. __builtin_altivec_abs*.
(bdesc_abs): New. (bdesc_abs): New.
* config/rs6000/rs6000.h (rs6000_builtins): Add * config/rs6000/rs6000.h (rs6000_builtins): Add
ALTIVEC_BUILTIN_ABS*. ALTIVEC_BUILTIN_ABS*.
* config/rs6000/altivec.h: Use const char for builtins expecting * config/rs6000/altivec.h: Use const char for builtins expecting
literals. literals.
(vec_abs): New versions for C and C++. (vec_abs): New versions for C and C++.
(vec_abss): Same. (vec_abss): Same.
2002-02-10 Kazu Hirata <kazu@hxi.com> 2002-02-10 Kazu Hirata <kazu@hxi.com>
...@@ -1937,20 +1942,6 @@ Thu Feb 7 12:14:17 CET 2002 Jan Hubicka <jh@suse.cz> ...@@ -1937,20 +1942,6 @@ Thu Feb 7 12:14:17 CET 2002 Jan Hubicka <jh@suse.cz>
2002-02-05 Jason Merrill <jason@redhat.com> 2002-02-05 Jason Merrill <jason@redhat.com>
* c-typeck.c (convert_for_assignment): Don't allow conversions
between pointers and references. Only allow lvalues to convert to
reference.
* c-decl.c (finish_function): Warn about a non-void function with
no return statement and no abnormal exit.
(current_function_returns_abnormally): New variable.
(start_function): Clear it.
(struct c_language_function): Add returns_abnormally.
(push_c_function_context): Save it.
(pop_c_function_context): Restore it.
* c-tree.h: Declare current_function_returns_abnormally.
* c-typeck.c (build_function_call): Set it.
* collect2.c (dump_file): Pass DMGL_VERBOSE to cplus_demangle. * collect2.c (dump_file): Pass DMGL_VERBOSE to cplus_demangle.
2002-02-05 Andreas Jaeger <aj@suse.de> 2002-02-05 Andreas Jaeger <aj@suse.de>
......
...@@ -1575,10 +1575,44 @@ The following @option{-W@dots{}} options are not affected by @option{-Wall}. ...@@ -1575,10 +1575,44 @@ The following @option{-W@dots{}} options are not affected by @option{-Wall}.
@table @gcctabopt @table @gcctabopt
@item -Weffc++ @r{(C++ only)} @item -Weffc++ @r{(C++ only)}
@opindex Weffc++ @opindex Weffc++
Warn about violations of various style guidelines from Scott Meyers' Warn about violations of the following style guidelines from Scott Meyers'
@cite{Effective C++} books. If you use this option, you should be aware @cite{Effective C++} book:
that the standard library headers do not obey all of these guidelines;
you can use @samp{grep -v} to filter out those warnings. @itemize @bullet
@item
Item 11: Define a copy constructor and an assignment operator for classes
with dynamically allocated memory.
@item
Item 12: Prefer initialization to assignment in constructors.
@item
Item 14: Make destructors virtual in base classes.
@item
Item 15: Have @code{operator=} return a reference to @code{*this}.
@item
Item 23: Don't try to return a reference when you must return an object.
@end itemize
and about violations of the following style guidelines from Scott Meyers'
@cite{More Effective C++} book:
@itemize @bullet
@item
Item 6: Distinguish between prefix and postfix forms of increment and
decrement operators.
@item
Item 7: Never overload @code{&&}, @code{||}, or @code{,}.
@end itemize
If you use this option, you should be aware that the standard library
headers do not obey all of these guidelines; you can use @samp{grep -v}
to filter out those warnings.
@item -Wno-deprecated @r{(C++ only)} @item -Wno-deprecated @r{(C++ only)}
@opindex Wno-deprecated @opindex Wno-deprecated
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment