lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


2011/4/18 Mike Pall <mikelu-1104@mike.de>:
> I guess he wants to e.g. multiply a matrix with either a number, a
> complex number or another matrix. And all of that from the same
> __mul metamethod. Currently there's no easy way to distinguish the
> five cases: mat*mat, mat*n, n*mat, mat*c, c*mat.

Yes, this is actually what I meant!

Actually there are 8 cases because matrices can be both real or complex.

-- 
Francesco