|
|
|
|
|
by peterfirefly
245 days ago
|
|
succ(seg(x)) and pred(seg(x)) turned out to be equivalent of just seg(x) in TP6. Earlier versions of Turbo Pascal (and Poly Pascal) generated poor code for "... + 1" but better code with succ(...) and doing memory access via memw[s:o] was common for speed for certain kinds of code. Allocating whatever size you needed + 16 guaranteed you had allocated enough to have paragraph aligned allocation (16 instead of 15 so you could just use the segment + 1). I think it took a day or two to find this bug in some text-mode windowing code I'd written. |
|