# # # patch "sanity.cc" # from [138093daf9687e823c9246b0708b7185f422ef45] # to [142c4f89d1272a0703550c4c49f00ecdccdef94a] # ============================================================ --- sanity.cc 138093daf9687e823c9246b0708b7185f422ef45 +++ sanity.cc 142c4f89d1272a0703550c4c49f00ecdccdef94a @@ -106,9 +106,9 @@ catch (std::exception & e) { ui.inform(F("fatal: formatter failed on %s:%d: %s") - % file - % line - % e.what()); + % file + % line + % e.what()); throw; } } @@ -293,17 +293,18 @@ void MusingBase::gasp_head(std::string & out) const { out = (boost::format("----- begin '%s' (in %s, at %s:%d)\n") - % name % func % file % line - ).str(); + % name % func % file % line + ).str(); } void MusingBase::gasp_body(const std::string & objstr, std::string & out) const { - out += (boost::format("%s" - "----- end '%s' (in %s, at %s:%d)\n") - % objstr - % name % func % file % line - ).str(); + out += (boost::format("%s%s" + "----- end '%s' (in %s, at %s:%d)\n") + % objstr + % (*(objstr.end() - 1) == '\n' ? "" : "\n") + % name % func % file % line + ).str(); }