is it possible to refer to the doc string on the RHS?
That seems odd. Maybe with a defrule style macro you could refer to its own self var and find the doc string on there somehow.
Would have to test that theory out though. Canβt at the moment.
Since clara allows arbitrary clojure in the rhs, most things are possible. It just seems a bit weird to do them:
(defrule a-rule
"hello"
[A (> x 3)]
=>
(println (:doc (meta #'a-rule))))
(-> (mk-session)
(insert (->A 4))
fire-rules)
hello
sweet.
well, i dunno like you say a bit weird, but at least possible.
@ethanc --- commented on ticket #428 - curious if retract rules from :rule-matches reasonably possible.