May 09, 2021
https://issues.dlang.org/show_bug.cgi?id=21909

          Issue ID: 21909
           Summary: Scope-ness of parameters of function templates should
                    be inferred
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: dmd
          Assignee: nobody@puremagic.com
          Reporter: per.nordlow@gmail.com

Typically usage case is `arg` in

auto apply(alias fun, T)(T arg) {
    return fun(arg);
}

Another example is parameters of std.format.format(), std.stdio.write(), and
std.stdio.writeln().

--