[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl-AnyPerl] using DATA for testing



I filed a perlbug

	if I try
	  #!/usr/bin/perl

	  open (INPUT,"<&DATA");
	  while (<INPUT>) {
	    print;
	  }

	  __END__
	  apple
	  banana

	when I run this, nothing is printed. Can I not dup DATA?

    Can Perl be changed to allow dup'ing of the DATA filehandle?

It seems there actually is a bug here; someone on the Perl5porters list has
noted that if there is a large enough quantity of data following the
__END__
tag, that eventually someo of it is printed. But not all of it.
-- --
       |\      _,,,---,,_       Vicki Brown <vlb@cfcl.com>
 ZZZzz /,`.-'`'    -.  ;-;;,_   Journeyman Sourceror: Scripts & Philtres
      |,4-  ) )-,_. ,\ (  `'-'  P.O. Box 1269  San Bruno  CA  94066
     '---''(_/--'  `-'\_) http://www.cfcl.com/~vlb  http://www.macperl.com

==== Want to unsubscribe from this list?
==== Send mail with body "unsubscribe" to macperl-anyperl-request@macperl.org