X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=lib%2FScope%2FUpper.pm;h=4a9010059f7ce5112af17d57452539ae17458ff8;hb=3852d1e712b2e4f5c1ab14efe303ce7d7a95464d;hp=f4d43e7dfa04bd67171193f9b0d9dbb0d09f6b45;hpb=ca50ad37afae0c65ddc432c03f68d5cefae4de29;p=perl%2Fmodules%2FScope-Upper.git
diff --git a/lib/Scope/Upper.pm b/lib/Scope/Upper.pm
index f4d43e7..4a90100 100644
--- a/lib/Scope/Upper.pm
+++ b/lib/Scope/Upper.pm
@@ -170,7 +170,7 @@ localize variables, array/hash values or deletions of elements in higher context
=item *
-return values immediately to an upper level with L, and know which context was in use then with L ;
+return values immediately to an upper level with L, L and L, and know which context was in use then with L ;
=item *
@@ -316,6 +316,38 @@ This means that
will set C<$num> to C<'z'>.
You can use L to handle these cases.
+=head2 C
+
+ yield;
+ yield @values, $context;
+
+Returns C<@values> I the context pointed by or just above C<$context>, and immediately restart the program flow at this point.
+If C<@values> is empty, then the C<$context> parameter is optional and defaults to the current context ; otherwise it is mandatory.
+
+L differs from L in that it can target I upper scope (besides a C substitution context) and not necessarily a sub, an eval or a format.
+Hence you can use it to return values from a C or a C