I have this code

           val array3d = Array.make[double](R);
                
                for (j = 0; j < 10; j++)
                        for (k = 0; k<edge_size; k++)
                                for (l = 0; l < edge_size; l++){
                                        array3d.set(0.0, 1,j,(k+l*edge_size));
                                }

returning this compiler error

Method set(T, x10.lang.Int, x10.lang.Int, x10.lang.Int) 
{x10 
.lang 
.Array 
#this.x10.lang.Array#dist.x10.lang.Dist#region.x10.lang.Region#rank==3} 
[] in x10.lang.Array[x10.lang.Double] cannot be called with arguments  
(x10.lang.Double{self==0.0}, x10.lang.Int{self==1}, x10.lang.Int,  
x10.lang.Long); Call invalid; calling environment does not entail the  
method guard.

Can someone tell me what the method guard is and how to use it? I'm  
looking at this in Array.x10:

     public abstract safe def apply(pt: Point(rank)): T;
     public abstract safe def apply(i0: int) {rank==1}: T;
     public abstract safe def apply(i0: int, i1: int) {rank==2}: T;
     public abstract safe def apply(i0: int, i1: int, i2: int)  
{rank==3}: T;
     public abstract safe def apply(i0: int, i1: int, i2: int, i3:int)  
{rank==4}: T;



Thanks.

Jim

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
X10-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/x10-users

Reply via email to