editors

Discussion about all editors used for Clojure/ClojureScript
bozhidar 2018-05-25T06:18:23.000262Z

Yeah, without middleware it works, but it has just some basic eval functionality.

bozhidar 2018-05-25T06:19:43.000132Z

A bit more things can be implemented to work without middleware, if needed (in the early days CIDER was just evaluating hardcoded clojure forms that did some of the ops that were transferred to middleware). That was limiting in many ways, but it gets the basic things done.

bozhidar 2018-05-25T06:20:34.000279Z

I agree that self-hosted nREPL server would be something ideal, and this was a big part of the reason I volunteered to work on the nREPl transition out of clojure-contrib. Now it’s perfectly possible for someone to make this happen.

bozhidar 2018-05-25T06:22:02.000253Z

And, of course, if people are willing to just add orchard to their projects, the fallback mode would be much simpler than it was before.

dominicm 2018-05-25T06:55:31.000249Z

This one is not well suited to decoding streams, like from the network.

dominicm 2018-05-25T06:55:55.000285Z

There's only one I've found that does that, and it can't handle negative numbers.

futuro 2018-05-25T16:35:59.000635Z

It can’t handle negative numbers? That’s really curious.

richiardiandrea 2018-05-25T16:43:11.000568Z

does the nrepl protocol use negative numbers? seems like a pretty big defect for such a popular lib

futuro 2018-05-25T16:45:10.000720Z

@dominicm what stream decoding bencode library was this?

futuro 2018-05-25T16:46:47.000274Z

@richiardiandrea bencode is used to serialize all nREPL output/input, so that could include negative numbers from user input, like (* 20 -1)

dominicm 2018-05-25T16:47:19.000231Z

https://github.com/cPu1/streaming-bencoder

dominicm 2018-05-25T16:48:13.000647Z

There's commonly quite a few subtle bugs where Unicode isn't supported properly and other such things.

futuro 2018-05-25T16:50:26.000699Z

Is that a problem with bencode as a standard, or just implementations?

richiardiandrea 2018-05-25T16:53:16.000163Z

from the bittorrent spec: > Integers are represented by an 'i' followed by the number in base 10 followed by an 'e'. For example i3e corresponds to 3 and i-3e corresponds to -3. Integers have no size limitation. i-0e is invalid. All encodings with a leading zero, such as i03e, are invalid, other than i0e, which of course corresponds to 0.

richiardiandrea 2018-05-25T16:53:31.000418Z

so in the case of negative numbers it is an impl problem

richiardiandrea 2018-05-25T16:56:06.000244Z

http://www.bittorrent.org/beps/bep_0003.html

futuro 2018-05-25T16:57:26.000523Z

Ahh, fantastic; thanks for digging that up 😄

futuro 2018-05-25T17:22:59.000396Z

I wonder what it'd take for a pure cljs bencode library. All of the clojure libraries I've looked at are tied pretty tightly to the jvm, but multi-methods are a common pattern.