<p dir="auto">see image below, this works correctly if no keyword arguments are used. This is causing the current test failures of <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="53300984" data-permission-text="Title is private" data-url="https://github.com/JuliaLang/julia/issues/9575" data-hovercard-type="pull_request" data-hovercard-url="/JuliaLang/julia/pull/9575/hovercard" href="https://github.com/JuliaLang/julia/pull/9575">#9575</a></p>
<p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/2347816/5918734/a7a2bab2-a634-11e4-8247-0b310dca56fb.png"><img src="https://cloud.githubusercontent.com/assets/2347816/5918734/a7a2bab2-a634-11e4-8247-0b310dca56fb.png" alt="screenshot from 2015-01-27 14 53 57" style="max-width: 100%;"></a></p>
<p dir="auto">Since empty arrays <code class="notranslate">[]</code> are of type <code class="notranslate">Vector{None}</code>, it will sometimes happen that people do mistakes like this:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; function f1(x::Vector{Int} = [])
           true
       end
f1 (generic function with 3 methods)

julia&gt; function f2(; x::Vector{Int} = [])
           true
       end
f2 (generic function with 1 method)

julia&gt; f1()
ERROR: no method f1(Array{None,1})
 in f1 at none:2

julia&gt; f2()
ERROR: no method __f2#3__(Array{None,1})"><pre lang="julia" class="notranslate"><code class="notranslate">julia&gt; function f1(x::Vector{Int} = [])
           true
       end
f1 (generic function with 3 methods)

julia&gt; function f2(; x::Vector{Int} = [])
           true
       end
f2 (generic function with 1 method)

julia&gt; f1()
ERROR: no method f1(Array{None,1})
 in f1 at none:2

julia&gt; f2()
ERROR: no method __f2#3__(Array{None,1})
</code></pre></div>
<p dir="auto">At least, in the second case, the function name is a bit weird. In the first case, the line number doesn't correspond to anything interesting. If it's possible, it would be great to print a more explicit message, like "default argument value is of an incorrect type".</p>