From: Rafael Garcia-Suarez Date: Thu, 29 Apr 2010 15:13:42 +0000 (+0200) Subject: Mention that Safe::reval() no wraps returned coderefs X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=167906a2243c13315495ab3464bc4dda6d445818;p=p5sagit%2Fp5-mst-13.2.git Mention that Safe::reval() no wraps returned coderefs --- diff --git a/dist/Safe/Safe.pm b/dist/Safe/Safe.pm index 20efe17..34659e6 100644 --- a/dist/Safe/Safe.pm +++ b/dist/Safe/Safe.pm @@ -651,9 +651,9 @@ expression evaluated, or a return statement may be used, just as with subroutines and B. The context (list or scalar) is determined by the caller as usual. -This behaviour differs from the beta distribution of the Safe extension -where earlier versions of perl made it hard to mimic the return -behaviour of the eval() command and the context was always scalar. +If the return value of reval() is (or contains) any code reference, +those code references are wrapped to be themselves executed always +in the compartment. See L. The formerly undocumented STRICT argument sets strictness: if true 'use strict;' is used, otherwise it uses 'no strict;'. B: if