3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2026-02-13 12:23:01 +00:00

Reapply PR #8190: Replace std::ostringstream with C++20 std::format (#8204)

* Initial plan

* Reapply PR #8190: Replace std::ostringstream with C++20 std::format

Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
This commit is contained in:
Copilot 2026-01-15 21:30:29 -08:00 committed by GitHub
parent 7d899fdc43
commit 6e68911cbb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 87 additions and 104 deletions

View file

@ -71,3 +71,11 @@ inline std::string& operator+=(std::string& s, mk_pp const& pp) {
return s = s + pp;
}
// Helper function to convert streamable objects (like mk_pp) to strings for use with std::format
template<typename T>
inline std::string to_string(T const& obj) {
std::ostringstream strm;
strm << obj;
return std::move(strm).str();
}