title: Error "Record, object or class type required" when using a wrapper type of an array
body: <p>I have got two arapper types for easy handling /returning of one-dimensional Arrays, and I want so write a method to convert one to another (a 2d-float-Vector class to a 2d-int-point class). Wrote a simple one, but it just throws some errors I don´t understand.</p>
  
  <pre><code>unit UUtil;
  
  interface
  
  uses
  
      UVector2f, Types, SysUtils;
  
  type
  
      Vector2fArrayWrapper = array of Vector2f;
      PointArrayWrapper = array of TPoint;
  
  implementation
  
      function toPointArray(vw : Vector2fArrayWrapper) : PointArrayWrapper;
      var pw : PointArrayWrapper;
          i,x,y : Integer;
      begin
          setLength(pw, vw.length);
          for i := 0 to vw.high do
          begin
              x := round(vw[i].getX());
              y := round(vw[i].getY());
              vw[i] := TPoint(x,y);
          end;
          result := pw;
      end;
  
  
  end.
  </code></pre>
  
  <p>These are the errors I get:</p>
  
  <pre><code>[Error] UUtil.pas(20): Record, object or class type required
  [Error] UUtil.pas(21): Record, object or class type required
  [Error] UUtil.pas(25): ')' expected but ',' found
  [Error] UUtil.pas(27): Declaration expected but identifier 'result' found
  [Error] UUtil.pas(28): '.' expected but ';' found
  </code></pre>