X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pod%2Fperltooc.pod;h=fdddb02531dd24411018213a1d3d0ab0645eb107;hb=83272a45226e83bd136d713158e9b44ace2dbc8d;hp=c1622200616d6d747310a47500a8ddd987f3771b;hpb=890a53b979262c647cff6eff22d9cf68bc23d720;p=p5sagit%2Fp5-mst-13.2.git diff --git a/pod/perltooc.pod b/pod/perltooc.pod index c162220..fdddb02 100644 --- a/pod/perltooc.pod +++ b/pod/perltooc.pod @@ -646,7 +646,7 @@ name them whatever you care to. Blindly and obediently using new() for each and every constructor you ever write is to speak Perl with such a severe C++ accent that you do a disservice to both languages. There's no reason to insist that each class have but one constructor, -or that that constructor be named new(), or that that constructor be +or that a constructor be named new(), or that a constructor be used solely as a class method and not an object method. The next section shows how useful it can be to further distance ourselves @@ -1294,10 +1294,6 @@ Inheritance is a powerful but subtle device, best used only after careful forethought and design. Aggregation instead of inheritance is often a better approach. -We use the hypothetical our() syntax for package variables. It works -like C, but looks like my(). It should be in this summer's -major release (5.6) of perl--we hope. - You can't use file-scoped lexicals in conjunction with the SelfLoader or the AutoLoader, because they alter the lexical scope in which the module's methods wind up getting compiled.