Tech Off Post

Single Post Permalink

View Thread: [C++] What is the function type
  • User profile image

    6 hours ago, Dexter wrote

    No problem, anyway my answer isn't quite right. void(int) will only work with std::function, what std::function does to achieve this is close to magic

    That is good to know Tongue Out

    In your case you'll have to stick to something simpler:
    guard<S_FUNC> g(func);

    Well now i feel stupid, for not thinking of that.
    It's quite obvious now when i see the solution.

    Damn tunnel vision !

    Thank you for the help.