#include <iostream>
#include <functional>

struct myStruct {
    int data;	
};

void get_data(struct myStruct* const value, const void * const data) {
    std::cout << "called!" << std::endl;
    value->data = 12345;
}

template<typename MyType>
void process(bool test, const std::function<void(MyType* const, const void* const)>& callb) {
    MyType t;
    callb(&t, nullptr);
    std::cout << t.data << std::endl;
}

int main() {
    bool test1 = true;
    process<myStruct>(test1, get_data);
    return 0;
}