Fork me on GitHub
#clojure
<
2018-05-15
>
sparkofreason00:05:48

Best guess at this point is that one project had some test dependencies different than the other, and one of those deps was pulling in an alpha version of 1.9. I think the ns spec might have gotten overwritten.

seancorfield00:05:07

@dave.dixon If 1.9 was complaining about a ns form in a library, then that library has a syntax error -- that just wasn't detected before 1.9 🙂 Quite a few libraries had syntax errors that were uncovered by 1.9 and needed to be updated...

sparkofreason00:05:11

Yes, it definitely had an error, empty () in the :import.

James Vickers02:05:55

Is there a way to mark a var as final in the same way you can mark a Java variable as final, to prevent it from being re-bound to another value?

seancorfield02:05:17

@jamesvickers19515 a Var can always be redefined (in several ways)...

James Vickers02:05:13

I was just randomly wondering because final is one technique for immutability in Java, wondered if Clojure has an equivalent

seancorfield02:05:42

@jamesvickers19515 data in Clojure is immutable -- that's a more powerful promise than Java's final.

seancorfield02:05:58

@jamesvickers19515 Consider

final ArrayList<Long> l = new ArrayList<Long>();
                l.add( new Long( 42 ) );
                // l = new ArrayList<Long>();
Here l is final but still mutable -- you can change the ArrayList it refers to -- you just can't make l point at a different ArrayList

gklijs03:05:58

One of the most deathful things about Java, you could use a final immutable list and that is almost like clojure, but it's very easy to make mistakes.

seancorfield03:05:18

One of... a long list of such nasty things 🙂

benzap04:05:13

I think the biggest strength with regards to clojures immutability is the implementation of the immutable collections, which negates a lot of the fuss in regards to the shortfalls of what most people think immutability means. Most people don't realize that you aren't necessarily copying a collection within memory to create an updated immutable collection from a previous immutable collection.

benzap04:05:51

or namely fully persistent immutable collections

benzap04:05:15

Actually i'm curious on whether clojure's collections are fully persistent, or only partially

phronmophobic04:05:48

i’ve always assumed they were fully persistent. what would it mean for them to be partially persistent?

benzap04:05:34

I was just reading the wiki, and it suggests that you can't modify previous versions

benzap04:05:44

So I guess it makes sense that it would be fully persistent

phronmophobic04:05:19

the jvm’s garbage collector also helps make clojure’s immutable datastructures cool. not sure what the memory management would be like for immutable datastructures in something like c++

seancorfield04:05:41

@smith.adriane You'd have to rely heavily on counted/auto pointer stuff I suspect 👀

👀 4
the2bears04:05:55

I still don't get what partially persistent would look like 🙂

benzap04:05:47

oh nvm, that's off

benzap04:05:00

from the wiki "partially persistent if all versions can be accessed but only the newest version can be modified"

👍 4
benzap04:05:18

so x and y could be accessed... so i'm not really sure what an example would be :S

benzap05:05:03

So I was wondering. How does the new prepl compare to tools.nrepl?

seancorfield05:05:14

@benzap They're fundamentally different on a number of levels.

seancorfield05:05:29

@benzap Is there some specific sort of comparison you're thinking of?

benzap05:05:31

I'm trying to study their codebases, so I can work out an implementation strategy for something similar

benzap05:05:05

prepl looks like it's using stuff that isn't available till clojure 1.10 (tap>, add-tap, remove-tap)

seancorfield05:05:14

prepl is a simple, data-oriented streaming REPL. You can use it directly or programmatically.

seancorfield05:05:41

nREPL is a complete protocol that must be supported by the client (and is not a streaming system).

benzap05:05:13

Interesting, from what I can tell, prepl is looking to replace nrepl in the future?

benzap05:05:46

or rather, you could program prepl to support the nrepl protocol

seancorfield05:05:55

Why does everyone seem to think that whatever Clojure/core produce is aimed at replacing some community project?

benzap05:05:06

haha, I don't know

seancorfield05:05:48

Could you build an adapter between an nREPL client and a prepl server? No idea. Not sure why you'd want to... could you explain?

seancorfield05:05:20

Have you looked at unrepl/unravel @benzap?

benzap05:05:15

From a design standpoint, i'm trying to figure out how each one works. Trying to get some insight into implementing something similar for a scripting language I wrote in clojure

seancorfield05:05:36

I would say: simpler is better.

