summaryrefslogtreecommitdiff
path: root/xmake/core/base/dump.lua
diff options
context:
space:
mode:
Diffstat (limited to 'xmake/core/base/dump.lua')
-rw-r--r--xmake/core/base/dump.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/xmake/core/base/dump.lua b/xmake/core/base/dump.lua
index 66e0208fc..303888ff0 100644
--- a/xmake/core/base/dump.lua
+++ b/xmake/core/base/dump.lua
@@ -4,7 +4,7 @@ local table = require("base/table")
local _dump = {}
function _dump._string(str, as_key)
- local quote = (not as_key) or str:match("%s")
+ local quote = (not as_key) or (not str:match("^[a-zA-Z_][a-zA-Z0-9_]*$"))
if quote then
io.write(colors.translate("${cyan}\""))
end