title: Is there a literal for the empty array in Chapel?
body: <p>I'm trying to make an empty array in Chapel. An array of one element can be made like this:</p>
  
  <pre><code>var a: [1..1] int = (1);
  </code></pre>
  
  <p>But when I try</p>
  
  <pre><code>var b: [1..0] int = ();
  </code></pre>
  
  <p>I get</p>
  
  <blockquote>
    <p>syntax error: near ')'</p>
  </blockquote>
  
  <p>Is there an empty array literal in Chapel? I haven't been able to find an example.</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>The reason I am trying to get an empty array is that I would like to implement get this function working for empty arrays:</p>
  
  <pre><code>proc sum_of_even_squares(a) {
    // Does this work for empty arrays? Probably not.
    return + reduce ([x in a] if x % 2 == 0 then x*x else 0);
  }
  
  assert(sum_of_even_squares([7]) == 0);
  assert(sum_of_even_squares([7, 3]) == 0);
  assert(sum_of_even_squares([7, 3, -8]) == 64);
  assert(sum_of_even_squares([7, 3, -8, 4]) == 80);
  </code></pre>
  
  <p>But I am unable to form an empty array literal.</p>