In C++, we have all sorts of std containers, such as vector. Normally, when we work with vectors, we also pass them around by reference, and vectors of course own their data in a contiguous way. When a vector is passed to a function, we pass it by reference: In C++20, there is a newContinue reading “How std::span changes C++ fundamentally”
Category Archives: learning c++
C++ comma operator and parallelization
I have never had a reason to use the comma operator, however, writing some modern code, it seems required. Say you have some series of variables and you want to perform a common operation on the group. New C++ is always a fun thing, I know. We could change this to be a generic functionContinue reading “C++ comma operator and parallelization”
C++ Binary Serializer
Binary Serialization can be sort of scary, maybe, to some people. Fortunately, it is super simple, straight forward, and even elegant, in C++. Binary data is the raw representation of information on the computer, and there are easy ways to work with it in C++. The benefits of using Binary are that it can saveContinue reading “C++ Binary Serializer”
Programming Basics with C++ explained in Assembly
What the basics of c++ are actually doing under the hood.