From 1973dedb5b035030bf32ff862f25895c8d48a48c Mon Sep 17 00:00:00 2001 From: Fabrice Benhamouda Date: Thu, 23 Feb 2023 10:58:08 -0500 Subject: [PATCH] Clarify that `Approve` and `Reject` always exit (#660) --- CHANGELOG.md | 2 ++ docs/control_structures.rst | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e83179d21..8e38c5b75 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ ## Added +* Clarify that `Approve` and `Reject` always exit in the documentation. + ## Fixed ## Changed diff --git a/docs/control_structures.rst b/docs/control_structures.rst index b8b0d26d3..7079abf3c 100644 --- a/docs/control_structures.rst +++ b/docs/control_structures.rst @@ -19,7 +19,8 @@ The :any:`Approve` and :any:`Reject` expressions cause the program to immediatel is used, then the execution is marked as successful, and if :code:`Reject` is used, then the execution is marked as unsuccessful. -These expressions also work inside :ref:`subroutines `. +These expressions also work inside :ref:`subroutines `. When used inside subroutines, they +also cause the program to immediately exit, contrary to :code:`Return(...)` which just returns from the subroutine. .. _seq_expr: