Vote UpVote

Yet another surprise from Delphi compiler

The Programming Works – Build and run the following console app: program ItWorks; {$APPTYPE CONSOLE} uses SysUtils; type TTest = record FData: Integer; end; procedure DoTest(const S: string); begin Writeln(TTest(S).FData); end; begin try DoTest('123'); except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; Readln; end. I tested in Delphi XE and Delphi 10.1 Berlin, it compiles and even works!
Favorite? Off-Topic? Serg @ 2017-02-17 10:05


Visits: 895
Votes: 0
Favorites: 0
Off-Topic: 0

Visits by Source

User Actions

Users who voted for this posting

Contact us to advertise on DelphiFeeds.com

Community Links

Torry Firebird News


Please login or register to use this functionality.
(click on this box to dismiss)