title: Delphi array initialization
body: <p>I currently have this, and it sucks:</p>
  
  <pre><code>type TpointArray = array [0..3] of Tpoint;
  
  class function rotationTable.offsets(pType, rotState, dir: integer): TpointArray;
  begin
  
    Result[0] := point(1, 1);
    Result[1] := point(1, 2);
    Result[2] := point(1, 1);
    Result[3] := point(1, 1);
  end;
  </code></pre>
  
  <p>but instead, <strong>i want to do something like this:</strong></p>
  
  <pre><code>class function rotationTable.offsets(pType, rotState, dir: integer): TpointArray;
  begin
     Result := [Point(1,1), Point(1,2), Point(1,1), Point(1,1)];
  end;
  </code></pre>
  
  <p>However, on compilation, it complains that the [1, 2, 3, 4] syntax can only work for Integers.</p>
  
  <p>Is there a way to instantiate/initialize an array of Tpoint similar to the way that i want?</p>