Add datatypes support

WIP, do not merge