On Wed, Aug 16, 2017 at 08:46:20AM -0600, Martin Sebor wrote:
> Is there a setup for writing and running as part of the test
> suite unit tests that exercise internal GCC functions like
> error and warning?  I ask because of a couple of bugs that
> were recently reported for the %s directive in GCC's
> diagnostics (81859 and 81586) that were only caught by running
> valgrind on GCC, but that could have been caught by GCC's own
> tests for these APIs if they existed.
> 
> I can't find any except some in the gcc.dg/plugin directory
> (though they weren't written to exercise the functions but
> rather the plugin interface).  Would adding a plugin for
> this sort of thing be the right way to do it?

Isn't -fself-test the thing you're looking for?

        Marek

Reply via email to