SE250:HTTB:Pointers:Function pointers
<html>
<image src="http://www.rajithaonline.com/SE250/httb/pointers/final/function_pointers_head.png" width="385" height="92" alt="Function Pointers Header Logo" /> |
</html>
Previous Page | Contents | Next Page |
Function Pointers
A pointer to a function contains the address of a function in memory. As an array name is really the address in memory of the first element of the array, a function name is really the starting address in memory of the code which is the function. Pointers to functions can be passed to functions, returned from functions, stored in arrays and assigned to other function pointers.
A pointer to a function is dereferenced to use the function, similar to how a pointer to a variable is dereferenced to access the value of the variable.
Previous Page | Contents | Next Page |