Debian Codegraph @

gcc/testsuite/g++.old-deja/g++.other/qual1.C

raw
1 // { dg-do assemble }
2 // { dg-options "-O" }
3 // Origin: Benjamin Pflugmann <[email protected]>
4
5 // DR 295 allows qualification via typedef
6
7 typedef const char *(func_type)();
8
9 class C
10 {
11 public:
12 func_type *Function;
13 // The following is DR 295 dependent
14 const func_type* function(void) { return Function; }
15 volatile func_type* functionv(void);
16 } action;
17
18 void work(const char *source)
19 {
20 work( action.function()() );
21 }