X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pod%2Fperlfunc.pod;h=7ba00c83a9522f2417232c3fca9d5f8cf4ea9510;hb=2b5ab1e742ea1b1374dcea7f6f90ef5c5cf29914;hp=766b060c8a7f2f2f52f606fbce26216825fe4e9a;hpb=91500cfd5c426b5ce4db817d5b64c763d5b8822b;p=p5sagit%2Fp5-mst-13.2.git diff --git a/pod/perlfunc.pod b/pod/perlfunc.pod index 766b060..7ba00c8 100644 --- a/pod/perlfunc.pod +++ b/pod/perlfunc.pod @@ -12,11 +12,12 @@ operators take more than one argument, while unary operators can never take more than one argument. Thus, a comma terminates the argument of a unary operator, but merely separates the arguments of a list operator. A unary operator generally provides a scalar context to its -argument, while a list operator may provide either scalar and list +argument, while a list operator may provide either scalar or list contexts for its arguments. If it does both, the scalar arguments will be first, and the list argument will follow. (Note that there can ever -be only one list argument.) For instance, splice() has three scalar -arguments followed by a list. +be only one such list argument.) For instance, splice() has three scalar +arguments followed by a list, whereas gethostbyname() has four scalar +arguments. In the syntax descriptions that follow, list operators that expect a list (and provide list context for the elements of the list) are shown @@ -47,6 +48,11 @@ example, the third line above produces: print (...) interpreted as function at - line 1. Useless use of integer addition in void context at - line 1. +A few functions take no arguments at all, and therefore work as neither +unary nor list operators. These include such functions as C