Type mapping stuff.