feat(emacs): replace metavar '?M_n' with '_' in synthed expr
This commit is contained in:
parent
2edb53397f
commit
b18124e1a2
1 changed files with 6 additions and 2 deletions
|
@ -102,8 +102,12 @@ The return valus has the form of '([symbol-string] [start-pos])"
|
|||
(cl-multiple-value-setq (typeinfo overload synth)
|
||||
(lean-extract-info-at-pos file-name line-number column start-pos))
|
||||
(when synth
|
||||
(let ((synth-str
|
||||
(replace-regexp-in-string "?M_[0-9]+" "_" (lean-synth-body-str synth))))
|
||||
(when (search " " synth-str)
|
||||
(setq synth-str (concat "(" synth-str ")")))
|
||||
(delete-forward-char 1)
|
||||
(insert (concat "(" (lean-synth-body-str synth) ")")))))))
|
||||
(insert synth-str)))))))
|
||||
|
||||
(defun lean-eldoc-documentation-function ()
|
||||
"Show information of lean expression at point if any"
|
||||
|
|
Loading…
Reference in a new issue