develooper Front page | perl.beginners | Postings from March 2002

Half asleep and need some aware eyes...

Thread Next
From:
Nikola Janceski
Date:
March 5, 2002 14:18
Subject:
Half asleep and need some aware eyes...
Message ID:
1449413DA482D311B67000508B5A12F50592DE2A@nyexchange01.summithq.com
I am getting stuck... and I don't know what to do about this... And I am
half asleep. It has to be something stupid.

early in my code I populate %COOR with

push @{ $COOR{$file} }, $chgid;

Then later I try to use that info with:

foreach my $file (keys %NEW){
	while (my ($cfile, $ids) = each %COOR){
		if( grep $NEW{$file}[2] == $_, @{ $ids } ){   ## line 855
			$RELATION{$file} = $RELATION{$cfile};
			last;
			}
		}
	}

but the error I get is:
Not an ARRAY reference at ./depend.pl line 855.


What the heck am I doing wrong??? Isn't COOR a hash of an array? 

In debug COOR looks like:
  DB<2> x %COOR
0  'src/xxx.cc'
1  ARRAY(0x3ab8a0)
   0  49196
   1  48544
2  'lib/xxxx.x'
3  ARRAY(0x3171f0)
   0  48641
4  'lib/xxxx.w'
5  ARRAY(0x30e510)
   0  49542
6  'lib/xxxx.x'
7  ARRAY(0x3173f4)
   0  49542
8  'include/xxxx.h'
9  ARRAY(0x30e42c)
   0  49124


Delivery Queue
<http://www/reldist-bin/build/assign/listassign.cgi?reverse=on>

Nikola Janceski
Summit Systems, Inc.
212-896-3400

The only reason for time is so that everything doesn't happen at once.
-- Albert Einstein (1879-1955)  


----------------------------------------------------------------------------
--------------------
The views and opinions expressed in this email message are the sender's
own, and do not necessarily represent the views and opinions of Summit
Systems Inc.


Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About