码迷,mamicode.com
首页 >  
搜索关键字:dangling pointer    ( 2210个结果
const char*,char *const,const char*const
const char * cp;cp is a pointer to const char;cp是一个指针变量,指向一个常量字符创,注意cp是指针变量,指向const char,那么意味着cp可以指向其他的const char;但需要注意的是cp指向的是const char,所以不能通过cp来修改const char;cp可以指向其他其他的const char和通过cp来修改const cha...
分类:其他好文   时间:2014-09-20 08:53:07    阅读次数:188
IAR MSP430设置合理堆栈大小(the stack pointer for stack is outside the stack range)
摘要: 本文给出IAR设置堆栈合理大小的详细方法,并分享一些好博文(icf及map讲解)。 最近在MSP430-169LCD(MSP430F169,RAM为2KB)调试一些ucos演示例子,IAR for MSP430默认的堆栈大小是80字节,编译可以通过,运行结果不确定性,调试过程会提示"the ...
分类:其他好文   时间:2014-09-19 15:24:55    阅读次数:205
css
.Coupon{ color:@Gray; h5{ color:@DimGray;} li{ position:relative;margin:0;font-size:12px; line-height:22px;cursor:pointer; &:hover .coupont_layer{disp...
分类:Web程序   时间:2014-09-18 18:05:34    阅读次数:175
Leetcode: Copy List with Random Pointer
A linked list is given such that each node contains an additional random pointer which could point to any node in the list or null.Return a deep copy ...
分类:其他好文   时间:2014-09-18 04:21:33    阅读次数:228
同类型结构体之间赋值不一定有效
同类型结构体之间赋值不一定有效 今天为这个问题debug好久... 之前看到一个关于结构体使用的技巧, 这个技巧能够避免内存零碎. 保证结构体所属内存尽量不要零散化. struct struct_name { element_type varible;         ...;         element_type  pointer[0]; } 关于该用法的介...
分类:其他好文   时间:2014-09-17 23:20:32    阅读次数:238
用函数指针实现的快速排序算法
K&R第五章介绍了用函数指针实现的快速排序算法,对其中的代码比较困惑,所以看了下《算法导论》上对快排的介绍,下面这张图说明了快排的原理及过程: 用C实现上面的过程: #include /* declare function pointer */ typedef int(*fp_operation)(int a, int b); void swap(int *a, int...
分类:其他好文   时间:2014-09-17 21:58:12    阅读次数:320
Siebel NextRecord And DeleteRecord In Loops Skips Record
DeleteRecord implicitly moves the record pointer to the next record in the record set. If a call to NextRecord is made after a call to DeleteRecord th...
分类:其他好文   时间:2014-09-17 18:14:22    阅读次数:187
智能指针原理与简单实现
当类中有指针成员时,一般有两种方式来管理指针成员:一是采用值型的方式管理,每个类对象都保留一份指针指向的对象的拷贝;另一种更优雅的方式是使用智能指针,从而实现指针指向的对象的共享。 智能指针(smart pointer)的一种通用实现技术是使用引用计数(reference count)。智能指针类将...
分类:其他好文   时间:2014-09-17 11:47:22    阅读次数:190
智能指针
http://blog.csdn.net/hackbuteer1/article/details/7561235智能指针(smart pointer)是存储指向动态分配(堆)对象指针的类,用于生存期控制,能够确保自动正确的销毁动态分配的对象,防止内存泄露。它的一种通用实现技术是使用引用计数(refe...
分类:其他好文   时间:2014-09-16 23:25:41    阅读次数:231
STL之auto_ptr
What's auto_ptr? The auto_ptr type is provided by the C++ standard library as a kind of a smart pointer that helps to avoid resource leaks when excep....
分类:其他好文   时间:2014-09-16 23:25:21    阅读次数:214
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!