Category "pointers"

Is an iterator in C++ a pointer?

Is an iterator in C++ a pointer? The reason I ask is that it seems like nobody completely understands what an iterator is. It's just a "thing" or a "value" they

How do I do a literal *int64 in Go?

I have a struct type with a *int64 field. type SomeType struct { SomeField *int64 } At some point in my code, I want to declare a literal of this (say, w

f2py compilation error with type(c_ptr) from iso_c_binding

Summary I am trying to write a model using Fortran and I need to use a function to integrate (closed limits). I tried working with fgsl and the standalone scrip

What is the difference between std::reference_wrapper and a simple pointer?

Why is there a need to have std::reference_wrapper? Where should it be used? How is it different from a simple pointer? How its performance compares to a simple

pcl::PointCloud<pcl::PointXYZ> to pcl::PointCloud<pcl::PointXYZ>::Ptr (Covert poincloud to ptr)

I am using PCL 1.3. Is there any function to convert pointcloud to pointcloud::ptr. I am new at PCL libraries. I have a ROS node subscribing to sensor_msgs/Poin

Insertion sort error occurring in a C program

I am probably missing something simple here, but I was looking over some simple algorithms in C and have not been able to get the insertion sort in the code bel

How to get the pointer of return value from function call?

I just need a pointer to time.Time, so the code below seems invalid: ./c.go:5: cannot take the address of time.Now() I just wonder why? Is there any way t

Are Python variables pointers? Or else, what are they?

Variables in Python are just pointers, as far as I know. Based on this rule, I can assume that the result for this code snippet: i = 5 j = i j = 3 print(i) wou

Trying to reverse ObjPtr to an Object I'm getting kernel not found error 53 in 64 bits but not in 32 bits

I'm referring Parent class from Child class; instead of simply do, for example: Public Property Set Parent(obj As ClassProperties) Set this.ParentColl = ob

Acces element of QVector pointer containing pointers

I have the following QVector pointer: QVector<someStruct*>* qvp; How can I acces someStruct members? Let's assume that qvp has some elements to access al

How to check c++ pointer pointing to invalid memory address?

Is there anyone show me how to check my pointer is pointing to an invalid memory address. #include<iostream> class Node{ public: int data; Node * ne

What is the size of a pointer?

Is the size of a pointer the same as the size as the type it's pointing to, or do pointers always have a fixed size? For example... int x = 10; int * xPtr = &a

warning: format ‘%s’ expects type ‘char *’, but argument 2 has type ‘char (*)’

I am trying to run a simple C program but I am getting this error: warning: format ‘%s’ expects type ‘char *’, but argument 2 has ty

warning: format ‘%s’ expects type ‘char *’, but argument 2 has type ‘char (*)’

I am trying to run a simple C program but I am getting this error: warning: format ‘%s’ expects type ‘char *’, but argument 2 has ty