Keno / SIUnits.jl

Efficient unit-checked computation
Other
70 stars 26 forks source link

* associativity can break #21

Open jiahao opened 10 years ago

jiahao commented 10 years ago
In [1]: using SIUnits
type a; x; end
*(A::a, c::Real)=A.x*c
A=a(1)
A*1Meter*Second

Out[1]: no method *(a, SIQuantity{Int64,1,0,0,0,0,0,0})
while loading In[3], in expression starting on line 1
 in * at operators.jl:82

In[2]: A*1*Meter*Second
Out[2]: 1 m s