This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix PR c++/19989 (4.0/4.1 regression)
- From: Mark Mitchell <mark at codesourcery dot com>
- To: Josh Conner <jconner at apple dot com>
- Cc: gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 02 Nov 2005 23:06:23 -0800
- Subject: Re: [PATCH] Fix PR c++/19989 (4.0/4.1 regression)
- References: <4369639A.4080404@apple.com>
Josh Conner wrote:
> + if (integer_zerop (max) && !(complain & tf_error))
> {
> - /* Still allow an explicit array of size zero. */
> - if (pedantic)
> - pedwarn ("creating array with size zero");
> + /* We must fail if performing argument deduction (as
> + indicated by the state of complain), so that
> + another substitution can be found. */
> + return error_mark_node;
> }
The GNU coding standards are that if there is only one dependent
statement, then there should be no braces. So, just:
if (...)
/* Comment... */
return error_mark_node;
Make that change (no need to fully retest; just run your test cases to
make sure they still work) and check in.
Thanks,
--
Mark Mitchell
CodeSourcery, LLC
mark@codesourcery.com
(916) 791-8304