由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Programming版 - Why do I need to use "plain" pointer?
相关主题
is smart_ptr really that good?一个简单的小问题
pointer overflow请问可以这样定义struct吗?
C++ Q05: pointer to constant variable how to do it ?=======Problem – coding in c++
C++ Q93 - Q95 (转载)[合集] pointer in C
int F::*x = &F::x是什么意思?about STL functor and function pointers
c++ 里用到pointer 的地方我们尽可能用smart pointer吗?what's the purpose of pointer to pointers?
不如各位高手挑个专题讲讲C++11吧find start point of loop from linked list
Go adopts JavaScript’s idea of semicolon insertionc++ pointers are iterators, why?
相关话题的讨论汇总
话题: pointer话题: why话题: plain话题: smart话题: pointers
进入Programming版参与讨论
1 (共1页)
h*****n
发帖数: 38
1
为什么不用smart pointer,而要用pointer呢?
q*****g
发帖数: 72
2
ya, good question
all java "pointers" are smart pointers
but that's one reason java is slower than C++

【在 h*****n 的大作中提到】
: 为什么不用smart pointer,而要用pointer呢?
h*****n
发帖数: 38
3
So, only for the performance sake?

【在 q*****g 的大作中提到】
: ya, good question
: all java "pointers" are smart pointers
: but that's one reason java is slower than C++

t****t
发帖数: 6806
4
i guess c++ tries to imitate c while adding OO. pointer is inherited from c
and is closer to hardware behaviour (than smart pointers).
well there's trade off everywhere. c++ is just result of some trade off
between execution efficiency and developping efficiency. some language make
some job easy, while making some other job (nearly) impossible. some
language make all jobs equally difficult (or equally easy, depending on the
point of view).
smart pointer makes you safer since you don't have maint

【在 q*****g 的大作中提到】
: ya, good question
: all java "pointers" are smart pointers
: but that's one reason java is slower than C++

1 (共1页)
进入Programming版参与讨论
相关主题
c++ pointers are iterators, why?int F::*x = &F::x是什么意思?
有什么工具可以检查内存泄漏么c++ 里用到pointer 的地方我们尽可能用smart pointer吗?
一个C#使用C++.NET类库的问题不如各位高手挑个专题讲讲C++11吧
difference between: char** p and char*p[] ??Go adopts JavaScript’s idea of semicolon insertion
is smart_ptr really that good?一个简单的小问题
pointer overflow请问可以这样定义struct吗?
C++ Q05: pointer to constant variable how to do it ?=======Problem – coding in c++
C++ Q93 - Q95 (转载)[合集] pointer in C
相关话题的讨论汇总
话题: pointer话题: why话题: plain话题: smart话题: pointers