Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re^8: Converting Unicode

by Polyglot (Chaplain)
on Dec 20, 2023 at 23:52 UTC ( [id://11156437]=note: print w/replies, xml ) Need Help??


in reply to Re^7: Converting Unicode
in thread Converting Unicode

This node falls below the community's threshold of quality. You may see it by logging in.

Replies are listed 'Best First'.
Re^9: Converting Unicode
by SankoR (Prior) on Dec 21, 2023 at 00:24 UTC
    Accept your arguments as a hash.
Ordering of parameters - Re^9: Converting Unicode
by soonix (Chancellor) on Dec 21, 2023 at 09:11 UTC
    Perhaps off-topic, and I don't remember where I have this from, but ordering of parameters is partly conceptual, partly a documentation issue. The suggestion is to put the parameters in a sentence (and use that sentence always in the function help). E.g.
    • search needle in haystack (this variant is probably a "false friend" for non-native speakers) → "needle" parameter goes first, then haystack
    • search haystack for needle → "haystack" parameter goes first, then needle
    Of course, your sentence(s) would be much longer, but once you have a "natural" phrasing, you have a "natural" order of the parameters. And, as the example shows, word use is important…
    This is (programming) language independent, btw.
    A reply falls below the community's threshold of quality. You may see it by logging in.
Re^9: Converting Unicode
by eyepopslikeamosquito (Archbishop) on Dec 22, 2023 at 04:27 UTC

    Your flamebait has attracted enough interesting and useful replies that I've just added it to my list of references at On Interfaces and APIs. :)

    As discussed in that node -- and as you have discovered -- the dark art of interface and API design is certainly not an easy one to master!

    > Or maybe, just maybe, you have no clue what I am doing and why I need all the variables in a single subroutine

    Instead of ranting like that in an eight-level deep reply to an old thread started by BernieC, I suggest you start a new thread clearly describing the problem you are trying to solve, along with your proposed API to solve it. Much more likely to elicit useful replies that will improve your initial attempt at an API.

    👁️🍾👍🦟

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11156437]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (2)
As of 2025-11-15 11:43 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What's your view on AI coding assistants?





    Results (72 votes). Check out past polls.

    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.