clojure-dev

cfleming 2023-05-19T02:40:00.043309Z

A Cursive user mentioned that Cursive didn’t resolve deftype and defrecord fields correctly when using the .-field access syntax. This turned out to be when fields contained a dash, like (defrecord Foo [my-field]). In that case, Cursive would autocomplete and resolve .-my_field, because that’s what the actual field is called on the Java object. However, the Clojure compiler does accept .-my-field. Is there some magic happening here to accept this form?

👀 1
Alex Miller (Clojure team) 2023-05-21T17:29:47.410529Z

don't know, must be going through a munge cycle somewhere

cfleming 2023-05-21T22:04:27.616569Z

Ok, I was mostly curious, I’ve fixed support for that anyway.