In-memory build database

Untested, of course, like all of the other code.  I decided
to implement it in smart-pointer-less C++ to see how well it
would work out.
Document vtable and replication design patterns

* Removes a duplicated comment.
* Elaborates on some replication/deallocation strategies.
* Explains why vtables are often passed as parameters.
Document motivations for vtable implementation