Skip to content

Commit eb32cc8

Browse files
author
Antoine Brand
committed
* Now it byte compile
1 parent 945cad3 commit eb32cc8

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

racket-mode.el

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -138,13 +138,14 @@ http://www.gnu.org/licenses/ for details.")
138138
(set (make-local-variable 'imenu-syntax-alist)
139139
'(("+-*/.<>=?!$%_&~^:" . "w"))))
140140

141-
(when (fboundp 'helm)
142-
(require 'helm)
143141

144-
(defun racket-helm-apropos-init ()
145-
(with-current-buffer (helm-candidate-buffer 'global)
146-
(dolist (elem (racket--eval/sexpr ",apropos"))
147-
(insert (car elem) "\n"))))
142+
(when (require 'helm nil 't)
143+
144+
(when (fboundp 'helm-candidate-buffer)
145+
(defun racket-helm-apropos-init ()
146+
(with-current-buffer (helm-candidate-buffer 'global)
147+
(dolist (elem (racket--eval/sexpr ",apropos"))
148+
(insert (car elem) "\n")))))
148149

149150
(defun racket-helm-apropos-match-part (candidate)
150151
candidate)
@@ -160,10 +161,11 @@ http://www.gnu.org/licenses/ for details.")
160161
(match-part . racket-helm-apropos-match-part)
161162
(action . racket-helm-apropos-action)))
162163

163-
(defun racket-helm-apropos ()
164-
"Equivalent of helm-apropos but for the racket installed documentation"
165-
(interactive)
166-
(helm :sources 'helm-source-racket-apropos :buffer "*helm racket apropos*")))
164+
(when (fboundp 'helm)
165+
(defun racket-helm-apropos ()
166+
"Equivalent of helm-apropos but for the racket installed documentation"
167+
(interactive)
168+
(helm :sources 'helm-source-racket-apropos :buffer "*helm racket apropos*"))))
167169

168170
;;;###autoload
169171
(define-derived-mode racket-mode prog-mode

0 commit comments

Comments
 (0)