On Thu, 16 Feb 2023 at 11:45, Jakub Jelinek <ja...@redhat.com> wrote:
>
> On Thu, Feb 16, 2023 at 11:47:54AM +0100, Jakub Jelinek via Gcc-patches wrote:
> > On Thu, Feb 16, 2023 at 10:30:30AM +0000, Jonathan Wakely via Gcc-patches 
> > wrote:
> > > Tested powerpc64le-linux. Pushed to trunk.
> > >
> > > These should be backported too.
> > >
> > > -- >8 --
> > >
> > > The non-reserved names 'val' and 'dest' were being used in our headers
> > > but haven't been added to the 17_intro/names.cc test. That's because
> > > they are used by <asm-generic/posix_types.h> and <netinet/tcp.h>
> > > respecitvely on glibc-based systems.
> >
> > So, can't we for such problematic names add hacks, like some directory
> > which the test adds as -isystem before the standard ones and contains
>
> Or do it the way you just did for PSTL, by including all the non-libstdc++
> headers used in libstdc++ headers before defining all the macros for the
> non-reserved names, hopefully the system headers use include guards and
> won't be included again.


Yes, I tried that last week, and it didn't work. There was a
diagnostic about __GLIBCXX__ being redefined, because of the {
dg-add-options no_pch } directive.

I can try again, or we can just use the existing solution of doing
#undef val #undef dest for glibc and/or linux targets, so that we
still test those names on other targets.

Reply via email to