better type defs