Hi,

Does anyone have any idea why this works perfectly:
while(<FIN>) {
  print $parser->record($_);
}

but the following fails to parse exactly the same input:

while(my $rec = <FIN>) {
  print $parser->record($rec);
}


The latter throws the following warnings:
Use of uninitialized value in index at 
/usr/local/lib/perl5/site_perl/5.8.0/Parse/RecDescent.pm line 2979, <GEN0> line 67.
Use of uninitialized value in index at 
/usr/local/lib/perl5/site_perl/5.8.0/Parse/RecDescent.pm line 2979, <GEN0> line 67.
Use of uninitialized value in length at 
/usr/local/lib/perl5/site_perl/5.8.0/Parse/RecDescent.pm line 2734, <GEN0> line 67.
Use of uninitialized value in substitution (s///) at (eval 80) line 2207, <GEN0> line 
67.
Use of uninitialized value in substitution (s///) at (eval 80) line 2207, <GEN0> line 
67.

This would perhaps suggest that the input is different but it's definitely 
not. The same warnings are thrown if I read the same input data from a 
socket-server source.

Apart from this weirdness, what a fantastic tool Parse::RecDescent is!

Thanks in advance,
R.


-- 
+---------------------------------------------------------------+
 Roger Michael Pettett           Email: [EMAIL PROTECTED]
 Project Leader (Web Systems),   Web: http://www.sanger.ac.uk/
 The Sanger Institute                 http://www.yourgenome.org/
 Wellcome Trust Genome Campus         http://www.ensembl.org/
 Hinxton                       
 Cambridge CB10 1SA
+---------------------------------------------------------------+

Reply via email to