3 ms·
> some other structure hanging onto the original reference. Let's unleash the superpower of C. You should've been using pointers to a pointer so that it is alw
by chelahmy 10y ago
> some other structure hanging onto the original reference.
Let's unleash the superpower of C. You should've been using pointers to a pointer so that it is always a single reference to a memory block.
You can't really be programming in C if you're not thinking in pointers.
One more thing; The article should have mentioned "pointer increment" which has nothing to do with "+= 1".
- kbp 10y ago> One more thing; The article should have mentioned "pointer increment" which has nothing to do with "+= 1". What do you mean? ++ptr is perfectly equivalent to ptr += 1, for any pointer type.
- deleted 10y ago[deleted]
- chelahmy 10y agoI read it as integer arithmetic. It is semantically different from pointer arithmetic.
- rrauenza 10y agoSo it's turt^H^H^H^Hpointers all the way down?
- chelahmy 10y agoWill the following help with the depth, or any depth? int *a, **b, **c, **d; d = c = b = &a;