Klimi's new dotfiles with stow.
Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

31 linhas
1.1 KiB

4 anos atrás
  1. (require 'slime)
  2. (require 'slime-cl-indent)
  3. (require 'cl-lib)
  4. (define-slime-contrib slime-indentation
  5. "Contrib interfacing `slime-cl-indent' and SLIME."
  6. (:swank-dependencies swank-indentation)
  7. (:on-load
  8. (setq common-lisp-current-package-function 'slime-current-package)))
  9. (defun slime-update-system-indentation (symbol indent packages)
  10. (let ((list (gethash symbol common-lisp-system-indentation))
  11. (ok nil))
  12. (if (not list)
  13. (puthash symbol (list (cons indent packages))
  14. common-lisp-system-indentation)
  15. (dolist (spec list)
  16. (cond ((equal (car spec) indent)
  17. (dolist (p packages)
  18. (unless (member p (cdr spec))
  19. (push p (cdr spec))))
  20. (setf ok t))
  21. (t
  22. (setf (cdr spec)
  23. (cl-set-difference (cdr spec) packages :test 'equal)))))
  24. (unless ok
  25. (puthash symbol (cons (cons indent packages)
  26. list)
  27. common-lisp-system-indentation)))))
  28. (provide 'slime-indentation)