Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/g++.dg/torture/pr84233.C @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
111:04ced10e8804 | 131:84e7813d76e9 |
---|---|
1 // { dg-do compile } | |
2 // { dg-additional-options "-w" } | |
3 | |
4 void a(const char *, int, const char *, const char *); | |
5 template <typename b> void c(b); | |
6 struct d { | |
7 long e; | |
8 template <typename> union f; | |
9 template <typename h> union f<h *> { | |
10 f(h *i) : j(i) {} | |
11 h *j; | |
12 long bits; | |
13 }; | |
14 static int k(volatile long &i) { return *(int *)f<volatile long *>(&i).bits; } | |
15 typedef long g; | |
16 operator g() volatile { | |
17 int l = k(e); | |
18 c(l); | |
19 } | |
20 }; | |
21 struct : d { | |
22 } m, n; | |
23 bool o; | |
24 void p() { (o ? m : n) ? (void)0 : a("", 5, "", ""); } | |
25 |