Hacker News new | ask | show | jobs
by seancorfield 1224 days ago
I've been programming with Clojure since 2010 and using it in production almost as long and I hardly ever care about the internal types so I'm really curious as to how you went down that "rabbit hole"? What sort of problems were you solving that necessitated delving into the implementation details behind the abstractions?

I've only needed to dig into that occasionally for a handful of specific situations (for example, in next.jdbc, where I create a hash map like abstraction over the (mutable) ResultSet object from Java -- to paper over some nasty interop issues).

1 comments

What is the idea behind immutable variant of a ResultSet? Since it maintains a database cursor, does it make sense to have it immutable?

> A ResultSet object maintains a cursor pointing to its current row of data. Initially the cursor is positioned before the first row [0]

0 - https://docs.oracle.com/javase/7/docs/api/java/sql/ResultSet...

If you're a Clojure developer and you're using the next.jdbc library you don't need to ask that question :)
Obviously, I'm not :)