We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a1c3dea commit 5552a0fCopy full SHA for 5552a0f
src/lt/plugins/typedclojure.cljs
@@ -210,9 +210,12 @@
210
(let [e (pool/last-active)
211
c (ed/->cursor e)
212
token (if (ed/selection? e)
213
- (ed/selection e)
214
- (:string (ed/->token e c)))]
215
- (object/raise e
216
- :eval.custom
217
- (check-form token)
218
- {:result-type :inline :verbatim true})))})
+ {:string (ed/selection e) :selection true}
+ (->token* e c))]
+ (cond
+ (or (:boundary token)
+ (:whitespace token)) (let [[start end] (par/form-boundary e (:at token) nil)
+ form (ed/range e start (ed/adjust-loc end 1))]
219
+ (raise* e (check-form form) :res :inline))
220
+ (:orphan token) (notifos/set-msg! "core.typed can only check vars or forms")
221
+ :else (raise* e (check-form (:string token)) :res :inline))))})
0 commit comments