From 40091657626750e60789b10fff30dd60a28c06d5 Mon Sep 17 00:00:00 2001 From: Father Chrysostomos Date: Tue, 13 Aug 2013 08:39:14 -0700 Subject: [PATCH] Update Devel::Peek docs with Dump changes Boy, does this whole document need a rewrite.... --- ext/Devel-Peek/Peek.pm | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/ext/Devel-Peek/Peek.pm b/ext/Devel-Peek/Peek.pm index 60a18dd..b71f378 100644 --- a/ext/Devel-Peek/Peek.pm +++ b/ext/Devel-Peek/Peek.pm @@ -76,6 +76,8 @@ Devel::Peek - A data debugging tool for the XS programmer use Devel::Peek; Dump( $a ); Dump( $a, 5 ); + Dump( @a ); + Dump( %h ); DumpArray( 5, $a, $b, ... ); mstat "Point 5"; @@ -103,6 +105,13 @@ counts on SVs. This document will take a passive, and safe, approach to data debugging and for that it will describe only the C function. +The C function takes one or two arguments: something to dump, and +an optional limit for recursion and array elements (default is 4). The +first argument is evaluted in rvalue scalar context, with exceptions for +@array and %hash, which dump the array or hash itself. So C +works, as does C. And C will call C in rvalue +context, whereas C will call it in lvalue context. + Function C allows dumping of multiple values (useful when you need to analyze returns of functions). -- 2.7.4