Elixir type spec for a function with default parameters
<p>How do I write a type spec for the function that accepts, let's say, one parameter which has a default value? Something like the following:</p>
<pre class="lang-elixir prettyprint-override"><code>def foo(bar \\ 10) do
  bar
end
</code></pre>
<p>Would it be this:</p>
<pre class="lang-elixir prettyprint-override"><code>@spec foo(integer) :: integer
</code></pre>
<p>Or what would it be?</p>
<p>Thank you.</p>