C++ implementation of an MSRP stack (old, outdated)