develooper Front page | perl.perl6.users | Postings from September 2018

Just posted a documentation RFE

From:
ToddAndMargo
Date:
September 26, 2018 21:59
Subject:
Just posted a documentation RFE
Message ID:
ed220272-ec7f-8113-46f5-fb39ea08b1bc@zoho.com
Hi All,

I just posted a documentation fix and RFE

     A booboo and an rfe in contains documentation
     https://github.com/perl6/doc/issues/2334

Thank you all for helping me understand to the point that I
can stop grumbling and start being part of the solution.

:-)

-T


Over on
https://docs.perl6.org/routine/contains#(Str)_method_contains
the return value is missing: --> Bool

Since it need to be updated anyway, for clarity, would you please 
consider the following enhancements:

Old: multi method contains(Str:D: Str:D $needle, Int:D $pos)
Proposed: multi method contains(Str:D $Haystack : Str:D $Needle, Int:D 
$Position --> Bool)

Giving the input string the name "Haystack" gives meaning to the 
parameter of "Needle". You are searching for the "needle in the 
haystack". Without this linkage, one is left wondering what the "needle" 
is "sticking".

The " :", rather than ":" makes it more clear that it is a delimiter to 
the untrained eye.

And spelling out "Position" just makes it clearer what it is. (Not "pos" 
for Positive or what ever else it can be mistaken for.)



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About