One of the new language features in C# 7 is local functions. This feature lets you define functions within the scope of other functions. The main benefit of local functions is encapsulation and a secondary benefit is that they bring local variables into scope.
Although local functions appear simple, their interaction with other language features quickly leads to questions. I wondered …
Read More