Bill Currie wrote:
On 27 Oct 97 at 8:50, Frank Heckenbach wrote:
[...]
- After calling an I/O function, if {$I+} is turned on, the calling
program must check InOutRes. The code to be generated (perhaps you've already done so) would look like "if InOutRes<>0 then _p_ioerror;" where _p_ioerror will be a RTS function I can provide. (The check "if InOutRes<>0" could also be done in the function (like in BP!), but that's inefficient, because the function has to be called after each I/O operation then.)
Actually, that's almost exactly what my mods do. If IO checking is enabled ( {$I+} ), a proceedure taking no parameters is called that would check the InOutRes state (though I used a different name) and if it's set dumps a dirty message and aborts the program.
For compatibility with BP, you would need to call the variable "InOutRes", and it should be exported, so that programmers can set it manually if they want (this feature of BP might be considered to be a bug by some, but I have found great use for it ...).
Best regards, The Chief -------- Dr. Abimbola A. Olowofoyeku (The African Chief) Email: laa12@keele.ac.uk Author of: Chief's Installer Pro 4.01 for Win16 and Win32: Winner of PC PLUS Magazine Gold Award (April 1995 U.K. edition) http://ourworld.compuserve.com/homepages/African_Chief/
ftp://ftp.demon.co.uk/pub/ibmpc/win3/apps/chief/pro/chief401.zip
On 28 Oct 97 at 8:42, The African Chief wrote:
For compatibility with BP, you would need to call the variable "InOutRes", and it should be exported, so that programmers can set it manually if they want (this feature of BP might be considered to be a bug by some, but I have found great use for it ...).
Good point. If I leave the check as a function call, there's no problem, but if I go to inline code I will use InOutRes.
Bill -- Leave others their otherness.