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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.c-torture/] [execute/] [990525-2.c] - Blame information for rev 307

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 297 jeremybenn
typedef struct {
2
    int v[4];
3
} Test1;
4
 
5
Test1 func2();
6
 
7
int func1()
8
{
9
    Test1 test;
10
    test = func2();
11
 
12
    if (test.v[0] != 10)
13
      abort ();
14
    if (test.v[1] != 20)
15
      abort ();
16
    if (test.v[2] != 30)
17
      abort ();
18
    if (test.v[3] != 40)
19
      abort ();
20
}
21
 
22
Test1 func2()
23
{
24
    Test1 tmp;
25
    tmp.v[0] = 10;
26
    tmp.v[1] = 20;
27
    tmp.v[2] = 30;
28
    tmp.v[3] = 40;
29
    return tmp;
30
}
31
 
32
 
33
int main()
34
{
35
    func1();
36
    exit (0);
37
}
38
 
39
 

powered by: WebSVN 2.1.0

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