util/format.lua
changeset 12785 22066b02887f
parent 12594 5eaf77114fdb
child 12979 d10957394a3c
--- a/util/format.lua	Thu Oct 20 16:56:45 2022 +0200
+++ b/util/format.lua	Wed Oct 19 16:25:05 2022 +0200
@@ -11,9 +11,7 @@
 local valid_utf8 = require "util.encodings".utf8.valid;
 local type = type;
 local dump = require "util.serialization".new("debug");
-local num_type = math.type or function (n)
-	return n % 1 == 0 and n <= 9007199254740992 and n >= -9007199254740992 and "integer" or "float";
-end
+local num_type = math.type;
 
 -- In Lua 5.3+ these formats throw an error if given a float
 local expects_integer = { c = true, d = true, i = true, o = true, u = true, X = true, x = true, };