In an effort to provide more helpful error messages to my script writers, I have been looking for a way to make "null pointer access" a little more descriptive. Most of my script writers are technical people, but their programming training is very thin. "Null pointer access" pretty much doesn't mean anything to them. I am hoping to provide something like "Instance of CDemoClass has not been properly initialized" or something, potentially varying based on the object.
I don't have a good way of accomplishing this within the Exception callback framework, short of analyzing the line where an exception occurred. I have been considering adding object information, when it exists, to the context (something like m_exceptionObjectType) which could be read during the exception callback.
I know there are many instances where the object type is not readily available (like asBC_CHKREF), so I was wondering if you had any thoughts about this.
Thanks