On Tue, Oct 15, 2024 at 11:47:45AM +0200, Jakub Jelinek wrote:
> The following patch adds selftests to genmatch to verify the new printing
> routine there.
> So that I can rely on HAVE_DECL_FMEMOPEN (host test), the tests are done
> solely in stage2+ where we link the host libcpp etc. to genmatch.
> The tests have been adjusted from pretty-print.cc (test_pp_format),
> and I've added to that function two new tests because I've noticed nothing
> was testing the %M$.*N$s etc. format specifiers.
> 
> Tested on x86_64-linux, ok for trunk?
> 
> 2024-10-15  Jakub Jelinek  <ja...@redhat.com>
> 
>       * configure.ac (gcc_AC_CHECK_DECLS): Add fmemopen.
>       * configure: Regenerate.
>       * config.in: Regenerate.
>       * Makefile.in (build/genmatch.o): Add -DGENMATCH_SELFTESTS to
>       BUILD_CPPFLAGS for stage2+ genmatch.
>       * genmatch.cc (test_diag_vfprintf, genmatch_diag_selftests): New
>       functions.
>       (main): Call genmatch_diag_selftests.
>       * pretty-print.cc (test_pp_format): Add two tests, one for %M$.*N$s
>       and one for %M$.Ns.

I'd like to ping this patch.

Thanks.

        Jakub

Reply via email to