summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.jason/rfg18.C
blob: 9c32b1f025693f9afefb47e35cab55c87b2319e7 (plain)
1
2
3
4
5
6
7
8
9
10
11
// { dg-do assemble  }
// Any expression may be explicitly converted to type void.

struct S { int m[10]; } object;
struct S f () { return object; }
 
void
test ()
{
  (void) f().m;         /* OK - cast to void; see constraints in 3.8.1 */
}