Re: Bug 576610: FILLARRAY



>>>>> "Wolfgang" == Wolfgang Jenkner <wjenkner@inode.at> writes:

    Wolfgang> The patch below should fix this.  Here are some remarks.

    Wolfgang> 1) Note that $FILLARRAY won't care about the type of an array, i.e. it
    Wolfgang> will happily fill a maxima array of, say, type FLOAT with FIXNUMs.

    Wolfgang> (C1) array(xxx,float,2,3);
    Wolfgang> (D1) 				      xxx
    Wolfgang> (C2) array(yyy,fixnum,1,1);
    Wolfgang> (D2) 				      yyy
    Wolfgang> (C3) :lisp(symbol-plist '|$xxx|)
    Wolfgang> (ARRAY-MODE $FLOAT MPROPS (NIL ARRAY $xxx) ARRAY
    Wolfgang>  #2A((0.0 0.0 0.0 0.0) (0.0 0.0 0.0 0.0) (0.0 0.0 0.0 0.0)))
    Wolfgang> (C3) :lisp(symbol-plist '|$yyy|)
    Wolfgang> (ARRAY-MODE $FIXNUM MPROPS (NIL ARRAY $yyy) ARRAY #2A((0 0) (0 0)))
    Wolfgang> (C3) fillarray(xxx,yyy);
    Wolfgang> (D3) 				      xxx
    Wolfgang> (C4) :lisp(symbol-plist '|$xxx|)
    Wolfgang> (ARRAY-MODE $FLOAT MPROPS (NIL ARRAY $xxx) ARRAY
    Wolfgang>  #2A((0 0 0 0) (0 0 0 0) (0 0 0 0)))
    Wolfgang> (C4) 

I've applied your patch for this and things look better, at least for
the fft stuff.

However, I have a question.  With the patch applied, consider

(C2) array(zzz,2,3);

(D2) 				      zzz
(C3) :lisp(symbol-plist '|$zzz|)

(MPROPS (NIL ARRAY G1148))

This seems a little unexpected.  Since Lisp has arrays with
element-type T, I would have expected some more like what your xxx
array looks like.

What do you think?  This this be changed to match xxx?  I don't know
what impact such a change will have though.

Ray