These are two different concepts, you cannot compare them. What the difference between the skunk and the moonlight?

Null pointer is a special reserved value of a pointer. A pointer of any type has such a reserved value. Formally, each specific pointer type (int *, char * etc.) has its own dedicated null-pointer value. Conceptually, when a pointer has that null value it is not pointing anywhere.

Void pointer is a specific pointer type - void * - a pointer that points to some data location in storage, which doesn't have any specific type.

So, once again, null pointer is a value, while void pointer is a type. These concepts are totally different and non-comparable.

differences between null pointer and void pointer.的更多相关文章

  1. Pointer arithmetic for void pointer in C

    http://stackoverflow.com/questions/3523145/pointer-arithmetic-for-void-pointer-in-c When a pointer t ...

  2. delete void pointer

    delete void pointer是否会有内存泄漏? 看下面一个简单例子 class Test{ public: Test(){ printf ("constructor\n" ...

  3. Heka 编译安装后 运行报错 panic: runtime error: cgo argument has Go pointer to Go pointer

    Heka 编译安装后 运行报错 panic: runtime error: cgo argument has Go pointer to Go pointer 解决办法: 1.  Start heka ...

  4. 野指针、NULL指针和void*

    一.野指针 “野指针”不是NULL指针,是指向“垃圾”内存的指针. “野指针”的成因主要有三种: (1)指针变量没有被初始化.任何指针变量刚被创建时不会自动成为NULL指针,它的缺省值是随机的,它会乱 ...

  5. 栈帧示意图:stack pointer、frame pointer

    更多参考:http://www.embeddedrelated.com/usenet/embedded/show/31646-1.php 一: The calling convention descr ...

  6. Void pointers in C

    In this article we are learning about “void pointers” in C language. Before going further it will be ...

  7. (原) c++ 杂

    Declaration of variables   C++ is a strongly-typed language, and requires every variable to be decla ...

  8. (转) Pointers

    原地址 http://www.cplusplus.com/doc/tutorial/pointers/ Pointers In earlier chapters, variables have bee ...

  9. Type system

    Type system[edit] Main articles: Data type, Type system, and Type safety A type system defines how a ...

随机推荐

  1. java中String类型的相关知识

    String类方法整理说明: ·Length()用来求字符串的长度,返回值为字符串的长度: ·charAt()取该字符串某个位置的字符,从0开始,为char类型: ·getChars()将这个字符串中 ...

  2. geekNews 学习总结

    1:下移隐藏,上移出现 //android.support.v4.widget.NestedScrollView nsvScroller; //FrameLayout llDetailBottom; ...

  3. Microsoft Visual Studio 2012正式版官方下载

    Microsoft Visual Studio 2012正式版官方下载 首先声明,看到园子里还没有类似的新闻,所以斗胆发首页,如有不妥之处,请移除并谅解. 虽然之前已经又用到泄露的MSDN正式版,但今 ...

  4. 面向GC的Java编程(转)

    转自:http://blog.hesey.net/2014/05/gc-oriented-java-programming.html Java程序员在编码过程中通常不需要考虑内存问题,JVM经过高度优 ...

  5. about hibernate lazy load and solution

    about hibernate lazy load is that used when loaded again.it can increase efficienty and sava memory. ...

  6. 明天学习一下验证码的匹配和thinkphp第十三章

    333333333 js 冒泡排序 var arr=[17,19,5,90,3];window.onload=function(){// alert(arr[0]);var len=arr.lengt ...

  7. 前台图片上传展示JS(单张图片展示)

    <script type="text/javascript">    //下面用于多图片上传预览功能    function setImagePreviews(aval ...

  8. geom设置—折线图

    折线图在R中也是很常见的一种图形,相对而言也比较简单. geom_line(mapping = NULL, data = NULL, stat = "identity", posi ...

  9. Python创建多进程,用Queue传递信息

    创建10个进程,分别计算0到1000各个区间的和,主进程汇总 __author__ = 'Administrator' # -*- coding:utf-8 -*- ''' @author:qiush ...

  10. 离线消息如何实现?-- ESFramework 4.0 快速上手(02)

    在ESFramework 4.0 快速上手一文中,主要介绍了如何使用ESPlus.Rapid命名空间中的引擎来快速地构建基于TCP的网络通信系统,即使是使用ESPlus.Rapid来进行ESFrame ...