Use C++11 std::vector.data() and std::vector.insert() with initializer lists to avoid tons of terrible code.