Remove testsuite/gcc.c-torture/execute/20000603-1.c

Diego Novillo dnovillo@redhat.com
Tue Feb 10 19:59:00 GMT 2004


On Thu, 2004-02-05 at 18:12, Joseph S. Myers wrote:
> On Thu, 5 Feb 2004, Diego Novillo wrote:
> 
> > Should I commit the test cases with these changes?
> 
> I think so (plus a comment pointing to DR236); the exact DR resolution is
> as yet unclear but it seems very likely that the modified version will be
> considered OK and the unmodified version not OK unless separate rulings on
> what the relevant objects are make it so, and the resolution will probably
> naturally suggest new testcases to add afterwards.  But wait to see if
> anyone of those generally objecting to changing what a testcase tests
> object here and want a new name (notwithstanding that the old version
> seems rather dubious).
>
OK.  This is what I will commit.  I tried reading the DR, but quickly
got lost.  Does the new comment make sense?


Diego.

Index: testsuite/gcc.c-torture/execute/20000603-1.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.c-torture/execute/20000603-1.c,v
retrieving revision 1.1
diff -d -c -p -r1.1 20000603-1.c
*** testsuite/gcc.c-torture/execute/20000603-1.c	3 Jun 2000 15:01:49 -0000	1.1
--- testsuite/gcc.c-torture/execute/20000603-1.c	10 Feb 2004 19:36:54 -0000
***************
*** 1,5 ****
--- 1,10 ----
+ /* It is not clear whether this test is conforming.  See DR#236
+    http://wwwold.dkuug.dk/JTC1/SC22/WG14/www/docs/dr_236.htm.  However,
+    there seems to be consensus that the presence of a union to aggregate
+    struct s1 and struct s2 should make it conforming.  */
  struct s1 { double d; };
  struct s2 { double d; };
+ union u { struct s1 x; struct s2 y; };
  
  double f(struct s1 *a, struct s2 *b)
  {
*************** double f(struct s1 *a, struct s2 *b)
*** 9,17 ****
  
  int main()
  {
!   struct s1 a;
!   a.d = 0.0;
!   if (f (&a, (struct s2 *)&a) != 2.0)
      abort ();
    return 0;
  }
--- 14,22 ----
  
  int main()
  {
!   union u a;
!   a.x.d = 0.0;
!   if (f (&a.x, (struct s2 *)&a.y) != 2.0)
      abort ();
    return 0;
  }



More information about the Gcc-patches mailing list