util.xml: Fix float formatting of line and columns in error (on Lua 5.3+)
authorKim Alvefur <zash@zash.se>
Sat, 03 Oct 2020 16:22:56 +0200
changeset 11131 1d9cd1abc660
parent 11130 cc6b1dab01a2
child 11133 387d442497e7
util.xml: Fix float formatting of line and columns in error (on Lua 5.3+)
util/xml.lua
--- a/util/xml.lua	Sat Oct 03 15:09:12 2020 +0200
+++ b/util/xml.lua	Sat Oct 03 16:22:56 2020 +0200
@@ -71,7 +71,7 @@
 		if ok then
 			return stanza.tags[1];
 		else
-			return ok, err.." (line "..line..", col "..col..")";
+			return ok, ("%s (line %d, col %d))"):format(err, line, col);
 		end
 	end;
 end)();