Is it possible to infer a template's return type from what it's assigned to? If not is this a difficult or worthless feature to add?

OUT fun(IN, OUT)(IN value) {
    return value.to!OUT;
}

void main() {
    float a = 5.0;
    int b = fun(a);
}

Reply via email to