From c9c4a0046f6ec2f0f2f4699e49d8809629a055f2 Mon Sep 17 00:00:00 2001 From: ruki Date: Wed, 25 Nov 2020 23:21:13 +0800 Subject: improve package/configs --- xmake/actions/require/impl/package.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xmake/actions/require/impl/package.lua b/xmake/actions/require/impl/package.lua index 599d076c1..2a0137967 100644 --- a/xmake/actions/require/impl/package.lua +++ b/xmake/actions/require/impl/package.lua @@ -292,8 +292,8 @@ function _check_package_configurations(package) for name, value in pairs(package:configs()) do local conf = configs_defined[name] if conf then - local config_type = conf.type or "string" - if type(value) ~= config_type then + local config_type = conf.type + if config_type ~= nil and type(value) ~= config_type then raise("package(%s %s): invalid type(%s) for config(%s), need type(%s)!", package:name(), package:version_str(), type(value), name, config_type) end if conf.values then -- cgit v1.3.1