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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-stable/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.dg/] [pack-test-2.c] - Blame information for rev 298

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

Line No. Rev Author Line
1 298 jeremybenn
/* Tests for syntax checking of #pragma pack.
2
   Contributed by Mike Coleman <mcoleman2@kc.rr.com> */
3
 
4
/* { dg-do compile { target *-*-linux* *-*-cygwin* powerpc*-*-eabi* } } */
5
 
6
#pragma pack(pop)               /* { dg-warning "without matching" } */
7
 
8
#pragma pack(push)
9
#pragma pack(pop)               /* reset */
10
 
11
#pragma pack(push, foo, 1)
12
#pragma pack(pop, foo, 1)       /* { dg-warning "malformed" } (/
13
#pragma pack(pop)               /* reset */
14
 
15
#pragma pack(push, foo, 1)
16
#pragma pack(pop, bar)          /* { dg-warning "without matching" } */
17
#pragma pack(pop)               /* reset */
18
 
19
#pragma pack(push, foo, 1)
20
#pragma pack(pop)
21
#pragma pack(pop, foo)          /* { dg-warning "without matching" } */
22
 
23
#pragma pack(push, foo, 3)      /* { dg-warning "small power of two" } */
24
 
25
extern int blah;        /* prevent "ISO C forbids an empty translation unit" */

powered by: WebSVN 2.1.0

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