title: C++ Compiler Error: "No matching function for call", when using a 2-D array as an argument
body: <p>I'm trying to call a function (called closestPair) in a separate .cpp file from my main.cpp, using a [5][10] 2D-array as an argument. </p>
  
  <p>The call:</p>
  
  <pre><code>extern const unsigned int vSize = 10;
  
  [...]
  
  double input[5][10] = {{0.595500, 0.652927, 0.606763, 0.162761, 0.980752, 0.964772, 0.319322, 0.611325, 0.012422, 0.393489},
                         {0.416132, 0.778858, 0.909609, 0.094812, 0.380586, 0.512309, 0.638184, 0.753504, 0.465674, 0.674607},
                         {0.183963, 0.933146, 0.476773, 0.086125, 0.566566, 0.728107, 0.837345, 0.885175, 0.600559, 0.142238},
                         {0.086523, 0.025236, 0.252289, 0.089437, 0.382081, 0.420934, 0.038498, 0.626125, 0.468158, 0.247754},
                         {0.969345, 0.127753, 0.736213, 0.264992, 0.518971, 0.216767, 0.390992, 0.242241, 0.516135, 0.990155}};
  closestPair(input);
  </code></pre>
  
  <p>The header:</p>
  
  <pre><code>#include &lt;iostream&gt;
  
  extern const unsigned int vSize;
  double vectDistance (double a[], double b[]);
  void closestPair(double bag[][vSize]);
  
  #endif /* defined(__Cpp_Lab2__name1__) */
  </code></pre>
  
  <p>The function:</p>
  
  <pre><code>void closestPair(double bag[][vSize]){
   [...]
  }
  </code></pre>
  
  <p>The error:</p>
  
  <pre class="lang-none prettyprint-override"><code>No matching function for call to 'closestPair'
  </code></pre>
  
  <p>I think something in the input 2D-array seems to be conflicting with the argument list for the function, but I'm not sure what the issue could be. I've checked all over the place, and it's probably something stupid that I'm missing. How can I solve that? </p>