Problems? Is your data what you think it is? | |
PerlMonks |
Re: RFC: Perl<->JSON<->YAML<->Dumper : roundtripping and possibly with unicodeby kcott (Archbishop) |
on Apr 09, 2020 at 18:00 UTC ( [id://11115288]=note: print w/replies, xml ) | Need Help?? |
G'day bliako, As requested, here's some comments and suggestions. Naming Subroutine names with a leading underscore tend to suggest private methods or implementation details; these are generally for internal use and not for users of module, i.e. not part of the interface — _qquote_redefinition_by_Corion() is a part of the implementation and the leading underscore is appropriate. The other four subroutines (_read_from_* and _write_to_*) are, in my opinion, part of the interface — consider removing the leading underscore from these. Exporting I wouldn't export those ten subroutines by default (i.e. via @EXPORT); in fact, I wouldn't export anything by default, instead using @EXPORT_OK as recommended in "Exporter: Selecting What to Export". In addition to using @EXPORT_OK, I would add %EXPORT_TAGS so that users of the module do not have to write long import lists. The following is an example of what can be done; it is not a recommendation of what you should do, although I do think something along these lines is a good idea.
Layout Some of your code layout could be improved. Lines like this one are not easy to read:
That's 134 characters long; plus there's leading whitespace for indentation. This would be much more readable, at least in my opinion, as:
— Ken
In Section
Meditations
|
|