comparison gcc/testsuite/g++.dg/rtti/typeid12.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 // PR c++/87547
2 // { dg-do run }
3
4 #include <typeinfo>
5
6 struct S { unsigned int a : 4; unsigned int b : 12; int c; unsigned long d : 8; } s;
7
8 int
9 main ()
10 {
11 if (typeid (s.a) != typeid (unsigned int)
12 || typeid (s.b) != typeid (unsigned int)
13 || typeid (s.c) != typeid (int)
14 || typeid (s.d) != typeid (unsigned long))
15 __builtin_abort ();
16 }