Endjin - Home

C# 8

This is part of a series of articles about faux amis in programming languages—constructs that can fool us through a misleading resemblance to one another: C# 8 surprising patterns (Introduction) C# faux amis 1: discards and underscores C# faux amis 2: tuple deconstruction and positional patterns (you are here) C# faux amis 3: variable declarations […]


C# faux amis 1: discards and underscores

by Ian Griffiths

This is the second in a series of articles: C# 8 surprising patterns (Introduction) C# faux amis 1: discards and underscores (you are here) C# faux amis 2: tuple deconstruction and positional patterns C# faux amis 3: variable declarations and type patterns In the introduction, I described the idea of faux amis in spoken languages […]


C# 8 surprising patterns

by Ian Griffiths

Recently, I made a surprising discovery. I had downloaded a preview of Visual Studio 2019 and was experimenting with some of the new language features in C# 8, when I discovered something: Switching between var and int can sometimes move type checks from compile-time to runtime. This shocked me. The experimental evidence (which I’ll get […]