9
votes
Vote UpVote

The limitations of Delphi’s “inline”

DelphiTools – Sometimes, the most simple-looking code can cause the Delphi compiler to stumble. I bumped on such a case recently, and simplified it to a bare-bones version that still exhibits the issue: type TFloatRec = record private Field : Double; public function RecGet : Double; inline; end; TMyClass = class private FRec : TFloatRec; public function Get : Double; virtual; end; function TFloatRec.Get : Double; begin Result:=Field; // here you could do a computation instead end; function TMyClass.Get : Double; begin ...
Favorite? Off-Topic? Eric @ 2011-02-08 14:48

Statistics

Visits: 903
Votes: 9
Favorites: 0
Off-Topic: 0

Visits by Source

User Actions

Users who voted for this posting

Ericc
Kibab
knight_killer
mad006
Primoz Gabrijelcic
stukelly
vcldeveloper
Yogi Yang
Zzzzz
Subscribe:
Contact us to advertise on DelphiFeeds.com

Community Links

Torry Firebird News

Sponsor

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