Skip to content

Poll: until in addition to while #562

@lachbaer

Description

@lachbaer

Because it always comes up from time to time 😃

The until keyword is available in many other programming languages and is made much use of. In C-derived languages however it does not exist, because it can be expressed by while (!(...)). Nevertheless, there seem to be quite some people who would like to have it additionally, not only in C#.

This poll is not about discussing until! It shall only be a rough survey on how community members currently think.

Sample:

do {
    PullNewItems(itemlist, source);
    Process(itemlist);
} while (!(list.IsFull || source.IsEmpty));

vs.

do {
    PullNewItems(itemlist, source);
    Process(itemlist);
} until (list.IsFull || source.IsEmpty);

Poll

  • ❤️ I would love to see it in the language soon (it eases conditions for me)
  • 🎉 If it were available I would certainly use it instead of while (!...)
  • 👍 It's okay, I might use it sometimes instead of while (!...)
  • 😃 I don't care, but I'll most probably stick with the existing while construct
  • 👎 It does not belong in the language! All users shall learn while(!...) as reading 'until' if they like
  • 😕 The other options don't reflect my opinion. Feel free to comment below.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions