OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.old-deja/] [g++.law/] [union1.C] - Blame information for rev 699

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 699 jeremybenn
// { dg-do assemble  }
2
// GROUPS passed unions
3
// anon-union file
4
// From: "Terry R. Coley" 
5
// Date:     Tue, 25 Aug 1992 17:33:29 -0700
6
// Subject:  possible bug in gcc/g++
7
// Message-ID: <199208260033.AA19417@brahms.wag.caltech.edu>
8
 
9
typedef enum { BADBINOP = 0, PLUS, MINUS, MULT, DIV, POWR } binoptype;
10
typedef enum { BADUNOP = 0, NEG = POWR+1, SIN, COS, TAN } unoptype;
11
 
12
typedef struct {
13
  const char *s;
14
  union {
15
    binoptype bop;
16
    unoptype uop;
17
  };
18
}
19
op_to_charp;
20
 
21
op_to_charp BINOPS[] = { {"+", PLUS},
22
                         {"-", MINUS},
23
                         {"*", MULT},
24
                         {"/", DIV},
25
                         {"^", POWR} };
26
 
27
int main() {
28
  int dummy;
29
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.