[slime-devel] Re: slime-complete-form broken
Matthias Koeppe
mkoeppe+slime at mail.math.uni-magdeburg.de
Thu Jan 10 13:34:56 UTC 2008
"Tobias C. Rittweiler" <tcr at freebits.de> writes:
> Matthias Koeppe <mkoeppe+slime at mail.math.uni-magdeburg.de> writes:
>> I noticed that slime-complete-form is broken in SLIME CVS.
> The bogus behaviour should be fixed in CVS.
Now this:
--------------------
(defun <C-c C-s>
(defun foo ()
1)
--------------------
causes this error:
Debugger entered--Lisp error: (cl-assertion-failed (<= (point) user-point))
signal(cl-assertion-failed ((<= (point) user-point)))
(or (<= (point) user-point) (signal (quote cl-assertion-failed) (list ...)))
(progn (or (<= ... user-point) (signal ... ...)) nil)
(assert (<= (point) user-point))
(let ((full-sexps ...)) (forward-sexp arg-index) (slime-forward-blanks) (assert (<= ... user-point)) (let (...) (if ... full-sexps ...)))
(save-excursion (goto-char op-start) (let (...) (forward-sexp arg-index) (slime-forward-blanks) (assert ...) (let ... ...)))
(let ((user-point ...)) (save-excursion (goto-char op-start) (let ... ... ... ... ...)))
(cond ((eql op-100273 ...) (destructuring-bind ... rand-100274 op)) ((eql op-100273 ...) (destructuring-bind ... rand-100274 op)) (t (let ... ...)))
(case op-100273 (:declaration (destructuring-bind ... rand-100274 op)) (:type-specifier (destructuring-bind ... rand-100274 op)) (t (let ... ...)))
(let* ((tmp-100275 ...) (op-100273 ...) (rand-100274 ...)) (case op-100273 (:declaration ...) (:type-specifier ...) (t ...)))
(destructure-case (slime-ensure-list op) ((:declaration declspec) op) ((:type-specifier typespec) op) (t (let ... ...)))
(let ((op ...) (op-start ...) (arg-index ...)) (destructure-case (slime-ensure-list op) (... op) (... op) (t ...)))
(if (null operators) "" (let (... ... ...) (destructure-case ... ... ... ...)))
(let* ((G100271 ...) (operators ...) (arg-indices ...) (points ...)) (if (null operators) "" (let ... ...)))
(multiple-value-bind (operators arg-indices points) (slime-enclosing-form-specs) (if (null operators) "" (let ... ...)))
slime-incomplete-form-at-point()
(let ((form-string ...)) (let (...) (if ... ... ...)))
slime-complete-form()
* call-interactively(slime-complete-form)
> I'd be interested in seeing a backtrace nontheless, though.
Using this (note: one space fewer):
--------------------
(defun<C-c C-s>
(defun foo ()
1)
--------------------
I get the error that I mentioned:
Debugger entered--Lisp error: (wrong-type-argument stringp nil)
substring-no-properties(nil)
(let* ((deleted-region ...) (deleted-text ...) (prior-parens-count ...)) (when slime-close-parens-limit (let ... ...)))
(progn (goto-char point) (dotimes (i sexp-level) (insert ")")) (setq point (point)) (skip-chars-forward " \n)") (skip-chars-backward " \n") (let* (... ... ...) (when slime-close-parens-limit ...)))
(if (> sexp-level 0) (progn (goto-char point) (dotimes ... ...) (setq point ...) (skip-chars-forward " \n)") (skip-chars-backward " \n") (let* ... ...)))
(when (> sexp-level 0) (goto-char point) (dotimes (i sexp-level) (insert ")")) (setq point (point)) (skip-chars-forward " \n)") (skip-chars-backward " \n") (let* (... ... ...) (when slime-close-parens-limit ...)))
(let ((sexp-level 0) point) (save-excursion (save-restriction ... ... ... ... ...)) (when (> sexp-level 0) (goto-char point) (dotimes ... ...) (setq point ...) (skip-chars-forward " \n)") (skip-chars-backward " \n") (let* ... ...)))
slime-close-all-parens-in-sexp()
(let ((slime-close-parens-limit 1)) (slime-close-all-parens-in-sexp))
(save-excursion (insert (substring result 0 -1)) (let (...) (slime-close-all-parens-in-sexp)))
(progn (just-one-space) (save-excursion (insert ...) (let ... ...)) (save-excursion (backward-up-list 1) (indent-sexp)))
(if (eq result :not-available) (error "Could not generate completion for the form `%s'" form-string) (progn (just-one-space) (save-excursion ... ...) (save-excursion ... ...)))
(let ((result ...)) (if (eq result :not-available) (error "Could not generate completion for the form `%s'" form-string) (progn ... ... ...)))
(let ((form-string ...)) (let (...) (if ... ... ...)))
slime-complete-form()
* call-interactively(slime-complete-form)
(This one is on a strange old unreleased version of Emacs, though, 21.3.50)
Thanks,
Matthias
--
Matthias Köppe -- http://www.math.uni-magdeburg.de/~mkoeppe
More information about the slime-devel
mailing list