TOOLS/nan-test.lua: fix lint warnings

This commit is contained in:
Guido Cella authored and Kacper Michajłow committed 2024-06-02 22:26:00 +02:00
1 parent c12e437d43
commit 5977722adc
2 files changed
+3 -4

No files matched your search

-1
View File
@@ -110,7 +110,6 @@ max_line_length = 100
-- TODO: Remove everything below this line
local todo = {
"player/lua/osc.lua",
"TOOLS/lua/nan-test.lua",
"TOOLS/lua/observe-all.lua",
"TOOLS/lua/osd-test.lua",
"TOOLS/lua/status-line.lua",
+3 -3
View File
@@ -3,10 +3,10 @@
local utils = require 'mp.utils'
prop_name = "scale-param1"
local prop_name = "scale-param1"
-- internal NaN, return string "default" instead of NaN
v = mp.get_property_native(prop_name, "fail")
local v = mp.get_property_native(prop_name, "fail")
print("Exp:", "string", "\"default\"")
print("Got:", type(v), utils.to_string(v))
@@ -25,7 +25,7 @@ print("Exp:", "number", 123)
print("Got:", type(v), utils.to_string(v))
-- try to set an actual NaN
st, msg = mp.set_property_number(prop_name, 0.0/0)
local st, msg = mp.set_property_number(prop_name, 0.0/0)
print("Exp:", nil, "<message>")
print("Got:", st, msg)