[Date Prev][Date Next][Thread Prev][Thread Next]
[Search]
[Date Index]
[Thread Index]
Re: [MacPerl] unknown error question -- used only once --
Robert,
The particular error is caused by your using the variable
$holdingThing
exactly one time. If you think you used the same variable
somewhere else, one or the other is a typo or out of scope.
If want to use it just once and hate the message, just do something
above the "real" use like:
$holdingThing = undef;
and, since you've used the same variable in the same scope more than
once, the compiler thinks you know what your doing. :-)
Of course, one should declare all variables one doesn't need to be
global with the (Perl5) 'my' statement so they have restricted scope.
-- Larry
At 4:38 PM 06/09/1999, Robert Pollard wrote:
>Hey guys,
>
>Could anyone tell me why the following code produces the following
>error:
>
>CODE:
>#! perl -w
>
>$holdingThing = 'Backup Folder';
>
>ERROR:
># Name "main::holdingThing" used only once: possible typo.
>File 'Untitled #3'; Line 3
--
Regards, Larry F. Allen-Tonar (larryat@cts.com) +1 760/746-6464 (voice)
Principal Designer +1 760/746-0766 (FAX,
P.O. Box 463072 upon request)
Escondido, CA 92046-3072
===== Want to unsubscribe from this list?
===== Send mail with body "unsubscribe" to macperl-request@macperl.org