We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
If I have declare a generic pointer [char *test] in C; How do I determine the pointer type in runtime? By checking the first byte of the pointer or is there any other functions doing this? Thanks in advance
Yes, you can pick apart the pointer to determine to which memory space it points. The first byte is a tag byte, or extra address bits for far pointers; the other two are offsets into the memory space. Details are in the manual in the "Generic and Far Pointers" section, or you might check the "THEORY OF OPERATION" section about a page down into XBANKING.A51 in the library. You might also take a look at the macros in absacc.h. It has some predefined values that might be useful for comparison.