Function Pointer
In some languages, a pointer can reference a function. The function pointer will store the address location of the function to be invoked. While this facility can be used to call functions dynamically, It is often the favorite method of virus and other malicious software writers. For example, in C it is possible to define a function pointer.
int a,b,x,y; int sum(int no1,int no2); // Function with two integer arguments which returns an integer value int (*fp)(int,int); // Function pointer which can point to a function like sum fp = ∑ // fp now points to Function sum x = (*fp)(a,b); y = sum(a,b); // Both lines call the function sum with parameters a and bRead more about this topic: Pointer (computer Programming)
Famous quotes containing the words function and/or pointer:
“The press and politicians. A delicate relationship. Too close, and danger ensues. Too far apart and democracy itself cannot function without the essential exchange of information. Creative leaks, a discreet lunch, interchange in the Lobby, the art of the unattributable telephone call, late at night.”
—Howard Brenton (b. 1942)
“The hardiest skeptic who has seen a horse broken, a pointer trained, or has visited a menagerie or the exhibition of the Industrious Fleas, will not deny the validity of education. A boy, says Plato, is the most vicious of all beasts; and in the same spirit the old English poet Gascoigne says, A boy is better unborn than untaught.”
—Ralph Waldo Emerson (18031882)