This began as a further attempt to implement the Maybe monad in C++, but quickly spiralled out of control and now includes an implementation of the List monad as well (using std::list!). This is really for my own amusement rather than to try and do anything useful with them. It also gave me an excuse to try out C++ 11 lambda functions for the first time.
My original implementation defined a macro called MBind
which caused a number
of problems -- thankfully [PJayB][pjayb] managed to find a way around that so