[fpc-pascal]About order of units...

L D Blake ldblake at sympatico.ca
Sun Aug 31 16:39:50 CEST 2003


In reply to your message of August 31, 2003

> If you have a look at the implementation, you'll quickly find, that 
> all of the examples you listed in this mail make absolutely _no_ 
> difference.

It DOES matter, especially in structures where windows is accessing things as
an offset from a pointer. Typing something as a 4 byte variable instead of a 1
or 2 byte one will result in wrong structure sizes causing all kinds of errors
inside windows where we can't really trace them down... The same is true of
parameters passed in API calls, hand it 4 bytes instead of 1 or 2 and you've
just offset the rest of the parameters, causing errors, never mind the
potential for passing grossly incorrect data... and I'm pretty sure
that's what I've got going on.

As I explained earlier... I'm getting re-draw errors.  Not only is my project
losing it's title bars, it is redrawing window frames in the wrong places and
sometimes it redraws the wrong window altogether...  Try moving one window and
it draws the frame of a different window in the wrong place on the screen.

If I turn on range checking I get a 201 error (range check) from my program
every time I try to open an HTML file (i.e. the FP docs) in IE... This is
especially weird since int's only HTML and only in IE... nothing else. And I
get hundreds of Range errors as the program runs (it's mostly api calls at
this point).

Errors like these from supplied units is a serious impediment to the
developement of bug free, reliable software, which is what Pascal is supposed
to be all about.  It's strength is in it's rigid error checking.

-----
 L D Blake





More information about the fpc-pascal mailing list