File: test-PR26739-2-v0.c

package info (click to toggle)
libabigail 2.2-2
  • links: PTS
  • area: main
  • in suites: bookworm
  • size: 881,820 kB
  • sloc: xml: 572,528; cpp: 98,056; sh: 11,779; makefile: 2,951; ansic: 2,913; python: 1,345
file content (33 lines) | stat: -rw-r--r-- 593 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
const int global[5]; //#0

typedef const int array_type1[5]; // #1
typedef volatile array_type1 array_type2; // #2

struct A
{
  // The volatile qualifier here applies to the elements of array in
  // declaration #1.  So libabigail's IR should edit the IR for this
  // this qualified type to make the qualifier apply to the element of
  // #1.  All types used for array_type1 should be cloned so that they
  // are not shared with array_type2.
  volatile array_type1 m;
};

void
f0 (struct A *a)
{
  (void)a;
}

void
f1(array_type1 a)
{
  (void) a;
}

void
f2(array_type2 i)
{
  (void) i;
}