quil-lang / magicl

Matrix Algebra proGrams In Common Lisp.
BSD 3-Clause "New" or "Revised" License
238 stars 44 forks source link

Bug fix, specified type. #186

Closed anranyicheng closed 1 year ago

anranyicheng commented 1 year ago

Hi, when I specified type for vector and tensor, error:

MAGICL> (from-list '(1 2 3 4 5 6) '(6) :type 'double-float)

The value 1 is not of type DOUBLE-FLOAT when setting an element of (ARRAY DOUBLE-FLOAT) [Condition of type TYPE-ERROR]

after fix:

MAGICL> (from-list '(1 2 3 4 5 6) '(6) :type 'double-float)

<VECTOR/DOUBLE-FLOAT (6):

1.000 2.000 3.000 4.000 5.000 6.000>

best wishes!

anranyicheng commented 1 year ago

Fix.

stylewarning commented 1 year ago

Fix.

There are still tab characters in the file. For example, before the #:sum line, there are some tabs and spaces. In Emacs you can add

(setq indent-tabs-mode nil)

to your .emacs, and in the files do C-x h M-x untabify.

These are great changes I'd love to merge, I just don't want code formatting/style to slip.

anranyicheng commented 1 year ago

I re-cloned the warehouse, maybe my own configuration is not the same, I did not find the difference, if you want, please modify it according to your format preference, thank you