Allow casting to function types.