Yes and no. If you want a module to automatically load another module from XS, and not import all functions/methods, this is a cleaner way to do so. Of course you can croak/fail/die/barf/puke when a user tries to invoke something that he/she did not explicitely load, but as Encode is a CORE module I see no harm in hiding the require from XS and making the underlying module DWIM more.
I agree that this is a grey/gray area and opinions may well differ if which case I think you should agree to disagree.
XS is a different world and pulling the right strings is sometimes extremely hard compared to how easy perl made it in the language level itself.
Enjoy, Have FUN! H.Merijn
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.