Development of an internal social media platform with personalised dashboards for students
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

continue_in_finally.py 415B

123456789101112131415161718192021222324
  1. """Test that `continue` is catched when met inside a `finally` clause."""
  2. # pylint: disable=missing-docstring, lost-exception, broad-except
  3. while True:
  4. try:
  5. pass
  6. finally:
  7. continue # [continue-in-finally]
  8. while True:
  9. try:
  10. pass
  11. finally:
  12. break
  13. while True:
  14. try:
  15. pass
  16. except Exception:
  17. pass
  18. else:
  19. continue