* g++.dg/pr65295.C: Use target c++14.
[platform/upstream/gcc.git] / gcc / testsuite / g++.dg / spellcheck-fields-2.C
1 // { dg-options "-fdiagnostics-show-caret" }
2
3 union u
4 {
5   int color;
6   int shape;
7 };
8
9 int test (union u *ptr)
10 {
11   return ptr->colour; // { dg-error "did you mean .color.?" }
12 }
13
14 // Verify that we get an underline and a fixit hint.
15 /* { dg-begin-multiline-output "" }
16    return ptr->colour;
17                ^~~~~~
18                color
19    { dg-end-multiline-output "" } */