6
votes
Vote UpVote

Delphi: always watch the compiler Warnings

The Wiert Corner – Quiz questions: Does the below unit test succeed or fail? Why? procedure TestHResult.Test_EOleException; var OleException: EOleException; IResult: LongInt; // == HResult UResult: Cardinal; // == DWord begin IResult := $800A11FD; UResult := $800A11FD; try OleException := EOleException.Create('message', $800A11FD, 'source', 'helpfile', -1); raise OleException; except on E: EOleException do begin if E.ErrorCode = $800A11FD then Exit; Self.CheckEquals(E.ErrorCode, $800A11FD, 'E.ErrorCode should equal $800A11FD'); end; // E: EOleException ...
Favorite? Off-Topic? Jeroen Pluimers @ 2014-08-28 07:00

Statistics

Visits: 961
Votes: 6
Favorites: 0
Off-Topic: 0

Visits by Source

User Actions

Users who voted for this posting

Barton_Stano
Chris
François
Jørn E. Angeltveit
Michael Riley
Primoz Gabrijelcic
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)