With asm6809 being my goto tool for any Dragon development work, dare I suggest a few new pseudo-ops to make life even easier? Something along the lines of
ASSERT condition, message
WARNING message
ERROR message
INFO message
Especially the ASSERT would be tremendously useful when making assumptions about an EQU constant, e.g., when optimizing code based on such assumptions.
At least, I've added ASSERT - code's in the git repo. Can't guarantee I'll do a release before christmas though
At the moment you can give an optional message, but I'd like to figure out how to make it print the failed assertion if you don't. Trickier than it sounds - only whole lines of source text are held internally, everything else is - by the time the error is generated - only available as an abstract syntax tree.
Asserts work like a charm. I don't have a big problem with the message-less asserts either. As long as it produces an assertion error and a line reference, that also works for quick tests where I can't be bothered to actually write a meaningful message.