diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2021-06-10 15:15:00 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2021-06-10 15:15:00 +0800 |
commit | 0317157103c58c55035305e93db2bc3382f9d334 (patch) | |
tree | c95879dc83c4b63f3b63fe88091c60af09d7b2c8 /script/core | |
parent | 94d0a2b40dd7ea1aed8bd361461306053d40bb99 (diff) | |
parent | 24b3c06cd70050fc98e3946cfd343395d4f11ddf (diff) | |
download | lua-language-server-0317157103c58c55035305e93db2bc3382f9d334.zip |
Merge remote-tracking branch 'origin/master' into 2.0.0
Diffstat (limited to 'script/core')
-rw-r--r-- | script/core/hover/init.lua | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/script/core/hover/init.lua b/script/core/hover/init.lua index ea86f785..5dd00c43 100644 --- a/script/core/hover/init.lua +++ b/script/core/hover/init.lua @@ -156,6 +156,14 @@ local function getHoverByUri(uri, offset) return nil end local hover = getHover(source) + if SHOWSOURCE then + hover.description = ('%s\n---\n\n```lua\n%s\n```'):format( + hover.description or '', + util.dump(source, { + deep = 1, + }) + ) + end return hover end |