Message ID | AANLkTinG2-c13a1mki40ULmj91hXaoMCrpRu37WqLPkL@mail.gmail.com |
---|---|
State | New |
Headers | show |
This obvious, you do not need anyone's approval for such a change. Go for it! Manuel. On 28 June 2010 21:05, Andrew Pinski <pinskia@gmail.com> wrote: > I caught this comment fix when I was looking at c-common.h. > diagnostic-core.h is now the file which contains error/warning/sorry > rather than toplev.h. > > OK? > > Thanks, > Andrew Pinski > > ChangeLog: > * c-common.h: Update comment for the location change of the diagnostic > functions. >
Actually, I am wrong. Since toplev.h still includes diagnostic-core.h, this is still true. So common.h has to be included before both toplev.h and diagnostic-core.h BTW, check the top of cp-tree.h for the check that I added to better diagnose this problem. I guess it applies here also. Cheers, Manuel. On 28 June 2010 21:16, Manuel López-Ibáñez <lopezibanez@gmail.com> wrote: > This obvious, you do not need anyone's approval for such a change. Go for it! > > Manuel. > > On 28 June 2010 21:05, Andrew Pinski <pinskia@gmail.com> wrote: >> I caught this comment fix when I was looking at c-common.h. >> diagnostic-core.h is now the file which contains error/warning/sorry >> rather than toplev.h. >> >> OK? >> >> Thanks, >> Andrew Pinski >> >> ChangeLog: >> * c-common.h: Update comment for the location change of the diagnostic >> functions. >> >
On Mon, 28 Jun 2010, Andrew Pinski wrote: > I caught this comment fix when I was looking at c-common.h. > diagnostic-core.h is now the file which contains error/warning/sorry > rather than toplev.h. > > OK? Although the changed comment is true, various C files still include toplev.h instead of or as well as diagnostic-core.h, so the comment is also true as it is. If toplev.h is stopped from including diagnostic-core.h, and diagnostic-core.h includes are added to files that include toplev.h (replacing the toplev.h include, in some cases), then it would indeed be necessary to change this comment to reference diagnostic-core.h.
On 28 June 2010 21:32, Joseph S. Myers <joseph@codesourcery.com> wrote: > On Mon, 28 Jun 2010, Andrew Pinski wrote: > >> I caught this comment fix when I was looking at c-common.h. >> diagnostic-core.h is now the file which contains error/warning/sorry >> rather than toplev.h. >> >> OK? > > Although the changed comment is true, various C files still include > toplev.h instead of or as well as diagnostic-core.h, so the comment is > also true as it is. If toplev.h is stopped from including > diagnostic-core.h, and diagnostic-core.h includes are added to files that > include toplev.h (replacing the toplev.h include, in some cases), then it > would indeed be necessary to change this comment to reference > diagnostic-core.h. I have a patch that fixes this but it is waiting for the rtl-error.h patch to be approved. Manuel.
On Wed, Jun 30, 2010 at 03:22, Manuel López-Ibáñez <lopezibanez@gmail.com> wrote: > I have a patch that fixes this but it is waiting for the rtl-error.h > patch to be approved. URL to the patch? Diego.
On 30 June 2010 13:47, Diego Novillo <dnovillo@google.com> wrote: > On Wed, Jun 30, 2010 at 03:22, Manuel López-Ibáñez > <lopezibanez@gmail.com> wrote: > >> I have a patch that fixes this but it is waiting for the rtl-error.h >> patch to be approved. > > URL to the patch? http://gcc.gnu.org/ml/gcc-patches/2010-06/msg02799.html Cheers, Manuel.
Index: c-family/c-common.h =================================================================== --- c-family/c-common.h (revision 161509) +++ c-family/c-common.h (working copy) @@ -28,9 +28,9 @@ along with GCC; see the file COPYING3. /* In order for the format checking to accept the C frontend diagnostic framework extensions, you must include this file before - toplev.h, not after. The C front end formats are a subset of those - for C++, so they are the appropriate set to use in common code; - cp-tree.h overrides this for C++. */ + diagnostic-core.h, not after. The C front end formats are a subset + of those for C++, so they are the appropriate set to use in common + code; cp-tree.h overrides this for C++. */ #ifndef GCC_DIAG_STYLE #define GCC_DIAG_STYLE __gcc_cdiag__ #endif