首页 > 其他 > 详细

pointer

时间:2016-10-28 02:58:49      阅读:164      评论:0      收藏:0      [点我收藏+]

https://en.wikipedia.org/wiki/Pointer_(computer_programming)

In computer science, a pointer is a programming language object, whose value refers to (or "points to") another value stored elsewhere in the computer memory using its memory address. A pointer referencesa location in memory, and obtaining the value stored at that location is known as dereferencing the pointer. As an analogy, a page number in a book‘s index could be considered a pointer to the corresponding page; dereferencing such a pointer would be done by flipping to the page with the given page number.

Pointers to data significantly improve performance for repetitive operations such as traversing strings, lookup tables, control tables and tree structures. In particular, it is often much cheaper in time and space to copy and dereference pointers than it is to copy and access the data to which the pointers point.

Pointers are also used to hold the addresses of entry points for called subroutines in procedural programming and for run-time linking to dynamic link libraries (DLLs). In object-oriented programming, pointers to functions are used for bindingmethods, often using what are called virtual method tables.

pointer

原文:http://www.cnblogs.com/yuanjiangw/p/6006197.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!