mirror of
https://github.com/vale981/emacs-jupyter
synced 2025-03-05 23:41:38 -05:00
Fix macro hygiene issues
This commit is contained in:
parent
4c3168d53f
commit
f5d852dc6d
2 changed files with 9 additions and 7 deletions
|
@ -175,7 +175,7 @@ returned."
|
||||||
(declare (indent 3) (debug (symbolp symbolp form body)))
|
(declare (indent 3) (debug (symbolp symbolp form body)))
|
||||||
`(let ((,beg (point-marker))
|
`(let ((,beg (point-marker))
|
||||||
(,end (point-marker)))
|
(,end (point-marker)))
|
||||||
(set-marker-insertion-type end t)
|
(set-marker-insertion-type ,end t)
|
||||||
(unwind-protect
|
(unwind-protect
|
||||||
(prog1 ,bodyform ,@afterforms)
|
(prog1 ,bodyform ,@afterforms)
|
||||||
(set-marker ,beg nil)
|
(set-marker ,beg nil)
|
||||||
|
|
|
@ -92,12 +92,14 @@ find the display in the REPL buffer. See
|
||||||
"Handle control codes in any produced output generated by evaluating BODY.
|
"Handle control codes in any produced output generated by evaluating BODY.
|
||||||
After BODY is evaluated, call `jupyter-handle-control-codes'
|
After BODY is evaluated, call `jupyter-handle-control-codes'
|
||||||
on the region inserted by BODY."
|
on the region inserted by BODY."
|
||||||
`(jupyter-with-insertion-bounds
|
(let ((beg (make-symbol "beg"))
|
||||||
beg end (progn ,@body)
|
(end (make-symbol "end")))
|
||||||
;; Handle continuation from previous messages
|
`(jupyter-with-insertion-bounds
|
||||||
(when (eq (char-before beg) ?\r)
|
,beg ,end (progn ,@body)
|
||||||
(move-marker beg (1- beg)))
|
;; Handle continuation from previous messages
|
||||||
(jupyter-handle-control-codes beg end)))
|
(when (eq (char-before ,beg) ?\r)
|
||||||
|
(move-marker ,beg (1- ,beg)))
|
||||||
|
(jupyter-handle-control-codes ,beg ,end))))
|
||||||
|
|
||||||
;;; Fontificiation routines
|
;;; Fontificiation routines
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue