This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ 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]

Re: 26_numerics/c99_classification_macros_c.cc


In article <87vfv93j3p.fsf@egil.codesourcery.com> you write:
>
>This test has been XPASSing for some time on i686-linux (glibc 2.2).
>Looking at the dg markup, I am not sure what the intent of the test
>is...

>// { dg-do compile { xfail *-*-linux-gnu *-*-freebsd5* } }
>// { dg-excess-errors "" { target *-*-linux-gnu *-*-freebsd5* } }

>It is possible that the intent was to run the test only on linux and
>freebsd5, where the C library is known to have the appropriate
>underlying primitives, but xfail it on both; it is also possible that
>the test is expected to fail only on those targets.

>In fact the test compiles successfully, with no diagnostic output.

>Could someone please explain what's supposed to be going on here?

Hi Zack,

We are not dg- experts over here but having been the last to dink with
it: The test is supposed to be compiled everywhere but fail on
*-*-linux-gnu (when glibc supports C99 macros) and *-*-freebsd5* (when
libc supports C99 macros).  The exact failures were not worth marking
thus we added the generic dg-excess-errors.  BTW, I think I tried
removing the xfail from the dg-do compile line and/or the
dg-excess-errors but it doesn't work quite the way we wanted unless
both marks remained (I'd admit that I read DG docs but the above was
trial-and-error after fixing up other library maintainers attempt).

BTW, I concur that it is XPASSing on ref5 (freebsd5).  That is a
strange regression since when I run the test case after the compiler
is fully installed, it produces the "expected" diagnostic output.

Luckily, this was an easy one to figure out (but, ah, another PCH
bondongle):

; g++  -include bits/stdc++.h -c c99_classification_macros_c.cc
; g++  -c c99_classification_macros_c.cc 
c99_classification_macros_c.cc:35: error: expected unqualified-id
c99_classification_macros_c.cc:35: error: expected `)'
c99_classification_macros_c.cc:35: error: expected `)'
c99_classification_macros_c.cc:35: error: expected `,' or `;'
[...]

The test suite runs the test the first way with the PCH include.
Thus, the marking is, if not correct, probably still doing what we
hoped and this is a real regression.

Regards,
Loren


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