Skip to content

Commit

Permalink
Indicate both special form and macro in doc
Browse files Browse the repository at this point in the history
Some symbols, like `clojure.core/let`, are both special forms AND
macros. `cider-doc` should indicate this.
  • Loading branch information
xiongtx committed Jul 1, 2017
1 parent be019aa commit e648455
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@

### New Features

* [#2012](https://github.com/clojure-emacs/cider/pull/2007): Support special forms in `cider-apropos` and `cider-grimoire-lookup`.
* [#2015](https://github.com/clojure-emacs/cider/pull/2015): Show symbols as special forms *and* macros in `cider-doc`
* [#2012](https://github.com/clojure-emacs/cider/pull/2012): Support special forms in `cider-apropos` and `cider-grimoire-lookup`.
* [#2007](https://github.com/clojure-emacs/cider/pull/2007): Fontify code blocks from `cider-grimoire` if possible.
* [#1990](https://github.com/clojure-emacs/cider/issues/1990): Add new customation variable `cider-save-files-on-cider-refresh` to allow auto-saving buffers when `cider-refresh` is called.
* Add new function `cider-load-all-files`, along with menu bar update.
Expand Down
6 changes: 4 additions & 2 deletions cider-doc.el
Original file line number Diff line number Diff line change
Expand Up @@ -432,8 +432,10 @@ Tables are marked to be ignored by line wrap."
(dolist (form forms)
(insert " ")
(emit (cider-font-lock-as-clojure form))))
(when (or special macro)
(emit (if special "Special Form" "Macro") 'font-lock-variable-name-face))
(when special
(emit "Special Form" 'font-lock-keyword-face))
(when macro
(emit "Macro" 'font-lock-variable-name-face))
(when added
(emit (concat "Added in " added) 'font-lock-comment-face))
(when depr
Expand Down

0 comments on commit e648455

Please # to comment.