void StackTraceImpl::copy_symbols(const StackTrace& other) { // todo: work it from the bottom, and break out of // the loop as soon as the frames don't match const size_t n = std::min(frames_.size(), other.size()); for (size_t i = 0; i != n; ++i) { Frame* f = other.frame(i); Frame* g = frames_[i].get(); if (f->program_count() != g->program_count()) { continue; } if (Symbol* sym = f->function(no_symbol)) { g->function(sym); } } }