title: How to skip optional parameters in Lua?
body: <p>There is a method I have been calling:</p>
  
  <pre><code>t1, t2 = LSL:GetDiffItem(item)
  </code></pre>
  
  <p>where the method is declared as:</p>
  
  <pre><code>GetDiffID(item, ignoreEnchant, ignoreGem, red, yellow, blue, meta, ignorePris)
  </code></pre>
  
  <p>Now I want to pass additional parameters, skipping some:</p>
  
  <p><strong>item</strong>, <strong>ignoreEnchant</strong>, <strong>ignoreGem</strong>, <em>red</em>, <em>yellow</em>, <em>blue</em>, <em>meta</em>, <strong>ignorePris</strong></p>
  
  <p>I tried just <em>skipping</em> the parameters:</p>
  
  <pre><code>t1, t2 = LSL:GetDiffItem(item, ignore, ignore, , , , , ignore)
  </code></pre>
  
  <p>But of course that doesn't work:</p>
  
  <blockquote>
    <p>unexpected symbol near ','</p>
  </blockquote>
  
  <p>So, <em>how do I skip optional parameters in Lua?</em></p>
  
  <hr>
  
  <h2>See also</h2>
  
  <ul>
  <li><a href="http://www.lua.org/pil/5.3.html" rel="nofollow">lua.org - 5.3 - Named Arguments "<em>arguments are positional</em>"</a></li>
  </ul>