while.asl 346 B

12345678910111213141516171819202122232425
  1. DefinitionBlock("while.aml", "DSDT", 1, "RSACPI", "WHILE", 1) {
  2. Name(X, 0)
  3. While (X < 5) {
  4. X++
  5. }
  6. // Test `DefBreak` - Y should only make it to 5
  7. Name(Y, 0)
  8. While (Y < 10) {
  9. If (Y >= 5) {
  10. Break
  11. }
  12. Y++
  13. }
  14. // Test `DefContinue` - Z should remain at zero
  15. Name(CNT, 0)
  16. Name(Z, 0)
  17. While (CNT < 5) {
  18. CNT++
  19. Continue
  20. Z++
  21. }
  22. }