title: Lazarus RandomRange function
body: <p>I have a problem with RandomRange, this is the code:</p>
  
  <pre><code>procedure TForm1.FormCreate(Sender: TObject);
  var
  i : Integer;
  
    function RandomRange(const AFrom, ATo: Integer): Integer;
    begin
    Result := RandomRange(15,20);
    Case Result of
    15 : ShowMessage('message1');
    16 : ShowMessage('message2');
    17 : ShowMessage('message3');
    18 : ShowMessage('message4');
    19 : ShowMessage('message5');
    20 : ShowMessage('message6');
    end;
  end.
  </code></pre>
  
  <p>When I try to compile, I get the following error:</p>
  
  <pre><code>unit1.pas(46,30) Hint: Parameter "AFrom" not used
  unit1.pas(46,37) Hint: Parameter "ATo" not used
  unit1.pas(57,4) Fatal: Syntax error, ";" expected but "." found
  </code></pre>
  
  <p>What could it be? thanks</p>