<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; function f(x)
        local x
        x = 1
       end
f (generic function with 1 method)

julia&gt; f(1)
ERROR: UndefVarError: x not defined
 in f(::Int64) at ./REPL[1]:2"><pre class="notranslate"><code class="notranslate">julia&gt; function f(x)
        local x
        x = 1
       end
f (generic function with 1 method)

julia&gt; f(1)
ERROR: UndefVarError: x not defined
 in f(::Int64) at ./REPL[1]:2
</code></pre></div>
<p dir="auto">In versions &lt;=0.4, this gave <code class="notranslate">ERROR: syntax: local "x" conflicts with argument</code> when parsing the method definition.</p>
<p dir="auto">while I might appreciate the accuracy in noting that atypes wasn't actually assigned, codegen doesn't appreciate finding an assignment to a parameter that it was told would not be assigned to:</p>
<div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="julia&gt; function inlineable(atypes::Vector{Any})
           local atypes = atype.parameters
           atype = Tuple{atypes...}
       end
inlineable (generic function with 1 method)

julia&gt; @code_lowered inlineable(Any[1,2,3])
1-element Array{Any,1}:
 :($(Expr(:lambda, Any[symbol(&quot;#self#&quot;),:atypes], 
Any[Any[Any[symbol(&quot;#self#&quot;),:Any,0],
Any[:atypes,:Any,18],
Any[:atypes,:Any,0], # &lt;==== this value is wrong, and overwrites the previous value ====
Any[:atype,:Any,18]],
Any[],1], :(begin  # none, line 2:
        atypes = (top(getfield))(atype,:parameters) # none, line 3:
        GenSym(0) = (top(_apply))(top(apply_type),(top(tuple))(Main.Tuple),atypes)
        atype = GenSym(0)
        return GenSym(0)
    end))))

julia&gt; inlineable(Any[1,2,3])
Assertion failed: (vi.isSA), function emit_assignment, file /Users/jameson/julia/src/codegen.cpp, line 3227.
Abort trap: 6"><pre class="notranslate">julia<span class="pl-k">&gt;</span> <span class="pl-k">function</span> <span class="pl-en">inlineable</span>(atypes<span class="pl-k">::</span><span class="pl-c1">Vector{Any}</span>)
           <span class="pl-k">local</span> atypes <span class="pl-k">=</span> atype<span class="pl-k">.</span>parameters
           atype <span class="pl-k">=</span> Tuple{atypes<span class="pl-k">...</span>}
       <span class="pl-k">end</span>
inlineable (generic <span class="pl-k">function</span> with <span class="pl-c1">1</span> method)

julia<span class="pl-k">&gt;</span> <span class="pl-c1">@code_lowered</span> <span class="pl-c1">inlineable</span>(Any[<span class="pl-c1">1</span>,<span class="pl-c1">2</span>,<span class="pl-c1">3</span>])
<span class="pl-c1">1</span><span class="pl-k">-</span>element Array{Any,<span class="pl-c1">1</span>}<span class="pl-k">:</span>
 :(<span class="pl-k">$</span>(<span class="pl-c1">Expr</span>(<span class="pl-c1">:lambda</span>, Any[<span class="pl-c1">symbol</span>(<span class="pl-s"><span class="pl-pds">"</span>#self#<span class="pl-pds">"</span></span>),<span class="pl-c1">:atypes</span>], 
Any[Any[Any[<span class="pl-c1">symbol</span>(<span class="pl-s"><span class="pl-pds">"</span>#self#<span class="pl-pds">"</span></span>),<span class="pl-c1">:Any</span>,<span class="pl-c1">0</span>],
Any[<span class="pl-c1">:atypes</span>,<span class="pl-c1">:Any</span>,<span class="pl-c1">18</span>],
Any[<span class="pl-c1">:atypes</span>,<span class="pl-c1">:Any</span>,<span class="pl-c1">0</span>], <span class="pl-c"><span class="pl-c">#</span> &lt;==== this value is wrong, and overwrites the previous value ====</span>
Any[<span class="pl-c1">:atype</span>,<span class="pl-c1">:Any</span>,<span class="pl-c1">18</span>]],
Any[],<span class="pl-c1">1</span>], :(<span class="pl-k">begin</span>  <span class="pl-c"><span class="pl-c">#</span> none, line 2:</span>
        atypes <span class="pl-k">=</span> (<span class="pl-c1">top</span>(getfield))(atype,<span class="pl-c1">:parameters</span>) <span class="pl-c"><span class="pl-c">#</span> none, line 3:</span>
        <span class="pl-en">GenSym</span>(<span class="pl-c1">0</span>) <span class="pl-k">=</span> (<span class="pl-c1">top</span>(_apply))(<span class="pl-c1">top</span>(apply_type),(<span class="pl-c1">top</span>(tuple))(Main<span class="pl-k">.</span>Tuple),atypes)
        atype <span class="pl-k">=</span> <span class="pl-c1">GenSym</span>(<span class="pl-c1">0</span>)
        <span class="pl-k">return</span> <span class="pl-c1">GenSym</span>(<span class="pl-c1">0</span>)
    <span class="pl-k">end</span>))))

julia<span class="pl-k">&gt;</span> <span class="pl-c1">inlineable</span>(Any[<span class="pl-c1">1</span>,<span class="pl-c1">2</span>,<span class="pl-c1">3</span>])
Assertion failed<span class="pl-k">:</span> (vi<span class="pl-k">.</span>isSA), <span class="pl-k">function</span> emit_assignment, file <span class="pl-k">/</span>Users<span class="pl-k">/</span>jameson<span class="pl-k">/</span>julia<span class="pl-k">/</span>src<span class="pl-k">/</span>codegen<span class="pl-k">.</span>cpp, line <span class="pl-c1">3227.</span>
Abort trap<span class="pl-k">:</span> <span class="pl-c1">6</span></pre></div>