Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/core/StarJsonExtra.cpp
diff options
context:
space:
mode:
authorKae <80987908+Novaenia@users.noreply.github.com>2023-06-27 20:23:44 +1000
committerKae <80987908+Novaenia@users.noreply.github.com>2023-06-27 20:23:44 +1000
commit332983c97b7a729c4dc5f19aa9ee4a22c420f7d8 (patch)
treefd9c441b796b522bdd5c7f8fbd32f51b8eff2a28 /source/core/StarJsonExtra.cpp
parent14b9689b6d4f4ad5276c88130dc6e449bedc0709 (diff)
The Formatting String Catastrophe
Diffstat (limited to 'source/core/StarJsonExtra.cpp')
-rw-r--r--source/core/StarJsonExtra.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/core/StarJsonExtra.cpp b/source/core/StarJsonExtra.cpp
index d683ca1..ec6fe90 100644
--- a/source/core/StarJsonExtra.cpp
+++ b/source/core/StarJsonExtra.cpp
@@ -147,7 +147,7 @@ RectD jsonToRectD(Json const& v) {
auto upperRight = jsonToVec2D(v.get(1));
return RectD(lowerLeft, upperRight);
} catch (JsonException const& e) {
- throw JsonException(strf("Inner position not well formed in jsonToRectD: %s", outputException(e, true)));
+ throw JsonException(strf("Inner position not well formed in jsonToRectD: {}", outputException(e, true)));
}
}
@@ -178,7 +178,7 @@ RectI jsonToRectI(Json const& v) {
auto upperRight = jsonToVec2I(v.get(1));
return RectI(lowerLeft, upperRight);
} catch (JsonException const& e) {
- throw JsonException(strf("Inner position not well formed in jsonToRectI: %s", outputException(e, true)));
+ throw JsonException(strf("Inner position not well formed in jsonToRectI: {}", outputException(e, true)));
}
}
@@ -201,7 +201,7 @@ RectU jsonToRectU(Json const& v) {
auto upperRight = jsonToVec2U(v.get(1));
return RectU(lowerLeft, upperRight);
} catch (JsonException const& e) {
- throw JsonException(strf("Inner position not well formed in jsonToRectU: %s", outputException(e, true)));
+ throw JsonException(strf("Inner position not well formed in jsonToRectU: {}", outputException(e, true)));
}
}
@@ -226,7 +226,7 @@ Color jsonToColor(Json const& v) {
} else if (v.type() == Json::Type::String) {
return Color(v.toString());
} else {
- throw JsonException(strf("Json of type %s cannot be converted to color", v.typeName()));
+ throw JsonException(strf("Json of type {} cannot be converted to color", v.typeName()));
}
}