diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-11-22 14:28:00 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-11-22 14:28:00 +0800 |
commit | dc7275ac9b56f26923c80c1e8bbce185c2d147a4 (patch) | |
tree | 8a5a325980feb3b0cd8b101ce5f37ee48779116d /server-beta/src/vm/getValue.lua | |
parent | 67ae2be22b43fec1c7bab1044842951eba84d37d (diff) | |
download | lua-language-server-dc7275ac9b56f26923c80c1e8bbce185c2d147a4.zip |
简单接入 hover 协议
Diffstat (limited to 'server-beta/src/vm/getValue.lua')
-rw-r--r-- | server-beta/src/vm/getValue.lua | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/server-beta/src/vm/getValue.lua b/server-beta/src/vm/getValue.lua index c8d62574..07ebe2a5 100644 --- a/server-beta/src/vm/getValue.lua +++ b/server-beta/src/vm/getValue.lua @@ -768,7 +768,10 @@ end function vm.isSameValue(a, b) local valuesA = vm.getValue(a) local valuesB = vm.getValue(b) - if valuesA == valuesB and valuesA ~= nil then + if not valuesA or not valuesB then + return false + end + if valuesA == valuesB then return true end local values = {} |