Re: Adding an @Immutable annotation to Java

2021-11-25 Thread Justin Dekeyser
, no? (downcasting) Since Object is the super class of everything, it sounds like a problem. What have you thought about to handle this concern? Regards, Justin Dekeyser On Thu, Nov 25, 2021 at 9:08 AM Alberto Otero Rodríguez wrote: > > Hi, I was thinking that it could be interesting

Re: 'Find' method for Iterable

2020-11-11 Thread Justin Dekeyser
elt so useful and language fundamental, that it should be in the java.lang package. Best regards, Justin Dekeyser On Tue, Nov 10, 2020 at 7:02 PM Nir Lisker wrote: > > Did this discussion get lost? > > On Sun, Sep 20, 2020 at 1:27 AM Nir Lisker wrote: > > > While it mi

Re: Asking to contribute(?)

2020-11-04 Thread Justin Dekeyser
about that toList stuff, so I guess it's ok!) I am just a bit cold about the idea that the spec will make the compiler's job, but I guess in Java there is no work around. I don't know what the community thinks about it. Regards, Justin Dekeyser On Wednesday, November 4, 2020, Rob Spoor wrote

Asking to contribute(?)

2020-11-04 Thread Justin Dekeyser
regards, Justin Dekeyser

Re: RFR: 8180352: Add Stream.toList() method

2020-11-04 Thread Justin Dekeyser
Hello, Ah that's a super good news, thanks a lot for sharing ! I dream of this since 2 years <3 Best regards, Justin Dekeyser On Wed, Nov 4, 2020 at 10:24 AM Tagir Valeev wrote: > > Hello! > > On Wed, Nov 4, 2020 at 4:16 PM Justin Dekeyser > wrote: > > What about t

Re: RFR: 8180352: Add Stream.toList() method

2020-11-04 Thread Justin Dekeyser
Stream interface, in such a way one could use the "natural flow" of writing while binding its own implementation and, therefore, use its own shortcuts. Best regards, Justin Dekeyser On Wed, Nov 4, 2020 at 9:59 AM Tagir Valeev wrote: > > Hello! > > On Wed, Nov 4, 2020 at 2:55 A

Re: 'Find' method for Iterable

2020-09-21 Thread Justin Dekeyser
think this was not the purpose (from a previous long post there were in this newsletter, about splitting the List interface in two interfaces, readonly and write-only). Regards, Justin Dekeyser On Mon, Sep 21, 2020 at 10:31 AM Justin Dekeyser wrote: > > Hi all, > > Correct me

Re: 'Find' method for Iterable

2020-09-21 Thread Justin Dekeyser
syntax ? Regards, Justin Dekeyser On Mon, Sep 21, 2020 at 10:08 AM Michael Kuhlmann wrote: > > Hi Nir, > > at first I thought "Wow, it would be really cool to have that method in > Iterable! Why isn't it there already?" > > But after thinking about it, I'm now convince

Re: Type inference: bug or feature?

2020-07-27 Thread Justin Dekeyser
! ;-) Thank you very much, Have a nice day, Justin Dekeyser On Mon, Jul 27, 2020 at 12:55 PM Remi Forax wrote: > - Mail original - > > De: "Maurizio Cimadamore" > > À: "Justin Dekeyser" , "core-libs-dev" < > core-libs-dev@openjdk.j

Re: Type inference: bug or feature?

2020-07-27 Thread Justin Dekeyser
Dear all, Okay, thank you very much for the many references you gave me! Indeed I wasn't aware of this specificity of cast expressions you mentioned, very interesting ! Sorry for the long email chain, though! Have a nice day, Justin Dekeyser On Mon, Jul 27, 2020 at 12:26 PM Maurizio

Re: Type inference: bug or feature?

2020-07-27 Thread Justin Dekeyser
lly don't get, or something else :/ Regards, Justin Dekeyser On Mon, Jul 27, 2020 at 10:21 AM Florian Weimer wrote: > * Justin Dekeyser: > > > Nevertheless, the point was not really about list stuffs, and is not > > related to the lack of co/contra variance. > >

Re: Type inference: bug or feature?

2020-07-27 Thread Justin Dekeyser
e, we have a casting operation that prevents some inference. I'm really not sure this is no bug :/ Regards, Justin Dekeyser On Mon, Jul 27, 2020 at 9:43 AM Florian Weimer wrote: > * Justin Dekeyser: > > > Then the following codes does not compile (for the same reason): > >

Type inference: bug or feature?

2020-07-26 Thread Justin Dekeyser
compile: var x = emptyList(Number.class); // inferred to List List x = emptyList(Number.class); // no mistake here, it's Integer on the left Is this the expected behavior? Why does casting operation here interfere with type inference like this? Regards, Justin Dekeyser <https://www.avast.

Re: Feature Request

2020-07-21 Thread Justin Dekeyser
Hello, Wouldn't that be too dangerous, in the sense that it makes us lose control over how the String are actually constructed and aggregated together? Aside from that, what kind of interpolation are you looking for, and how the String.format utility does not meet your needs? Regards, D.J.

Re: Was functional-Try already discussed?

2020-05-08 Thread Justin Dekeyser
on { V apply(U args) throws E; } Function> safe (TryFunction f) { ... } ``` The Try could be enriched with many interpolability facilities, but its essence would be to catch the provided exception. Best regards, Justin Dekeyser On Fri, May 8, 2020 at 1:23 AM Justin Dekeyser wrote: >

Was functional-Try already discussed?

2020-05-05 Thread Justin Dekeyser
style while keeping this cool feature of checked exceptions. Best regards, Justin Dekeyser