Fork me on GitHub
Karol Wójcik09:09:36

@bozhidar 1. I've connected to repsl via cider-jack-in-clj&cljs (I'm using shadow-cljs) 2. When I try to evaluate the form: #?(:cljs (println "Hello")) the expression is send to clj repl instead of cljs. The question is how can I send some expressions to clj repl and some expressions to cljs repl?


So, you’re in a cljc buffer, right?

Lucas Barbosa12:09:47

Guys, is there a way to debug functions defined with custom defns? I'm trying to debug a function declared through prismatic/schema's defn with no success

Karol Wójcik10:09:48

@bozhidar so there is no option to send value to cljs instead of regular clj repl?


At some point I recall we were sending forms to both REPLs when working with cljc, but I’m not quite certain what’s the current state. You can open some ticket and I’ll check this when I can.


@lvbarbosa Just an idea… If CIDER doesn’t support it… if that’s a macro that’s expanding to a defn (I don’t know whether it is), you could use the macroexpansion in place of your definition.

Lucas Barbosa13:09:06

Oh I thought it would show a text snippet. Well, that's the macroexpansion-1 of a function. I think I now understand why the debugger does not work on this


Maybe you could replace the things in that first let with defs, and then do the defn at the top level (just for debugging purposes). And there’s also that thing after the defn so you’d need that too.

thanks2 4
Lucas Barbosa19:09:05

Sir, apparently there is a way to do it.

Lucas Barbosa19:09:05

When I try to instrument the function, it triggers the debugger. I was hitting C to continue at that moment. Subsequent calls to the instrumented function would not trigger the debugger

Lucas Barbosa19:09:35

Instead of continue, if you hit n (`next`), the function is successfully instrumented. Subsequent calls do trigger the debugger


Ah, I think I recall that as a bug in an earlier version of CIDER. Are you on the latest version?

Lucas Barbosa23:09:24

I'm using the latest version that is on MELPA: 20190911.1917


Do you get the same behaviour when you debug a defn form?


how can I configure emacs/clojure-mode/cider in such a way that it doesn't indent lines starting with a single semi-colon to the middle of the page?


☝️oooh i wanna know this too


I wonder if it's related to classic Emacs Lisp convention at all?


... perhaps the triple-wink will stay aligned to the left?


I have a hook that does (set (make-local-variable 'comment-column) 0) — I think that’s why I don’t have single-semicolon comments jumping.

✔️ 8

Yes — I commented that out of my Emacs config and now my single-semicolon comments jump to the middle of the page.