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]

[Diagnostic Patch] Clean-up diagnostic facilities in diagnostic.c


Hi,

yesterday I had the idea of this small clean-up: move the work done by emit_diagnostic to a new non-variadic diagnostic_impl and use it to implement the former and all the various inform, warning, permerror, etc (lately we have the *_at_rich_loc variants too). Something similar can be done for inform_n, warning_n and errror_n. There is the minor subtlety of the declarations decorated with ATTRIBUTE_GCC_DIAG when available to suppress the build-time warning: I think I did it the right way, I took inspiration from the declarations of diagnostic_set_info, etc, in diagnostic.h.

Tested x86_64-linux.

Thanks,
Paolo.

////////////////////////////////

Attachment: CL_diagnostic
Description: Text document

Attachment: patch_diagnostic
Description: Text document


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