Fork me on GitHub

Good Morning!


Nice article on Rich Comment Blocks


I use them too, they are certainly great - esp as I can eval forms inside of them, in the repl, to try out stuff πŸ™‚


in the #news-and-articles channel.


Yeah, I was pleased to see someone had written that up.


my RCB's contain next.jdbc invocations pumping in some data and looking at the results πŸ™‚


or invoking APIs and looking at the results that come back πŸ™‚


My RCB's contain all sorts of stuff. I just committed a big data migration that was written and tested entirely via RDD using RCB's. And I left the whole thing in when the PR went up for review so my colleague could see how I'd evolved the solution and how I'd "tested" it in the REPL.


I used Spec to generate random test data to populate 10,000 rows in each of three tables to act as a test bed for the migration. All in the RCB.


You know what - that's what I do too. I test out stuff in my repl inside rcbs, backed by a few unit tests, and I'm happy to believe that it'll work. I love the rapid feedback.


Can't say I produce 10,000 random test data rows 'tho - not yet anyway πŸ™‚


(s/exercise ::some-spec 10000) πŸ™‚


Spec is soooo useful for extended example testing!


I'll have to do more, that's for sure!


I don't think that's a helpful way to put it, but I agree with the point - my first programming course at university was functional programming in haskell

Jakob Durstberger08:07:49

What surprised me about clojure when I started looking into it was how few language constructs there are. Some basic data types + standard lib and then bit later atoms/refs + async + protocols . It is funny now looking at Kotlin and other languages and see how many keywords and concepts there are to learn.


I would guess most people learning Kotlin will already have paid a lot of the cost of learning it by becoming familiar with Java

Jakob Durstberger08:07:23

Yeah, I have been using Java for a few years but am now predominantly using Kotlin at work that’s why I used it as an example. I feel the same about C#, Haskell, Typescript and other.


There does seem to be some pain with learning Kotlin - as clunky as it is, I think I'm pretty good at functional-style programming with Java streams (after some horrible first attempts), and then the Kotlin equivalent requires learning a whole new set of functions


Which bits did you find trickiest?


Nothing in particular, just a lack of familiarity with what's available, and the best way of doing things