Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Clojure eval right?
(let [eval-right? clojure.core/eval] (intern 'clojure.core 'eval (fn [form] (if (= 'right? (last form)) (eval-right? (butlast form)) 'right?))))
@Hendekagon

This comment has been minimized.

Copy link
Owner Author

Hendekagon commented Jul 22, 2019

(let [eval-right? clojure.core/eval] (intern 'clojure.core 'eval (fn [form] (if (= 'right? (last form)) (eval-right? (butlast form)) 'right?))))

from now on you must end expressions with "right?" to evaluate them:

(+ 1 2)
=> right?
(+ 1 2 right?)
=> 3

This is in order to conform to the way all speakers in tech end their statements in 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.