yield return based on Coroutines

Attila Kelemen attila.kelemen85 at gmail.com
Tue Aug 29 12:22:00 UTC 2023


As it turned out, I don't think there was much disagreement in the first
place. Because - as far as I remember - nobody wanted a language level
construct. I personally only wished the JDK to provide methods and
interfaces for this. The only question is that there are multiple ways to
implement this with different implications, and I believe the JDK should
provide at least 2 different kinds: One which requires no close, and no
longer referenced iterators would just abandon their VT forever (somewhat
dangerous, but there a lot of generators that would not be hurt by that),
and another one which can be closed explicitly. Anyway, before talking
about other specific details, we would need that the JDK puts it up on the
roadmap in the first place.

Robert Engels <rengels at ix.netcom.com> ezt írta (időpont: 2023. aug. 28., H,
13:34):

> I let it die :) - I thought because I proved that there was no difference
> in syntax or implementation by using virtual threads directly rather than
> requiring a new language continuation construct. There was some minor
> disagreement left that a “language continuation” could allow slightly more
> deterministic collection but I believe that was dismissed as being no
> different than other resource management in the JDK.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/loom-dev/attachments/20230829/1122fbba/attachment-0001.htm>


More information about the loom-dev mailing list