On 11/05/2011 02:00 AM, Uri Guttman wrote:
> there was no actual error anywhere in his code.
Good. :-)
that was a very long post that missed the actual issue. ... he just printed $!
which happens to have some value in it (and all $! values are some error
text/number!).
Agreed. I was trying to figure out a way to make readline set $!, but
ended up with a sloppy mess that, upon further inspection, fails to save
$! after calling readline.
> <major snip>
also posting large chunks of the perldocs isn't too useful. post
appropriate snippets or refer to the docs instead.
1. http://en.wikiquote.org/wiki/Chinese_proverbs
授人以魚不如授人以漁(授人以鱼不如授人以渔)。(pinyin: Shòu rén yǐ yú
bùrú shòu rén yǐ yú)
* Literally: Teach a man to take a fish is not equal to teach a man
how to fish.
* Meaning: Give a man a fish and you feed him for a day. Teach a
man to fish and you feed him for a lifetime.
2. I wanted to demonstrate my problem-solving process.
3. Putting the perldoc output into the post makes for convenient reading.
4. 100 lines of documentation isn't too bad.
5. "RTFM print, $!, and readline" is curt, and inadequate for a newbie.
6. Taking small pieces out of context can be misleading.
David
--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/