Skip to content

Commit

Permalink
* Now it byte compile
Browse files Browse the repository at this point in the history
  • Loading branch information
Antoine Brand committed Oct 1, 2014
1 parent 945cad3 commit eb32cc8
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions racket-mode.el
Original file line number Diff line number Diff line change
Expand Up @@ -138,13 +138,14 @@ http://www.gnu.org/licenses/ for details.")
(set (make-local-variable 'imenu-syntax-alist)
'(("+-*/.<>=?!$%_&~^:" . "w"))))

(when (fboundp 'helm)
(require 'helm)

(defun racket-helm-apropos-init ()
(with-current-buffer (helm-candidate-buffer 'global)
(dolist (elem (racket--eval/sexpr ",apropos"))
(insert (car elem) "\n"))))
(when (require 'helm nil 't)

(when (fboundp 'helm-candidate-buffer)
(defun racket-helm-apropos-init ()
(with-current-buffer (helm-candidate-buffer 'global)
(dolist (elem (racket--eval/sexpr ",apropos"))
(insert (car elem) "\n")))))

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

(defun racket-helm-apropos ()
"Equivalent of helm-apropos but for the racket installed documentation"
(interactive)
(helm :sources 'helm-source-racket-apropos :buffer "*helm racket apropos*")))
(when (fboundp 'helm)
(defun racket-helm-apropos ()
"Equivalent of helm-apropos but for the racket installed documentation"
(interactive)
(helm :sources 'helm-source-racket-apropos :buffer "*helm racket apropos*"))))

;;;###autoload
(define-derived-mode racket-mode prog-mode
Expand Down

0 comments on commit eb32cc8

Please sign in to comment.