title: C - Function not returning value?
body: <p>I have the following method defined in my header file</p>
  
  <pre><code>unsigned char test(void);
  </code></pre>
  
  <p>Implementation:</p>
  
  <pre><code>unsigned char test()
  {
    unsigned char value = 0xFF;
    return value;    
  }
  </code></pre>
  
  <p>When I call it with this:</p>
  
  <pre><code> unsigned char temp;
   temp = test();
  </code></pre>
  
  <p>Nothing is returned???  I stepped through it with breakpoints.  At the very end, the variable value has a value of 0xFF, but it is never returned to temp?</p>
  
  <p>I am not used to plain old C... only C++, there might be some kind of subtle difference in how methods are declared.</p>
  
  <p>Any help would be greatly appreciated!!!</p>