Loading ...
Sorry, an error occurred while loading the content.

13Re: [extremeperl] Testing, Audience, etc.

Expand Messages
  • Rob Nagler
    Jan 29 12:15 PM
      Tom Brown writes:
      > but it's not. An array in a scalar context is the number of elements in
      > it. I don't need to tell you that, your knowledge of the language is
      > better than mine....

      I'm not so sure about that.

      > adding the int() function makes me look at _why_ you are adding the
      > function, and try to find the twist that needs it. There isn't one, so
      > I've wasted time figuring that out. That is why I prefer either scalar()
      > or nothing.

      Nothing like data to backup a hypothesis:

      trgrep '\bint\(?\s*@' /usr/lib/perl | grep -v Bivio | wc

      trgrep '\bscalar\(?\s*@' /usr/lib/perl | grep -v Bivio | wc

      The scalars have it. I'll change it to be nothing or scalar where
      required, thanks.

      > Obviously, it's mostly a matter of style. Does it matter? I can't answer
      > that. For the book to be used/popular you probably want to try to code to
      > your target audience. No individual can claim to represent that.

      This is the danger of writing a book about perl and XP. Whenever I
      mention that I program in perl at an XP meeting, I get the strangest
      looks. Fortunately, the perl community is more forgiving about XP.
      Yet they aren't the easiest audience to please either. :)

    • Show all 20 messages in this topic