[comp.lang.modula2] JPI FIO.WrBin only V1.04b?

SLovatt@massey.ac.nz (S.J. Lovatt) (07/10/90)

In article <7773@tekgvs.LABS.TEK.COM>, toma@tekgvs.LABS.TEK.COM (Tom Almy)
writes:

> In article <831@massey.ac.nz> SLovatt@massey.ac.nz (S.J. Lovatt) writes:
> >Bug Fix - JPI TopSpeed M2 Rel 1.04b
> >Symptom:
> >When using FIO.WrLn, I found that it was producing: CR CR LF
> >... rather than CR LF, as it should.
> >Solution:
> >The problem was traced to FIO.WrBin, where the procedure CLB.write was
> >called to do the actual writing. Elsewhere, this procedure was called as:
> >CLB._write     ... but here, it was called as:    CLB.write
>
> This message has me baffled because I recompiled (from older TS M2) an
> application that wrote binary files and didn't see this problem.
>
> But my release is "1.04" with no letter suffix. In the sources CLB.write
> is called *everywhere* except FIO.Truncate().

< Stuff Deleted >

> So this brings up a new question, are there different versions for different
> countries? Did they introduce new errors in some revision from 1.04 to 1.04b?
> Enquiring minds want to know.
>
> Tom Almy

I got my JPI compiler direct from JPI at Mountain View CA, so I guess I
got the same compiler version that anyone in the US got at the time as I
purchased it (around 10 May, if I recall correctly). It seemed strange to
me that most (if not all) the CLB routines that I came across in FIO were
called with a leading underscore, when CLB.write was not. I also recalled
reading that functions to be called by C from assembly frequently had a
leading underscore, and what I found in FIO then seemed to fit in with the
C <-> Modula-2 multilanguage programming idea.

I haven't checked through R_CORE.A in detail (which is where CLB._write
resides) as I am not good enough with 8086 assembly to be sure that I
would understand what was going on, however I did enough testing before
fixing to convince myself that the problem was in FIO.WrBin, and enough
testing afterwards to convince me that the fix worked, and didn't disturb
anything else.

The caveat that I included before is worth repeating more strongly - If
your compiler version is not the same as mine, or you are in any doubt
about the fix, don't use it; wait for the next release. Apparently Tom's
version does not suffer from the problem, and yours may not either.

- Simon

-- 
Simon Lovatt            | S.J.Lovatt@massey.ac.nz |
Dept of Biotechnology   |                         |
Massey University, N.Z. |                         |