Kipper icon indicating copy to clipboard operation
Kipper copied to clipboard

[Feature] Implement `do ... while` loop statement

Open Luna-Klatzer opened this issue 2 years ago • 0 comments

Is there an existing proposal for this?

  • [X] I have searched the existing issues

This feature does not exist in the latest version

  • [X] I am using the latest version

Proposal

Implement JS-like do-while-loop statements, which allow the repetitive execution of a block of code as long as a specific boolean condition is met after the first block execution. The syntax and behaviour should be exactly the same as in the JS implementation and follow the guidelines/docs of MDN do-while-loops.

Exact behaviour / changes you want

  • [ ] Implement the new reserved keywords do and while.
  • [ ] Add support for the do-while-loop syntax and implement proper semantic analysis for it.
  • [ ] Add warnings for infinite empty do-while-loops.
  • [ ] Add translation support for TypeScript and JavaScript (#208).

Luna-Klatzer avatar Aug 03 '22 16:08 Luna-Klatzer