seancorfield05:05:46

nREPL is pretty heavyweight.

benzap05:05:13

I'm not that familiar with socket repls whatsoever, so i'm trying to get more insights into whether I could maybe program prepl to do what I want

seancorfield05:05:51

The nice thing about unrepl/unravel is that you can take a plain old Socket REPL and bootstrap it so you can use code completion, documentation insight, and so on. You don't need a heavy layer of protocols and libraries to make that happen.

benzap05:05:11

ah interesting

benzap05:05:11

yeah, i'll have to take from prepl then. Simpler is definitely better

seancorfield05:05:42

At work, we regularly start a process with a Socket REPL (via the Java property), then we connect via unravel, specifying compliment as a dependency to enable completion/insight, then we have a fairly full-featured local REPL connected via an SSH tunnel to our server process. Works great. We don't need nREPL loaded into the server process, nor a fat client.

benzap05:05:22

I'd just rather not reinvent the wheel. So what i've gathered, nrepl is pretty heavyweight, and unravel is similar and offers a similar feature while being simpler?

benzap05:05:32

feature-set*

seancorfield05:05:47

Define "similar features".

seancorfield05:05:05

It depends what you need. I think nREPL is way over-complicated for most situations.

benzap05:05:20

auto-completion support doesn't seem like an easy task for a simple socket repl

benzap05:05:42

but i'm guessing unrepl's implementation has decomplected this concept somehow?

seancorfield05:05:19

We used to have an automated test that used an nREPL connection to modify a running process to mock something so the test could verify an API behavior. We dropped down to a simple Socket REPL and it hugely simplified our test code.

seancorfield05:05:45

Compliment is an auto-complete library (at a high-level).

seancorfield06:05:36

The standard REPL is designed to support all sorts of lightweight client-side extensions. Look at Bruce Hauman's Rebel Readline stuff.

benzap06:05:01

oh yeah, i've been meaning to look at that

benzap06:05:38

i'm not really sure what i'm after here

benzap06:05:46

is the standard repl implemented as a socket repl?

seancorfield06:05:05

Socket REPL is a standard bare REPL running over a socket.

seancorfield06:05:25

i.e., what clojure.main can start up.

benzap06:05:24

alright, so this is nothing like lein repl, which uses its own repl protocol called nrepl?

seancorfield06:05:27

prepl takes away the prompt and produces standardized data responses instead of a mix of text, data, and exceptions.

seancorfield06:05:42

lein repl (and boot repl) is based on nREPL.

benzap06:05:51

ah ok, this is starting to make sense

seancorfield06:05:52

It requires nREPL on both the client and the server.

seancorfield06:05:24

lein repl starts an nREPL server (on port 65432 or whatever) then starts an nREPL client and connects to that port.

benzap06:05:35

so nrepl was a community-made protocol, and prepl is something that is going to be part of clojure as a more extensive standard repl that is data-oriented

seancorfield06:05:59

Yeah, basically.

benzap06:05:17

ok great. It's all making more sense

seancorfield06:05:21

Per Clojure 1.10, you'll be able to guarantee prepl with no additional dependencies.

seancorfield06:05:36

just like you can assume Socket REPL per Clojure 1.8

benzap06:05:52

are you familiar with the add-tap, remove-tap tap>?

benzap06:05:31

I'm not really sure what it does, my guess is there will be an article in the future explaining what they are for exactly

seancorfield06:05:44

It's a nice way to add debugging into the REPL.

benzap06:05:07

so it's going to be something strictly used with prepl?

seancorfield06:05:19

prepl exposes the data sent to the tap so it's easy to access programmatically.

seancorfield06:05:05

a process can send data out to all connected taps (whether there's no taps active or a dozen)

seancorfield06:05:29

It's a nice extension point for debugging.

benzap06:05:37

ah, so it's similar to core.async taps with mult?

seancorfield06:05:57

I'm not familiar enough with core.async to say.

benzap06:05:18

sort of like a subscription? So add-tap would be like i'm subscribing to the prepl

seancorfield06:05:45

Yeah, sort of.

benzap06:05:36

I think that makes sense. Instead of pulling in core.async as a dependency, they implemented a small subset for that purpose

seancorfield06:05:34

I think my advice in general would be "don't over-think it". Clojure/core / Cognitect are very focused on "simple" and "composable".

benzap06:05:53

the KISS principle 😉

benzap06:05:04

Keep It Simple Stupid!

benzap06:05:52

I need to hit the sack, thanks for the feedback @seancorfield

tianshu06:05:22

I'm using carmine library for redis. it's likely there's no way to shutdown(or close) the connection pool(I use lsof -i:6379 on redis server and can't find way make the connection disconnected). also don't know how can i customize the redis connection pool size.

tianshu06:05:56

I wonder if it's very different from those connection pool in mysql.

shakdwipeea08:05:56

I am getting a dependency mismatch with s3. In my project I have specified dependency on com.amazonaws/aws-java-sdk-s3 {:mvn/version "1.11.261"}. Also, I have a library whose transitive dependency include a different version of sdk . I have specified a exclusion for s3 as:

libB {:mvn/version "2.0.0-SNAPSHOT"
        :exclusions [com.amazonaws/aws-java-sdk-s3]}
Now, when I do clj -Stree. I can see that only the correct version is being included. But when I tried to find the location of sdk being included using System.out.println(SDKGlobalConfiguration.class.getProtectionDomain().getCodeSource().getLocation()); as per https://github.com/aws/aws-sdk-java/issues/1071 I see that it is referring to the location of the jar of the transitive dependency which is the older version of aws sdk. FWIW I am using the clj tool and deps.edn and the conflicting libraries are java based.

xtreak2908:05:30

Wild guess : Try resolve-dep to see if the correct version is resolved (Little confused since -Stree gives correct version). There seems to be an option :override-deps that is worth a try.

shakdwipeea08:05:41

I tried :override-deps using an alias: sth like :aliases {:dev {:override-deps {com.amazonaws/aws-java-sdk-s3 {:mvn/version "1.11.261"}}}} but I see the same behaviour.

shakdwipeea08:05:20

hmm according the issue it should support exclusion of the transitive dependency on the maven project level. In my case the conflicting library is a transitive dependency of a dependency, could that be an issue ?

shakdwipeea09:05:09

This seems to be a clj specific bug, the same chain of deps work in boot.

Alex Miller (Clojure team)12:05:49

This doesn’t make sense to me - could you file a TDEPS bug with the deps.edn to repro so I can take a look? If you’re seeing the right thing with -Stree, you should see the same thing at runtime

shakdwipeea14:05:27

I was able to find some more details. This happens when the dependent library has maven shade plugin enabled. Is this expected ?

Alex Miller (Clojure team)15:05:08

maven shade has some known bugs around timestamping that can cause issues

Alex Miller (Clojure team)15:05:36

that is, not preserving file timestamps during shading (Clojure load logic for .clj vs .class uses timestamps)

konrad09:05:16

Hi, Im trying to figure out a way to prevent calling/referencing certain functions of an external clojure library in our project for security reasons. One way that Ive come up with would be to have a test that searches for those symbols and makes sure that the ns list comes out empty. Unfortunately I haven't figured out how to code that test up. I know that cursive and emacs does support that. The closest Ive come is the https://github.com/clojure-emacs/refactor-nrepl#find-symbol function, but I didn't get it to work with the external library as the file path is either on the classpath or inside a jar in the local maven cache. Any help and other solutions are very welcome. Thanks in advance.

mattford10:05:25

Hey. Anyone here use Amazonica with AWS ECS/Fargate?

mattford10:05:42

I can't get it to pick up IAM roles.....

sobel10:05:43

I'd hoped to use Pallet but it's no longer maintained

jerger_at_dda10:05:10

@matt220 We're working currently on lifting dependencies to clojure 1.9 😉

sobel10:05:29

@jerger_at_dda yes, that is interesting! i had no idea

sobel10:05:55

So, is Travis CI reviving Pallet or is that someone's project at Travis CI? I'm really curious who is behind this work

jerger_at_dda11:05:48

@matt220 We forked pallet at https://github.com/DomainDrivenArchitecture/pallet and will provide pull-request and / or maintain the fork. As we're using pallet heavily (e.g. at https://github.com/DomainDrivenArchitecture/dda-serverspec-crate) we're very interested in keeping pallet in a good shape. Travis is just showing, that we're working on pallet just in this moment.

sobel11:05:35

That's about the best I could have hoped for. Great news!

danm11:05:33

I didn't realise that Travis did stuff with Clojure 🙂 Nice!

mpenet11:05:00

They don't 🙂 (as far as I know)

jerger_at_dda11:05:23

Travis has clojure builders, so you can build clojure projects there. We build all our open source projects in this way 🙂

