This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH, c++ diagnostics] Fix c++ front end i18n problems


On Mon, Nov 30, 2009 at 9:51 PM, Shujing Zhao <pearly.zhao@oracle.com> wrote:
> Hi all,
>
> This patch is refined and adjusted Paolo Bonzini's old patch
> http://gcc.gnu.org/ml/gcc-patches/2002-06/msg01620.html.
>
> As discussed before, this patch abandon using string fragments.
> Use "candidates are" only when there are more than one candidate, otherwise
> use "candidate is".
> The "candidates are" isn't printed in a separate line, because the error
> will be reported at a different line. That would cause many test cases need
> to be adjust the report line of "candidates are". I think this change is not
> very necessary.
> Function readonly_error accept an enum as argument, and use a macros to emit
> the diagnostics.
> Function op_error accept bool as argument, not int.
> Use _() to fix the i18n problems.

Change readonly_error_str to readonly_error_kind (and adjust the prefix RES_).
I do not understand the renaming from function_category to in_function.
Instead of duplicating the test for deciding "candidates are" or
"candidate is", please
abstract that decision in a separate function.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]