int f(char) {
return 0;
}
int (*return_f())(char) {
return f;
}
No, seriously, use a typedef 🙂
More Related Contents:
- Call function use pointer
- What should main() return in C and C++?
- How do I execute a command and get the output of the command within C++ using POSIX?
- Function pointer to member function
- “unpacking” a tuple to call a matching function pointer
- Calling C++ member functions via a function pointer
- Why are function pointers and data pointers incompatible in C/C++?
- Do distinct functions have distinct addresses?
- Using a STL map of function pointers
- Function pointers casting in C++
- Most vexing parse confusion
- convert std::bind to function pointer
- C++ return value without return statement
- How define an array of function pointers in C
- Error with address of parenthesized member function
- Complex C declaration
- Function pointer as parameter
- Where are member functions stored for an object?
- C++ function pointer (class member) to non-static member function
- C++ class member function pointer to function pointer
- generic member function pointer as a template parameter
- Do function pointers need an ampersand [duplicate]
- About Pointers To Functions in function declarations
- Passing a pointer to a class member function as a parameter
- can void* be used to store function pointers? [duplicate]
- What is the purpose of std::function and how to use it?
- Why do we use std::function in C++ rather than the original C function pointer? [duplicate]
- C++: Calling member function via pointer
- How do C++ progs get their return value, when a return is not specified in the function?
- Howto: c++ Function Pointer with default values