P2905R2 Fix - Refactor rvalue arguments into lvalues for std::make_format_args (#3194)

Co-authored-by: xiaoxiao921 <837334+xiaoxiao921@users.noreply.github.com>
This commit is contained in:
R.K
2024-05-29 10:50:59 -07:00
committed by GitHub
parent 8fef2f383c
commit fe0bcdd7ae
11 changed files with 47 additions and 26 deletions

View File

@ -10,10 +10,11 @@ namespace big
{
components::button("MORS_FIX_ALL"_T, [] {
int amount_fixed = mobile::mors_mutual::fix_all();
auto v_fixed = amount_fixed == 1 ? "VEHICLE_FIX_HAS"_T.data() : "VEHICLE_FIX_HAVE"_T.data();
g_notification_service.push_success("MOBILE"_T.data(),
std::vformat("VEHICLE_FIX_AMOUNT"_T.data(),
std::make_format_args(amount_fixed,
amount_fixed == 1 ? "VEHICLE_FIX_HAS"_T.data() : "VEHICLE_FIX_HAVE"_T.data())));
std::make_format_args(amount_fixed, v_fixed)));
});
ImGui::SameLine();