From 7a3ebede6972dd620ecdf8f70cfbe61ff4ecf262 Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 3 Apr 2019 10:44:00 +0800 Subject: =?UTF-8?q?=E8=87=AA=E5=AE=9A=E4=B9=89=E5=AF=B9=E8=B1=A1=E4=B9=9F?= =?UTF-8?q?=E4=BC=9A=E6=8F=90=E7=A4=BAchild?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/src/core/hover/hover.lua | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'server/src') diff --git a/server/src/core/hover/hover.lua b/server/src/core/hover/hover.lua index dfaeed35..a7fcca19 100644 --- a/server/src/core/hover/hover.lua +++ b/server/src/core/hover/hover.lua @@ -122,9 +122,10 @@ end local function getValueHover(source, name, value, lib) local valueType = value:getType() + local class if not lib then - local class = findClass(value) + class = findClass(value) if class then valueType = class end @@ -164,7 +165,11 @@ local function getValueHover(source, name, value, lib) text = ('%s %s: %s'):format(tp, name, unpackTable(value)) else if literal == nil then - text = ('%s %s: %s'):format(tp, name, valueType) + if class then + text = ('%s %s: %s %s'):format(tp, name, valueType, unpackTable(value)) + else + text = ('%s %s: %s'):format(tp, name, valueType) + end else text = ('%s %s: %s = %s'):format(tp, name, valueType, literal) end -- cgit v1.2.3