Type inference is a common feature among mainstream programming languages. The functional ones, like ML and Haskell, are pioneers in exploring this programming paradigm where the declaration of a variable or a function may omit a type annotation. Today, even classic imperative languages such as C++ offer, to a certain extent, a kind of type inference.
C# is not an exception to the ever-increasing popularity of inference-enabled languages: since C# 3.0, developers may declare implicitly typed variables with the
var keyword (in C++ 11, a similar feature was introduced — re-targeting the then-existing
auto keyword). …
I write about topics in the field of programming languages: e.g., type theory, formal methods, compiler construction, static analysis, and application security.