Debian Codegraph @

gcc/testsuite/g++.dg/ext/attribute-may-alias-4.C

raw
1 // PR c++/70209
2
3 struct V {
4 typedef float F;
5 template <typename S> void m_fn1(S);
6 };
7
8 template <typename> struct A {
9 typedef V::F Ta __attribute__((__may_alias__));
10 Ta *m_data;
11 void m_fn2(V &);
12 };
13
14 template <>
15 void A<int>::m_fn2(V &p) {
16 p.m_fn1(m_data);
17 }