fpc/tests/tbf/tb0232.pp
svenbarth 376bd046aa Don't allow "static" for class operators or normal methods (except in objects).
pdecsub.pas, pd_static:
  * check whether the given pd is an operator or a class method not inside an Object and generate an error if either of these is true
msg/errore.msg, msgidx.inc, msgtxt.inc:
  * add a message to inform that a certain procedure directive is not allowed

+ added tests

git-svn-id: trunk@23944 -
2013-03-20 10:46:55 +00:00

21 lines
179 B
ObjectPascal

{ %FAIL }
program tb0232;
{$mode objfpc}
{$modeswitch advancedrecords}
type
TTest = record
procedure Test; static;
end;
procedure TTest.Test;
begin
end;
begin
end.