Perldoc Search: "$)" perl-5.20.1

search official POD


12 PODs, 38 LINEs found.
perlsub.pod
284 :         sub foo :prototype($) { $_[0] }
288 :         sub foo :prototype($$) ($left, $right) {
904 :        sub mylink ($$)         mylink $old, $new
905 :        sub myvec ($$$)         myvec $var, $offset, 1
906 :        sub myindex ($$;$)      myindex &getstring, "substr"
907 :        sub mysyswrite ($$$;$)  mysyswrite $buf, 0, length($buf) - $off, $off
913 :        sub myopen (*;$)        myopen HANDLE, $name
916 :        sub myrand (;$)         myrand 42
1006 :         sub func ($) {
1020 :             sub foo($$);
1021 :             sub foo($$) {
perlvar.pod
91 :             LinuxThreads is now obsolete on Linux, and caching "getpid()" like this made embedding perl unnecessarily complex (since you'd have to manually update the value of $$), so now $$ and "getppid()" will always return the same values as the underlying C library.
122 :             However, a value assigned to $( must be a single number used to set the real gid. So the value given by $( should *not* be assigned back to $( without being forced numeric, such as by adding zero. Note that this is different to the effective gid ($)) which does take a list.
130 :     $)      The effective gid of this process. If you are on a machine that supports membership in multiple groups simultaneously, gives a space separated list of groups you are in. The first number is the one returned by "getegid()", and the subsequent ones by "getgroups()", one of which may be the same as the first number.
132 :             Similarly, a value assigned to $) must also be a space-separated list of numbers. The first number sets the effective gid, and the rest (if any) are passed to "setgroups()". To get the effect of an empty list for "setgroups()", just repeat the new effective gid; that is, to force an effective gid of 5 and an effectively empty "setgroups()" list, say " $) = "5 5" ".
134 :             You can change both the effective gid and the real gid at the same time by using "POSIX::setgid()" (use only a single numeric argument). Changes to $) require a check to $! to detect any possible errors after an attempted change.
136 :             $<, $>, $( and $) can be set only on machines that support the corresponding *set[re][ug]id()* routine. $( and $) can be swapped only on machines supporting "setregid()".
perldiag.pod
1222 :         (W syntax) In scalar context, you've used an array index/value slice (indicated by %) to select a single element of an array. Generally it's better to ask for a scalar value (indicated by $). The difference is that $foo[&bar] always behaves like a scalar, both in the value it returns and when evaluating its argument, while %foo[&bar] provides a list context to its subscript, which can do weird things if you're expecting only one subscript. When called in list context, it also returns the index (what &bar returns) in addition to the value.
1225 :         (W syntax) In scalar context, you've used a hash key/value slice (indicated by %) to select a single element of a hash. Generally it's better to ask for a scalar value (indicated by $). The difference is that $foo{&bar} always behaves like a scalar, both in the value it returns and when evaluating its argument, while @foo{&bar} and provides a list context to its subscript, which can do weird things if you're expecting only one subscript. When called in list context, it also returns the key in addition to the value.
2474 :         (W syntax) You've used an array slice (indicated by @) to select a single element of an array. Generally it's better to ask for a scalar value (indicated by $). The difference is that $foo[&bar] always behaves like a scalar, both when assigning to it and when evaluating its argument, while @foo[&bar] behaves like a list when you assign to it, and provides a list context to its subscript, which can do weird things if you're expecting only one subscript.
2479 :         (W syntax) You've used a hash slice (indicated by @) to select a single element of a hash. Generally it's better to ask for a scalar value (indicated by $). The difference is that $foo{&bar} always behaves like a scalar, both when assigning to it and when evaluating its argument, while @foo{&bar} behaves like a list when you assign to it, and provides a list context to its subscript, which can do weird things if you're expecting only one subscript.
2564 :         (F) You tried to assign to $), and your operating system doesn't support the setegid() system call (or equivalent), or at least Configure didn't think so.
perlsyn.pod
32 :     A bare declaration like that declares the function to be a list operator, not a unary operator, so you have to be careful to use parentheses (or "or" instead of "||".) The "||" operator binds too tightly to use after list operators; it becomes part of the last element. You can always use parentheses around the list operators arguments to turn the list operator back into something that behaves more like a function call. Alternatively, you can use the prototype "($)" to turn the subroutine into a unary operator:
34 :       sub myname ($);
496 :         =item snazzle($)
504 :         sub snazzle($) {
perlop.pod
1025 :             PATTERN may contain variables, which will be interpolated every time the pattern search is evaluated, except for when the delimiter is a single quote. (Note that $(, $), and $| are not interpolated because they look like end-of-string tests.) Perl will not recompile the pattern unless an interpolated variable that it contains changes. You can force Perl to skip the test and never recompile by adding a "/o" (which stands for "once") after the trailing delimiter. Once upon a time, Perl would recompile regular expressions unnecessarily, and this modifier was useful to tell it not to do so, in the interests of speed. But now, the only reasons to use "/o" are one of:
1340 :             $perl_info  = qx(ps $$);            # that's Perl's $$
1632 :             Interpolation in patterns has several quirks: $|, $(, $), "@+" and "@-" are not interpolated, and constructs $var[SOMETHING] are voted (by several different estimators) to be either an array element or $var followed by an RE alternative. This is where the notation "${arr[$bar]}" comes handy: "/${arr[0-9]}/" is interpreted as array element -9, not as a regular expression from the variable $arr followed by a digit, which would be the interpretation of "/$arr[0-9]/". Since voting among different estimators may occur, the result is not predictable.
perlfork.pod
94 :                 sub pipe_to_fork ($) {
123 :                 sub pipe_from_fork ($) {
perlfunc.pod
3364 :         If the subroutine's prototype is "($$)", the elements to be compared are passed by reference in @_, as for a normal subroutine. This is slower than unprototyped subroutines, where the elements to be compared are passed into the subroutine as the package global variables $a and $b (see example below). Note that in the latter case, it is usually highly counter-productive to declare $a and $b as lexicals.
3454 :             sub backwards ($$) { $_[1] cmp $_[0]; }  # $a and $b are
perlport.pod
345 :     Don't assume the Unix user and group semantics: especially, don't expect the $< and $> (or the $( and $)) to work for switching identities (or memberships).
perlref.pod
374 :         *$name = sub ($) { "<FONT COLOR='$name'>$_[0]</FONT>" };
perlipc.pod
38 :             # snazzy writing of: kill("HUP", -$$)
perlunicode.pod
794 :         sub my_escape_html ($) {
perlpacktut.pod
639 :         sub cat($){
<< Back to Perldoc Search