Author image

C++ Vector Implementation


Difficulty:
3/5


A C++17 ready, allocator_traits aware Vector similar to std::vector ; made to become familiar with the internals of C++ standard library containers.

TODO:

  • fix some obscure Iterator problems (perhaps add begin() and end() to it) - we'll see
  • shrinkToFit(#) : if current storage is larger than # Bytes, it shrinks it to # bytes
  • halfSize() shrink

I won't attempt to create a full tutorial on this, because LokiAstari has covered this in excruciating detail already - in a level I can't hope to match (check out acknowledgements section below).

I used Windows, Visual Studio & C++17 to build the project.

Github

Github repository link.

Acknowledgements

Special thanks to LokiAstari (blog post) for his in-depth tutorials!


0 likes