Also he probably could have figured it out on his own if he had used strict et al.
No. That's the point of my rant. You didn't even bother to try, did you?
#!/usr/bin/perl use strict; use warnings; use diagnostics; my @Line; COPY: use File::Copy; copy("$Line[0]","$Line[1]") or die "Copy failed: $!"; __END__ syntax error at f line 10, near "use File::Copy" Execution of f aborted due to compilation errors (#1) (F) Probably means you had a syntax error. Common reasons include +: A keyword is misspelled. A semicolon is missing. A comma is missing. An opening or closing parenthesis is missing. An opening or closing brace is missing. A closing quote is missing. Often there will be another error message associated with the synt +ax error giving more information. (Sometimes it helps to turn on -w. +) The error message itself often tells you where it was in the line +when it decided to give up. Sometimes the actual error is several toke +ns before this, because Perl is good at understanding random input. Occasionally the line number may be misleading, and once in a blue + moon the only way to figure out what's triggering the error is to call perl -c repeatedly, chopping away half the program each time to se +e if the error went away. Sort of the cybernetic version of S<20 questions>. Uncaught exception from user code: syntax error at f line 10, near "use File::Copy" Execution of f aborted due to compilation errors. at f line 13
strict, warnings and diagnostics turned on. And it didn't tell anything the OP didn't know of.

I thought he could use the advice.
But there are a million more advices to give - each of them having as much relevance to the OP's problem as the advice you gave. You omitted those.
Also why rant anonomyously? Be proud of your rants, take credit for them.
Oh, I am. And don't get the impression you aren't as anonymous as I am. Or do you really think that your description of "Super Genius & XPW" and the image of the monster Frankenstein created you put on your user page identify who you are? Or perhaps it's the "Brother Crossbow of Engaged Distraction" that makes you stand out from the other nerds?

In reply to Re^4: File::Copy a bug? by Anonymous Monk
in thread File::Copy a bug? by moked

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.