fork(1) download
  1. {$mode objfpc}
  2.  
  3. type
  4. TMyRecord = record
  5. Field: Integer;
  6. end;
  7.  
  8. type
  9. TMyClass = class
  10. protected
  11. MyRecord: TMyRecord;
  12.  
  13. public
  14.  
  15. property MyRecordProperty: TMyRecord read MyRecord write MyRecord;
  16. end;
  17.  
  18.  
  19. var classInstance: TMyClass;
  20. begin
  21. classInstance := TMyClass.Create();
  22. classInstance.MyRecordProperty.Field := 52;
  23. end.
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
Free Pascal Compiler version 2.6.4+dfsg-6 [2015/05/31] for i386
Copyright (c) 1993-2014 by Florian Klaempfl and others
Target OS: Linux for i386
Compiling prog.pas
prog.pas(22,32) Error: Argument can't be assigned to
prog.pas(23,4) Fatal: There were 1 errors compiling module, stopping
Fatal: Compilation aborted
Error: /usr/bin/ppc386 returned an error exitcode (normal if you did not specify a source file to be compiled)
stdout
Standard output is empty