Re: 0-based Indexing
- Posted by gertie at visionsix.com Jul 17, 2003
- 512 views
On 17 Jul 2003, at 12:34, Christian.CUVIER at agriculture.gouv.fr wrote: > > > > Date: Wed, 16 Jul 2003 19:16:35 -0500 > > From: gertie at visionsix.com <snip> > > BASIC and Pascal used the first byte as length. (It feels odd that RobC > > would use an example from Basic, and still not implement CASE and > > GOTO.) So the string storage data did actually start at zero offset, but not > > the string itself. Naturally my gripe with Turbo Pascal is that it began a > > move to C strings, so one could not store a null in byte in the string. But > > then, DOS frowned on that too. > > > > Kat > > In which way does it frown? > The basic display functions (int 21/09 and BIOS int 10/0E and 13) will > happily print nulls, provided the current codepage supports them. > Besides, for all the DOS calls I know which take an ASCIZ string as > pointed argument, that arguent is a file, path or machine name, where > #0-#1F are not allowed or either relevant. > Or did I overlook anything? Jeeze, excuse me. In dos4 and using Turbo Pascal on a 386 in 1994(?), when writing a txt file with a null char in it, there wasn't a problem. When reading it back in, dos would truncate the file at the null char. Your mileage may vary. Look, i have met only one other computer programmer in real life, ever, even going back to the Z80/6502/8035 days. I know only one person who even HAS a puter in this state now. So while you guys have puter jobs, and easily make yourself understood because you speak to other programmers daily, WEEKS go by here between times i even SEE another human,,, let alone speak to one. Kat