-
-template <typename T, action_t val, int b>
-class Class {
- public:
- static T arr;
- struct A {
- int &a;
- };
-
- static void action() {
- printf("%d\n", arr);
- }
-
- action_t getFuncPtr() {
- foo();
- action();
- return &Class::action;
- }
-
- static void foo() {
-
- }
-
- static void init() {
- action_t inst1 = &foo;
- int a = (1, 2);
- }
-
- Class() {
- //ar = T((int)val);
- (*val)();
- //foo();
- }
-};
-
-#include "test.h"
-
-int main() {
- Class<int> c;
- action_t f_ptr = c.getFuncPtr();
- //cc.getFuncPtr();
- return 1;
-}
-