A pointer is a variable type that allows you to refer indirectly to another object. Instead of holding data, a pointer holds the address to data -- the address of another variable or object. You can change the address value a pointer points to thus changing the variable or object the pointer is pointing to.
A reference is a type of pointer that cannot change and it must always point to a valid storage (no nulls).
Delphi Pointers
Although pointer data types in Delphi coding are less important and not required for most general coding, Delphi fully supports developer defined pointers. Use a carrot (^) to declare a pointer data type. Use the @ operator or Addr function to return the current address of a variable.
Delphi provides typed pointer types such as PChar and PExtended as well as a generic point to anything Pointer type.
Nil is a special pointer value that you can assign to any type of pointer. Nil never points to any valid memory and indicates an unassigned or empty pointer.
Syntax Example: //Declare a pointer of type integer.
PCounter : ^Integer;
//Assign a value to the location of a pointer.
//Also known as dereferencing.
PCounter^ := 8;
//Assign address of A to B.
PointerB := @PointerA; //or...PointerB := Addr(PointerA);