
FB II Compiler
PG PRO
Debugging
Memory
System
Mathematics
Resources
Disk I/O
Windows
Controls
Menus
Mouse
Keyboard
Text
Fonts
Drawing
Sound
Clipboard
Printing
Communication
ASM
|
DEBUGGING
Avoid Odd variable address error
Add a 1 byte global (i.e., DIM dummy%;1) to your globals.
Try looking in your globals, or even doing a trial compile on them as the problem may be there. Look for a record or bunch of variables that you have changed.
Probably one byte vars, chains containing even number of chars, and records where the length is odd.
Have have this in the past, and got round it just by moving variable declarations around in the GLOBALS file.
Next time I'll read the Staz Tech Notes before I post to the list. I saw the note about the even numbered arrays which, with element 0, creates an odd variable total and I had done just that. Changed a 10 to an 11 in the globals file and all is well. What threw me was that a trial compile of the Globals file showed no abnormalities and the error was occurring at the end of an INCL compile.
Just changing an array index from 10 to an 11 will not solve the problem I was addressing. Any array index (i.e., a%(10), a#(11), a!(12) ) will give you an even number of bytes. The problem you described comes about when you try to use only one single byte variable, or an odd byte variable (i.e., DIM a;3) or a record with an odd number of bytes. That was the reason I suggested DIMing another one byte variable.
|