summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--script/provider/diagnostic.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/script/provider/diagnostic.lua b/script/provider/diagnostic.lua
index c01c56b0..a649ce8b 100644
--- a/script/provider/diagnostic.lua
+++ b/script/provider/diagnostic.lua
@@ -208,7 +208,7 @@ function m.doDiagnostic(uri, isScopeDiag)
local syntax = m.syntaxErrors(uri, state)
local diags = {}
- local lastDiag = m.cache[uri]
+ local lastDiag = util.deepCopy(m.cache[uri])
local function pushResult()
tracy.ZoneBeginN 'mergeSyntaxAndDiags'
local _ <close> = tracy.ZoneEnd