lcc, lip, toolbox: Improve type system