Releases: mech-lang/mech
Releases · mech-lang/mech
v0.2.17-beta
Numbers default to f64
The default numeric type has been switched to f64.
Set Value
-- scalar
x := 1.23;
x = 4.56;
-- row vector
x := [6,2]
x[1] = 4
Full Changelog: v0.2.16-beta...v0.2.17-beta
v0.2.16-beta
Full Changelog: v0.2-beta...v0.2.16-beta
v0.2.15-beta
Strengthened tests.
Full Changelog: v0.2.14-beta...v0.2.15-beta
v0.2.14-beta
Variable Assign
You can use the =
operator to assign values to variables now. Only works for scalars so far.
x := 1.23;
x = 4.56;
Full Changelog: v0.2.13-beta...v0.2.14-beta
v0.2.13-beta
Enums
<foo> := `A | `B
x<foo> := `A -- Works!
y<foo> := `C -- Causes an error
v0.2.12-beta
Added enum definitions:
<foo> := A | B | C;
They don't do much yet.
Full Changelog: v0.2.11-beta...v0.2.12-beta
v0.2.11-beta
Full Changelog: v0.2.10-beta...v0.2.11-beta
v0.2.10-beta
Define Kinds
<foo> := <i64>
x<foo> := 123
More Number Literals
0b10101 -- bin
0x123abc -- hex
0o1234 -- oct
0d1234 -- dec
Full Changelog: v0.2.9-beta...v0.2.10-beta
v0.2.9-beta
v0.2.8-beta
Column dot select
x := { x<i64> y<i8>|
1 2
3 4
5 6
7 8 };
x.y
Table swizzle
x := { x<i64> y<u8>|
1 2
4 5 };
x.x,x,y
Logical indexing
ix := [false, false, true]';
x := [1 2 3
4 5 6
7 8 9];
x[:,ix]
x[[1,2,3,3],ix]
x[ix,ix]
Full Changelog: v0.2.7-beta...v0.2.8-beta