Combine module lists into one using std::copy instead of for each loop.