title: Defining a function with different signature
body: <p>Today I discovered that it is possible to declare a function in a header with one signature, and implement it in the source file with different (similar) signature. For example, like this :</p>
  
  <pre><code>// THE HEADER  example.hpp
  
  #ifndef EXAMPLE_HPP
  #define EXAMPLE_HPP
  
  int foo( const int v );
  
  #endif
  
  // THE SOURCE FILE example.cpp
  
  #include "example.hpp"
  
  int foo( int v )   // missing const
  {
    return ++v;
  }
  </code></pre>
  
  <p>Is this allowed? Or is this the compiler's extension (I am using g++ 4.3.0) ?</p>
  
  <p><strong>EDIT</strong>
  I am compiling with pedantic and maximum possible warning level, and I am still not getting a warning or an error.</p>