=head1 SYNOPSIS
- use Math::BogFloat;
+ use Math::BigFloat;
$f = Math::BigFloat->new($string);
$f->fadd(NSTR) return NSTR addition
GV *gv = gv_fetchpv(name ? name : "__ANON__",
GV_ADDMULTI | (block ? 0 : GV_NOINIT), SVt_PVCV);
char *ps = proto ? SvPVx(((SVOP*)proto)->op_sv, na) : Nullch;
- register CV *cv;
+ register CV *cv=0;
I32 ix;
if (o)
Does exactly the same thing as "exec LIST" except that a fork is done
first, and the parent process waits for the child process to complete.
Note that argument processing varies depending on the number of
-arguments. The return value is the exit status of the program as
+arguments. If there is more than one argument in LIST, or if LIST is
+an array with more than one value, starts the program given by the
+first element of the list with arguments given by the rest of the list.
+If there is only one scalar argument, the argument is
+checked for shell metacharacters, and if there are any, the entire
+argument is passed to the system's command shell for parsing (this is
+C</bin/sh -c> on Unix platforms, but varies on other platforms). If
+there are no shell metacharacters in the argument, it is split into
+words and passed directly to execvp(), which is more efficient.
+
+The return value is the exit status of the program as
returned by the wait() call. To get the actual exit value divide by
256. See also L</exec>. This is I<NOT> what you want to use to capture
the output from a command, for that you should use merely backticks or
If the PATTERN evaluates to the empty string, the last
I<successfully> matched regular expression is used instead.
-If used in a context that requires a list value, a pattern match returns a
+If the C</g> option is not used, C<m//> in a list context returns a
list consisting of the subexpressions matched by the parentheses in the
-pattern, i.e., (C<$1>, $2, $3...). (Note that here $1 etc. are also set, and
+pattern, i.e., (C<$1>, C<$2>, C<$3>...). (Note that here
+C<$1> etc. are also set, and
that this differs from Perl 4's behavior.) If there are no parentheses,
the return value is the list C<(1)> for success or C<('')> upon failure.
With parentheses, C<()> is returned upon failure.
in case you want to append to each file, or reset line numbering (see
example in L<perlfunc/eof>).
+Finally, note that the B<-i> switch does not impede execution when no
+files are given on the command line. In this case, no backup is made
+(the original file cannot, of course, be determined) and processing
+proceeds from STDIN to STDOUT as might be expected.
+
=item B<-I>I<directory>
Directories specified by B<-I> are prepended to the search path for
IoFLAGS(io) &= ~IOf_START;
IoLINES(io) = 0;
if (av_len(GvAVn(last_in_gv)) < 0) {
- SV *tmpstr = newSVpv("-", 1); /* assume stdin */
- av_push(GvAVn(last_in_gv), tmpstr);
+ do_open(last_in_gv,"-",1,FALSE,0,0,Nullfp);
+ sv_setpvn(GvSV(last_in_gv), "-", 1);
+ SvSETMAGIC(GvSV(last_in_gv));
+ fp = IoIFP(io);
+ goto have_fp;
}
}
fp = nextargv(last_in_gv);
}
RETURN;
}
+ have_fp:
if (gimme == G_SCALAR) {
sv = TARG;
if (SvROK(sv))