summaryrefslogtreecommitdiff
path: root/server/src/vm
diff options
context:
space:
mode:
authorsumneko <sumneko@hotmail.com>2019-04-16 15:23:12 +0800
committersumneko <sumneko@hotmail.com>2019-04-16 15:23:12 +0800
commit20b609862d1536b1aa6befdca3eef9dedb58fc91 (patch)
treeee23bdf964a39ce2c54b6fe0ea7770d0fdee809c /server/src/vm
parentbd38c1bd2ceed3121d86ff99f73dbf4815ed18e7 (diff)
downloadlua-language-server-20b609862d1536b1aa6befdca3eef9dedb58fc91.zip
修正值类型优先级失效的bug
Diffstat (limited to 'server/src/vm')
-rw-r--r--server/src/vm/value.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/src/vm/value.lua b/server/src/vm/value.lua
index d765883e..425cc0b2 100644
--- a/server/src/vm/value.lua
+++ b/server/src/vm/value.lua
@@ -84,8 +84,8 @@ function mt:getType()
mRate = rate
mType = tp
elseif rate == mRate then
- local level1 = TypeLevel[rate] or 0.0
- local level2 = TypeLevel[mRate] or 0.0
+ local level1 = TypeLevel[tp] or 0.0
+ local level2 = TypeLevel[mType] or 0.0
if level1 > level2 then
mRate = rate
mType = tp