tons of cosmetic cleanups to container data structure impl code