The analogue of "fill-pointer" in D
John Colvin via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Mon May 18 02:00:52 PDT 2015
On Monday, 18 May 2015 at 08:21:38 UTC, Dennis Ritchie wrote:
> Hi,
>
> In Common Lisp, there is such a thing as a fill-pointer
> (Example 5):
> http://www.tutorialspoint.com/lisp/lisp_arrays.htm
>
> Does D some equivalent?
Fill pointers, combined with the various helper functions (e.g.
vector-push) and vector-extend, perform tasks that D uses slices
for.
e.g. vector-push-extend is roughly equivalent to the ~= operator,
given a non-aliased array.
There are important differences, but the functionality overlaps a
lot.
More information about the Digitalmars-d-learn
mailing list