mpenet11:05:25

I think he meant clojure use at travis, but I could be wrong

danm12:05:54

I did 🙂

ghaskins12:05:29

hi all, im getting myself wrapped around the axle on trying to programmatically intern a bunch of java interop

ghaskins12:05:14

in a nutshell, I think what I want is similar in function to the memfn form, except I need to generate the symbol dynamically

ghaskins12:05:34

what I would like is to intern a bunch of these from a list, like (map intern-my-interop [“Byte” “Bool” “Int32”]), etc

ghaskins12:05:30

which compiles, but doesnt work quite right at runtime

ghaskins12:05:53

ive tried all variants (I could think of) of using dot special form, memfn, etc

mfikes12:05:39

I suspect a macro could pull this off; where the macro emits all of the desired variants

ghaskins12:05:42

but its proving difficult to get any of the interop forms to accept a symbol for eval rather than a literal

ghaskins12:05:34

@mfikes yeah, i tried that too…i was slamming into “cant eval local” problems, more than likely PABCAC

ghaskins12:05:21

@mfikes was trying something like

(defmacro interopfn [member]
  `(memfn ~(eval member)))

(defn- ->sizefn [type]
  (let [name (-> (str "size-" type)
                 symbol)
        sym (-> (str "CodedOutputStream/compute" type "Size")
                symbol)
        f (interopfn sym)]
    (intern *ns* name
            (fn [tag value]
              (if value
                (f tag value)
                0)))))

ghaskins12:05:53

i think I am in macro-on-macro land at this point, which is probably part of my problem

mfikes12:05:16

Can your macro just emit defn forms?

ghaskins12:05:38

you mean rather than using intern?

mfikes12:05:40

(I was thinking of a macro that "wrote" the tedious code for you.)

ghaskins12:05:59

maybe, i tried something like that initially before I discovered intern, and was having problems

ghaskins12:05:08

but it could be a tenable solution if I can figure out that part

mfikes12:05:13

TBH, though, I haven't read what you are doing carefully enough to truly understand

ghaskins12:05:15

thats fair, appreciate the thoughts

cddr13:05:31

Looks like clojure was used to bootstrap sku-vault's apparently successful use foundationdb. https://abdullin.com/sku-vault/2017-01-22-dsl-impression/

parens 4
borkdude14:05:25

How to do type hints inside threading macros?

(def a "foo")
(.length ^String a)
(->> a (.length ^String)) ;; error
As a work-around I used as->:
(-> foo
      parse
      (select “li.previous”)
      first
      (as-> elt (.text ^Element elt)))

sundarj15:05:57

type hints are a reader macro, which means they happen at read time (before macroexpansion) - so there's no way to get ^Element to work with ->>. you'd need to use with-meta or vary-meta

sundarj15:05:37

^Foo is shorthand for ^{:tag Foo}

sundarj15:05:33

so you could do (vary-meta elt assoc :tag Element)

sundarj15:05:21

although maybe type hinting doesn't work at runtime, not sure

ghadi14:05:58

always type-hint the target of the method

ghadi14:05:10

which is a in the first block

borkdude14:05:37

that’s what it’s supposed to do, but I didn’t know how in ->>

ghadi15:05:04

But -- if you want to debug it, first

(set! *print-meta* true)
then macroexpand your forms

borkdude15:05:50

cool, this worked:

(-> foo
      parse
      (select "li.previous")
      ^Element
      first
      (.text))

ghadi15:05:59

that doesn't look right -- you're type hinting first

borkdude15:05:17

@ghadi It doesn’t look right indeed, but it does work for some reason…

borkdude15:05:12

Forget this, I’m writing a function instead of the method call

ghadi15:05:15

yup, they're hints. compiler can ignore them

borkdude15:05:30

@ghadi I mean in the sense that I didn’t get a reflection warning anymore

borkdude15:05:04

I’m going for this one:

(defn text
  "Gets text from Jsoup Element"
  [^Element elt]
  (.text elt))

danielneal15:05:23

🙂 looks clearer

ghadi15:05:06

so much better

konrad16:05:56

any thoughts/ideas on this?

mpenet17:05:53

Clojail is an option. Personally I prefer to use lua for this kind of things. Luaj makes it super easy to use clj datastructures from lua without copying via proxies, it can also be sandboxed and resource limited easily.

mpenet17:05:50

It's super fast too

dominicm16:05:03

@konrad tools.analyzer is what you're looking for.

dominicm16:05:31

fwiw, positano provides a nice api for querying information like this: https://github.com/stathissideris/positano/blob/master/src/positano/analyze.clj#L763-L770

bronsa18:05:02

oh wow this is great

dominicm18:05:48

@U050AACJB said the same thing when I showed him the datomic namespace in tools.analyzer 🙂

stathissideris18:05:58

@dominicm thanks for promoting it, but @U060FKQPN please note that this is super beta and written with a hangover 😄

dominicm18:05:39

The best kind of code 😄

bronsa18:05:00

man this is exactly what I wanted to enable people to do when I wrote that, it makes me so happy to see it works (even if still alpha) :)

simple_smile 4
stathissideris18:05:02

@U060FKQPN I ended up remixing one of your functions to also convert :meta and :env info to EAV

bronsa18:05:40

anything that you think would be useful upstream I'll take patches FWIW

bronsa18:05:20

this could be super useful for Eastwood /cc @U04V5VAUN @andy.fingerhut

stathissideris18:05:54

@U060FKQPN thanks, but it’s a tiny bit of code that belongs in positano anyway I think 🙂

stathissideris18:05:27

and positano needs a major cleanup, it contains endless comments with lots of experiments, it’s just not presentable the way it is

jmacneal16:05:00

I'm looking to do some NLP in Clojure and I'm wondering if anybody with some experience can recommend a particular library. I see postagga, clojure-opennlp and clojure-nlp-parse as 3 semi-popular github repos. Any suggestions?

hiredman16:05:00

that, of course, only finds static uses, if you lookup the var manually you can by pass it

dominicm16:05:24

I'm guessing from the context that this is more about linting rather than actual secure execution at runtime. Otherwise, I'd recommend trying clojail.

konrad16:05:40

wow, thanks @alexmiller @hiredman and @dominicm, you really got me unstack here, thats awesome!

ghadi16:05:30

making a process boundary is another option

noisesmith17:05:43

I wonder what would happen if you explicitly destroyed all the vars in the ns after all your code loads? - then worst case is a runtime failure when trying to call a var, but you know the vars are not called

noisesmith17:05:00

(unless something was inlined...)

hiredman17:05:38

functions are compiled with static fields containing the vars they reference

hiredman17:05:02

so removing the var from the namespace doesn't mean an already compiled function can't use it

Alex Miller (Clojure team)17:05:18

I believe if you use direct linking, those vars are not included statically

hiredman17:05:35

but a similar outcome, removing the vars from the namespace doesn't stop you from accessing the vars value. without direct linking you could nil out all the vars, but with direct linking even doing that wouldn't stop you (but direct linking is only for invoking functions)

tjtolton17:05:48

question about namespaced keywords: in the reframe app template, in the myproject.core namespace, there is a key that looks like this:

(defn ^:export init []
  (re-frame/dispatch-sync [::events/initialize-db])
  (dev-setup)
  (mount-root))

tjtolton17:05:17

wouldn't that expand to :myproject.core/events/initialize-db?

tjtolton17:05:56

in the myproject.events namespace, there is an event handler registered for ::initialize-db

tjtolton17:05:58

so how does the ::events/initialize-db in myproject.core get associated with ::initialize-db in myproject.events?

joelsanchez17:05:43

it's an alias, it will expand to the namespace that has the events alias

tjtolton17:05:56

whaaat, really?

tjtolton17:05:21

okay, that's super neat

dpsutton17:05:40

realize there's a difference between :a/b and ::a/b

💡 4
datran18:05:45

can someone shed some light on regexes in clojure? I think I'm missing a something basic. I'm trying to write a spec for a string, and that string needs to be all lower case letters or a hyphen:

datran19:05:50

I'm messing about with re-matches, but it's not matching how I'd expect

datran19:05:22

(re-matches #"([a-z]|-)" "abc") ;;=> nil

noisesmith19:05:27

re-matches matches the entire string, it doesn't do sub-string matches

noisesmith19:05:35

re-find does substring matches

andy.fingerhut19:05:54

Try (re-matches #"[a-z]+|-" ...)

💯 4
noisesmith19:05:19

youre regex does not match the entire string, so doesn't do what you describe - yeah, what @andy.fingerhut said

datran19:05:41

ok, that's starting to work

datran19:05:56

(re-matches #"[a-z]+|-" "abc-abc") ;;=> nil

noisesmith19:05:06

that's not what you described

noisesmith19:05:18

[a-z-]+ would match that

datran19:05:18

you're right, my bad

andy.fingerhut19:05:43

If you want hyphens in as many places as you can have letters, put the hyphen inside the square brackets (but at the end, or the beginning, since otherwise it has a special meaning between square brackets)

datran19:05:02

ok, that's perfect

andy.fingerhut19:05:32

Then you don't need the |- part of the regex any more, of course

datran19:05:42

so, re-find is looking at substring (in this case, each letter), and my regex says it can be any lower case letter or a hyphen

noisesmith19:05:56

don't use re-find if you want to check the entire string

noisesmith19:05:10

but you need to use a regex that describes the entire string in that case, naturally

andy.fingerhut19:05:39

re-find will look for any substring it can find that matches the regex. e.g. (re-find #"[a-z-]+" "1923-1930") returns "-"

andy.fingerhut19:05:57

whereas re-matches returns nil (no match), because the regex does not match the entire string.

datran19:05:35

(re-matches #"[a-z-]+" "abc-abc") ;; => "abc-abc"

datran19:05:47

(re-matches #"[a-z-]+" "abc-abc12") ;; => nil

petr.mensik19:05:18

How to correctly exclude file from uberjar? Both

:uberjar-exclusions [#"frontend" #"resouces/scripts" #"aws_config" #"user.clj"]
  :jar-exclusions [#"user.clj"]
doesn't really work (`src/user.clj` is the file I am concerned about)

benzap20:05:23

I found something within the clojure codebase that I haven't been able to figure out:

benzap20:05:37

So there's a PrintWriter

benzap20:05:16

However, this is using a special form PrintWriter-on

benzap20:05:35

Does this dash on have special significance in java interop?

Alex Miller (Clojure team)20:05:49

that’s just a function in clojure.core

benzap20:05:03

oh ok, i'll have to go hunting

benzap20:05:22

oh, so it was added in 1.10, no wonder

Alex Miller (Clojure team)20:05:38

yeah, it was added for prepl, but is useful otherwise too

zentrope22:05:16

I’ve got some date/parse interop that takes Instant::from. How do I do that in Clojure? Instant/from gives me an “Unable to find static field” error.

zentrope22:05:54

Example form: (.parse DateTimeFormatter/ISO_INSTANT s Instant/from)

hiredman22:05:13

where d o you see Instant::from?

hiredman22:05:45

Instant::from is neither java Instant.from nor clojure Instant/from

zentrope22:05:34

It’s a Java8+ thing.

👍 4
zentrope22:05:09

Refers to a method of a class.

hiredman22:05:20

oh, it's a SAM

mikerod14:05:30

What’s a SAM?

mikerod19:05:18

Oh nice. I didn’t think that’d be so easy to search. I thought this was called a “functional interface” before. Never heard of called SAM. Thanks for link

hiredman19:05:32

I think that term was one I saw in a lot of the lead up to indy, I suspect they wanted a different term from "functional interface" because java got a bunch of interfaces named Function

mikerod19:05:14

Yeah, that makes sense I suppose.

zentrope22:05:46

Ah, thanks for the link. (I have it in Dash.)

👍 4
hiredman22:05:49

and generating a adapter for whatever goes there

zentrope22:05:43

Their example: LocalDateTime dt = parser.parse(str, LocalDateTime::from);

hiredman22:05:51

so (reify TemporalQuery ...fill in method stuff to invoke the from static method...)

zentrope22:05:37

OK, but what am I missing with regard to the :: operator (vs .)?

ghadi22:05:11

in Java 8+, that's a direct method reference

hiredman22:05:25

the :: syntax effectively tells the java compiler to generate an implementation of the expected interface that invokes the given static method

zentrope22:05:44

.stream().map(MyType::xform) etc, etc, assumes you’re mapping MyType data, so apply the xform method to it. I see.

hiredman22:05:41

it is more or less short hand for creating anonymous classes to wrap calls to static methods

zentrope22:05:46

The super cool thing about Intellij for the bits of Java programming I still do: it suggests all those things without me ever having to understand anything!

zentrope22:05:14

And there’s a clojure.instance. Never knew that. Interesting.

seancorfield23:05:46

You mean clojure.instant?

zentrope22:05:42

Anyway, thanks @hiredman and @ghadi: I both understand and the reify worked.