What is the correct way to declare a pointer to a __far pointer?

For the built-in purpose, I use far pointers to access some parts of the memory card.

next to the pointer (without explicitly indicating __near):

unsigned int * VariableOnePtr;

Pointer to the nearest pointer:

unsigned int ** VariableOnePtrPtr;

far pointer:

unsigned int * __ far VariableTwoPtr;

What is the correct way to declare a pointer to a far pointer? Should this pointer be the biggest pointer?

+3
source share
3 answers

I believe you will do this:

unsigned int * __far *VariableThreePtrPtr;

Further pointer to the far pointer:

unsigned int * __far * __far VariableFourPtrPtr;
+6
source

"__ far" - , , . . .

+3

You can also use typedef for this, for example

typedef unsigned int *__far VariableTwoPtr_t;
VariableTwoPtr_t* VariableTwoPtrPtr;
+2
source

Source: https://habr.com/ru/post/1698615/


All Articles