Type Based Optimization

Typed based optimizations are optimizations that can be performed based on information from the type inferencer, e.g.

Function call evaluation using type information

a = [ 1 2 ; 3 4 ]
b = ismatrix(a)

The type inferencer can determine that a is of type matrix. Therefore, we can rewrite this to,

a = [ 1 2 ; 3 4 ]
b = true