in reply to Re: Explanation of Perl one-liner required
in thread Explanation of Perl one-liner required

I do not agree. A modern Text::CSV will use the XS-version if available and the Pure Perl version if XS is not available. So there is no need to "upgrade" your scripts. As per the docs:
Text::CSV provides facilities for the composition and decomposition of comma-separated values using Text::CSV_XS or its pure Perl version.

If there is anything you should do, then it is to replace Text::CSV_XS by Text::CSV to make your script more universally applicable.

CountZero

A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

Replies are listed 'Best First'.
Re^3: Explanation of Perl one-liner required
by almut (Canon) on Sep 28, 2009 at 14:51 UTC
Re^3: Explanation of Perl one-liner required
by ikegami (Patriarch) on Sep 28, 2009 at 16:35 UTC
    You're missing the context. He doesn't have a modern Text::CSV, and it's easier instructing this particular monk to install Text::CSV_XS (simple ppm command) than to have him upgrade Text::CSV (which would require installation of make tools, an exercise requiring at least 5 posts to explain to this monk).
      Text::CSV (v.1.13) is available on the Activestate PPM site for Perl 5.8 and 5.10, so it is easy to install as Text::CSV_XS

      Update: I see, Win still must have a Perl 5.6 for which indeed there is no modern Text::CSV available; but then again for Perl 5.6 there is no Text::CSV_XS available AT ALL on the ActiveState PPM it seems. So the substitution trick won't work I'm afraid.

      CountZero

      A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

        Regarding your update, Text-CSV_XS is cleary listed. Twice even. Some of his repos have it.