makamaka / Text-CSV

comma-separated values manipulator
24 stars 19 forks source link

Remove bad STDOUT mention #51

Closed jidanni closed 10 months ago

jidanni commented 3 years ago

We read "out" can be a file name (e.g. "file.csv"), which will be opened for writing and closed when finished, a file handle (e.g. $fh or "FH"), a reference to a glob (e.g. "*STDOUT"), the glob itself (e.g. *STDOUT), " That's right. So I removed the invalid line.

jidanni commented 3 years ago

Hazards: creates ./STDOUT file, and if use strict: makes warnings.

jidanni commented 3 years ago

I didn't edit the _PP version. Please do if needed.

charsbar commented 10 months ago

Could you make a PR for https://github.com/Tux/Text-CSV_XS if this still matters to you? The doc of Text::CSV(_PP) is copied from there.

Note also: when perl encounters csv(in => $aoa, out => STDOUT);, it spits an error if strict ( Bareword "STDOUT" not allowed while "strict subs" in use ) but it writes to a file called STDOUT if not strict. So, whether the line is invalid or not depends on the mode.

jidanni commented 10 months ago

There should be some warnings in the file "Don't edit this, edit the master version."

That way years later, there would be no need to ask the original PR submitter (e.g., me) who by that time has lost all concept of what was going on... So sorry.