3 ms·
Looks readable to me. Though you had the advantage of not being forced into using Perl for really complex data structures. I love Perl, but that's the part I
by tyingq 3y ago
Looks readable to me. Though you had the advantage of not being forced into using Perl for really complex data structures.
I love Perl, but that's the part I don't like. If you, for example, have to parse a very deeply nested piece of JSON, you're very quickly into that weak spot. Lots of crazy sigils, braces, etc...all mushed together. Worse if you're having to use refs, globs, etc.
- kqr 3y agoI would argue if you "have to parse a very deeply nested" data format you should have subroutines or objects with methods for that specific task, and not rely on generic language container types. What you're running into is insufficient modeling of the problem, not a deficiency unique to any language.
- tyingq 3y agoBut a Perl object underneath is a hash, or list, or whatever. That abstraction doesn't save you from Perl's "sigil per type" and other oddities. It maybe encapsulates it, but...