answersLogoWhite

0


Best Answer

A universal pointer is a pointer variable that does not specify the type being pointed at. That is, it can be used to store any memory address regardless of the type of object actually stored at that address. It can be likened to a variable type, but you cannot dereference the memory address without providing some mechanism for determining the actual type stored at that memory address. Generally you would use a universal pointer when you don't actually care what type resides at the address, you are only interested in the address itself. But just as a typed pointer can point to 0 (or NULL), so can a universal pointer, which simply means it points at nothing at all.

User Avatar

Wiki User

11y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

8y ago

Generic pointers are pointers of the type void*. They can point to any object, but you cannot dereference a void* nor can you perform pointer arithmetic because the compiler won't know the runtime type of the object you are actually pointing at. It's up to you to determine the proper runtime type and then cast the pointer to the appropriate pointer type.

This answer is:
User Avatar

User Avatar

Wiki User

12y ago

dont no

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is a universal pointer?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

What is universal pointers?

A universal pointer is a pointer variable that does not specify the type being pointed at. That is, it can be used to store any memory address regardless of the type of object actually stored at that address. It can be likened to a variable type, but you cannot dereference the memory address without providing some mechanism for determining the actual type stored at that memory address. Generally you would use a universal pointer when you don't actually care what type resides at the address, you are only interested in the address itself. But just as a typed pointer can point to 0 (or NULL), so can a universal pointer, which simply means it points at nothing at all.


What is a universal symbolism?

A universal symbol is some kind of sign that is recongized by pretty much everyone, and it doesn't matter if the people don't speak the same language and aren't from the same place. For example, a heart is the universal symbol for Love and putting up your pointer and middle finger is a symbol for Peace.


Difference between pointer to constant and constant pointer?

1. pointer to a constant means you can not change what the pointer points to 2. constant pointer means you can not change the pointer.


What is triple pointer?

Example: int x; -- integer int *px= &x; -- pointer to integer int **ppx= &px; -- pointer to pointer to integer int ***pppx= &ppx; -- pointer to pointer to pointer to integer


What are pointer to pointer?

A pointer only holds an address information (location) in the memory. if a pointer holds points another pointer then it is a pointer to an other pointer. Pointer holds an address in the memory so in that address there is an other location information that shows another location.


What is pointer of pointer?

pointer is the variable that holds the address of another variable


Why is double pointer used?

Double pointer is a pointer to a pointer. So you can work with the double pointer as you work with a single one.Or you might mean 'pointer to double', eg:void clear_double (double *dp){*dp = 0;}


Define pointer to pointer in c?

Double (**) is used to denote the double pointer. As we know the pointer stores the address of variable, Double pointer stores the address of any pointer variable. Declaration : int **ptr2Ptr;


What is void pointer and what are its uses?

Void pointer can hold the address of any kind of pointer. But we can't operate on void pointer


C program pointers to pointers examples?

Pointer to Pointer is a double pointer, denoted by (**). Pointer stores the address of the variable and pointer to pointer stores the address of a pointer variable and syntax can be given as int **ptr2ptr;


What is the mouse pointer?

the move pointer


What a cell pointer?

A cell pointer is a