Too many people these days learn programming by way of languages where all of the datastructure work is done for them, so they really just become users of tools instead of people that can think for themselves...

I agree with you that people need to learn the basics too, but I disagree that being a "user of tools" is a bad thing. I think if you look at all of mankinds great acheivements (especially in the modern era), you will find that many (if not all of them) would not have been possible if people did not stand on the shoulders of others to get there. It is the sharing of knowledge and tools which got us to where we are today as a species (I will make no judgements as to whether that is a good place or a bad place).

This probably involves having some objects behave as Nodes, which is where we need mixins (subclassing Node is wrong!)

I like mix-ins too, but I am not sure they are always better than subclassing (which is what I think your implying here, but I may be wrong).

I also abhor the design pattern FAD so I avoid things such as VisitorFactories, as I get this silly image of a factory with Tourists popping out of the loading dock -- that's not what OO is supposed to be about.

I don't agree that it is a FAD, and all that being a "FAD" implies. But that is your perogative.

I think you've got a Forrest::Complex there instead of a Tree::Simple

Maybe if you take into account all the other Tree::Simple::* classes, but that is all optional. And while I am not really 100% happy with the ::Simple name, and have many times regreted calling it that, it is too late to change now as I have a number of users of the module already, that that is not fair to them.

No reason to rant against Tree::DAG_Node about line count (line count wars are always petty) in your POD

I just re-read that, and I realize I am not being clear. My problem with Tree::DAG_Node is that it only has one test, and that is to test if the module loads without errors. It is pretty well known and accepted that the number of bugs increases alongside the number of lines of code. So to me having 1500+ lines of virtually untested code is not acceptable, I am (badly) contrasting this with the 250+ lines of code in Tree::Simple, which comes with approx. 400+ tests and has 97% code coverage.

-stvn

In reply to Re^2: How do "you" make a tree in perl by stvn
in thread How do "you" make a tree in perl by stvn

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • 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:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.