It is an optional, gradual type system for Clojure. Does it offer enough to be useful or are you looking for something different?
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clo...@googlegroups.com
Note that posts from new members are moderated - please be patient with your first post.
To unsubscribe from this group, send email to
clojure+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
---
You received this message because you are subscribed to the Google Groups "Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Hi there!
There is an 'optional type system' for Clojure in 'core.typed':
https://github.com/clojure/core.typed
But it also seems like others who were using such a type system have stepped away from it:
https://circleci.com/blog/why-were-no-longer-using-core-typed/
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clo...@googlegroups.com
Note that posts from new members are moderated - please be patient with your first post.
To unsubscribe from this group, send email to
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
---
You received this message because you are subscribed to the Google Groups "Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email to clojure+u...@googlegroups.com.
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clo...@googlegroups.com
Note that posts from new members are moderated - please be patient with your first post.
To unsubscribe from this group, send email to
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
---
You received this message because you are subscribed to the Google Groups "Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscribe@googlegroups.com.
Just curious... What do you think the primary contributing factor is for Cursive's NPEs? Java interop?
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
---
You received this message because you are subscribed to the Google Groups "Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email to clojure+u...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
---
You received this message because you are subscribed to the Google Groups "Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscribe@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/clojure?hl=en
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "Clojure" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to clojure+unsubscribe@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clo...@googlegroups.com
> Note that posts from new members are moderated - please be patient with your
> first post.
> To unsubscribe from this group, send email to
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscribe@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clo...@googlegroups.com
Note that posts from new members are moderated - please be patient with your first post.
To unsubscribe from this group, send email to
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
---
You received this message because you are subscribed to the Google Groups "Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscribe@googlegroups.com.
On 10/21/16, 10:40 AM, "Colin Fleming" <clo...@googlegroups.com on behalf of colin.ma...@gmail.com> wrote:
> Honestly, the easiest solution to my problem is probably just to use Kotlin, which was
> designed by JetBrains for almost exactly my use case, has great IDE support, and has
> a lot of smart people working full-time on it.
And, to be fair, Kotlin has as a design goal to help address Java’s NPE issue. Whereas Clojure has, as part of its design, idiomatic nil-punning. If you’re doing a lot of Java interop, Kotlin is going to be a better fit.
As for Typed Clojure, we’ve tried it a few times and the problems cited by CircleCI and by yourself are why we’ve given up on it each time. I will say, in Typed Clojure’s defense, that it gets better and better each time I try it so it’s definitely going in the right direction – but it is a very hard problem to solve!
Pretty much the only time I ever see NPEs is when my Clojure code touches Java interop. And, yes, that can mean numeric ops (since those are implemented directly in Java) and string manipulation (again, implemented on top of Java).
As an experiment, I tried a version of clojure.string where nil was always treated as “” and it does indeed avoid the NPEs but it comes at a performance cost (calling str or adding nil conditions). In the domain in which I work, nil -> “” is pretty much universally the right thing so it’s a cost we’re considering swallowing, for the extra simplicity it would bring to our code (i.e., creating a drop-in replacement of clojure.string that implements all of the functions with added str calls as needed – many can be handled mechanically).
We don’t do much numeric work so we don’t hit NPEs in that Java interop boundary very often. There tho’ there is almost no argument that nil -> 0 would be the “right thing” so suffering NPEs instead of some NonNumericArgumentException thing isn’t such a horrible trade off.
Sean Corfield -- (970) FOR-SEAN -- (904) 302-SEAN
An Architect's View -- http://corfield.org/
"If you're not annoying somebody, you're not really alive."
-- Margaret Atwood
Isn't a major selling point of generative testing to create loads of unique cases you can't invent on your own?
You don't trust it to do that? Is that from personal experience? Genuinely curious because I am a little excited about using it in a project at work but this is disheartening.
> In this sort of situation, a static type system which provides universal guarantees (this value can never be null) is more useful than a contract system (no null values have been seen yet for the test inputs you've tried). There's simply no way I can test all combinations, or reproduce all combinations that users might have running.
Isn't a major selling point of generative testing was that it creates loads of unique cases you can't invent on your own?
You don't trust it to do that? Is that from personal experience? Genuinely curious because I am a little excited about using it in a project at work but this is disheartening.
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
---
You received this message because you are subscribed to the Google Groups "Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email to clojure+u...@googlegroups.com.
I know a lot of people like to say how unhelpful Java like static typing is, and only more powerful type systems of the ML family add value, but I've been wondering recently if for Clojure it wouldn't make more sense to simply extend the type hints to enable an optional Java like static typing schemI the.