Calva's paredit seems to be a bit too fussy about deleting #
characters before parens - the only way I can do it is by highlighting the #
and pressing backspace:
#(fn [] oops) ;; <- try to delete the #
#{1 2 3} ;; same here
@qythium, it’s because Calva sees it as an opening #(
bracket, starting a literal lambda. I’ve noticed this myself when having an ignore marker (`#) before the function and trying to delete it. First it deletes the
then it thinks it is a
#(` bracket. Please file an issue about it, I should be able to figure something out. As a workaround, use alt+backspace
to delete any character without Calva Paredit getting in the way.
Ah okay, that's a useful command :thumbsup:
Can I just say how awesome the "infer parens from indentation" command is 🙂 It's like Parinfer on-demand without the constant worrying that it'll screw something up, and it really deserves a better default keybinding
I bound it to Shift-Tab for a nice symmetry with the auto-indentation command:
Tab
reformats your code according to the structure <-> Shift-Tab
restructures the code according to the formatting.
Un-indenting can be still be done with the default cmd-[
binding.
Oh, I like that binding!
It does interfere sometimes with the autocompletion popup, but so does Tab
It does? tab
shouldn’t interfere there. Issue please! 😃
Maybe interfere isn't the right word, I mean how when you have
(wrongly (indented
f)) ;; <- cursor after f
and try to press tab
to reindent, but at the last millisecond vscode decides to show the popup and it ends up triggering the completion, turning f
into false
.You might be able to tweak how quick vs code should be popping up the completions.
It's not really an issue per se, maybe related to editor philosophies - I'm used to Emacs where keybinding contexts are mostly deterministic 😛
I just released Calva https://github.com/BetterThanTomorrow/calva/releases/tag/v2.0.188, fixing the Getting Started, and Standalone REPLs for some Windows users. It took me and @borkdude more than two weeks to get it reproducable (I even bought a PC for this) and then to track it down and then, Borkdude being Borkdude, he fixed it of course. https://github.com/borkdude/deps.clj is an amazing tool. On Windows it is a safer bet than the official clojure
CLI tools, I would say. Thanks also to @luanprinsmain for reporting and for sticking to it testing stuff for us while he had the only machine where the error could be reproduced. Happy Friday! :calva: