Can't use keyword arguments with overloaded functions
<p><em>Note:</em> The corresponding gist is <a href="https://gist.github.com/nschloe/2905bbd136605aa91eeb5d22cbe6ec05" rel="nofollow">here</a></p>

<hr>

<p>I'm SWIGging some C++ code to be used from Python, and I'm using <code>std::vector&lt;double&gt;</code> in the interface, e.g.,</p>

<p><code>myfoo.hpp</code></p>



<pre><code>#ifndef MYFOO_HPP
#define MYFOO_HPP

#include &lt;vector&gt;

double sum(const std::vector&lt;double&gt; &amp; a) {
  double sum = 0.0;
  for (const auto &amp; elem: a) {
    sum += elem;
  }
  return sum;
}

#endif // MYFOO_HPP
</code></pre>

<p><code>myfoo.i</code></p>

<pre><code>%module myfoo

%{
#include "myfoo.hpp"
%}

%include &lt;std_vector.i&gt;
namespace std {
%template(Line) vector&lt;double&gt;;
}

%include "myfoo.hpp"
</code></pre>

<p>When SWIGging with the <code>-keyword</code> option (not really necessary in this mini example), e.g.,</p>

<pre><code>swig -python -keyword -c++ -o myfoo_wrap.cpp myfoo.i
</code></pre>

<p>I'm getting <em>tons</em> of warnings like</p>

<pre><code>/usr/share/swig3.0/std/std_vector.i:94: Warning 511: Can't use keyword arguments with overloaded functions (std::vector&lt; double &gt;::erase(std::vector&lt; double &gt;::iterator)).
</code></pre>

<p>What am I doing wrong? </p>