@@ -234,14 +234,15 @@ sendParserHighlighting =
234234
235235sendHighlighting :: [(FC, OutputAnnotation)] -> Idris ()
236236sendHighlighting highlights =
237− do ist <- getIState
237+ do let highlights_uniq = nub highlights
238+ ist <- getIState
238239 case idris_outputmode ist of
239240 RawOutput _ -> updateIState $
240241 \ist -> ist { idris_highlightedRegions =
241− highlights ++ idris_highlightedRegions ist }
242+ highlights_uniq ++ idris_highlightedRegions ist }
242243 IdeMode n h ->
243244 let fancier = [ toSExp (fc, fancifyAnnots ist False annot)
244− | (fc, annot) <- highlights, fullFC fc
245+ | (fc, annot) <- highlights_uniq, fullFC fc
245246 ]
246247 in case fancier of
247248 [] -> return ()