The first thing I did was to check how slicing and indexing works. If anyone else is curious it is explained here http://ocaml.xyz/chapter/slicing.html The syntax is quite verbose. Anyway to make it better with macros ? Coming from number crunching world makes me wish that the syntax for list and arrays in OCaml were swapped. On a different note, I hope Owl allows flexibility over memory layout in future. Inter-opera…
let a = x.%{ [|2; 3; 4|] }
x.%{ [|2; 3; 4|] }
might be simplified to: let a = x.%{ 2; 3; 4 }
x.%{ 2; 3; 4 }
It is possible to go further with ppxs(OCaml version of macros), but at a greater readability cost.