title: Return a pointer to function with varying signature based on argument
body: <p>I've seen <a href="https://stackoverflow.com/questions/997821/how-to-make-a-function-return-a-pointer-to-a-function-c">this link describing a fixed signature example</a> but would like to know how to write a function that returns a pointer to a function whose signature depends on the argument to the calling function (if it is even possible)?</p>
  
  <p>Example: </p>
  
  <p>Suppose I have </p>
  
  <pre><code>typedef void (*func1) (int);
  typedef void (*func2) (int, int);
  </code></pre>
  
  <p>I would like to have a function <code>get_func</code> that returns a pointer to one or the other based on, say, the value of an integer argument, e.g.,:
      <code>get_func1(0)</code> returns <code>func1</code>;
      <code>get_func2(1)</code> returns <code>func2</code>.</p>