Starts a perl code snippet
perl.begin [-n] [-q] [(<perl_context>[,<arg0>[,<arg1>[...]]])]
<perl code>
Indicates the beginning of a snipped of perl code. The whole code part between perl.begin and perl.end is executed in a perl interpreter. If perl.end is omitted then it is implicitly assumed that the code from perl.begin to the end of the command buffer is perl.
Each perl code execution is bound to a perl context (that is in fact a particular instance of a perl interpreter). If <perl_context> is not specified or it is an empty string then temporary perl interpreter is created and destroyed just after the code snippet has terminated execution. If <perl_context> is specified then a perl interpreter keyed to that context is used: if it was already existing then it is reused otherwise it is created. Any <perl_context> is persistent: it mantains the function declarations and perl variable states until explicitly destroyed with perl.destroy (or the perlcore module is forcibly unloaded).
The <arg0>,<arg1>,... arguments, if present, are passed to the perl code snippet in the @_ array (accessible as $_[0],$_[1]...).
The return value of the perl code is propagated to the current context (just like setreturn was called on it) unless the -n switch is used.
The -q switch prevents from the command from printing any warning.
See the perl scripting documentation for more information.
-q | --quiet
Prevents the command from printing any warnings.
-n | --no-return
Prevents the perl script return value to be propagated to the current context.
-f | --fail-on-error
Treat perl errors as KVS errors and abort execution of the current script. Incompatible with -q
Syntax Specification
perl.begin [-n] [-q] [(<perl_context>[,<arg0>[,<arg1>[...]]])]
<perl code>

    KVIrc::eval("echo \"Hello World from perl!\"");

Index, Commands
KVIrc 3.9.99 Documentation
Generated by root at Wed Oct 17 19:34:06 2007