Archiv des Autors: oliverfunke

Pattern Matching in C# 7

Patterns are used to test whether a value matches a specific expectation and if it matches patterns allow to extract information from the value. You already create such pattern matchings by writing if and switch statements. With these statements you … Weiterlesen

Veröffentlicht unter .NET, C# | Kommentar hinterlassen

C++17: initializers in if-statement and switch-statement

With C++17 it is possible to initialize a variable inside an if-statement and a switch-statement. We already know and use this concept in the for-statement. To be honest: I don’t like this feature. Within this article I want to introduce … Weiterlesen

Veröffentlicht unter C++ | Kommentar hinterlassen

Name hiding in inheritance

The C++ name hiding rules for variables are well known by software developers. In contrast, name hiding in inheritance sometimes leads to issues although it follows the same rules. Such issues are therefore not a result of the rules but … Weiterlesen

Veröffentlicht unter C++ | Kommentar hinterlassen

Expression Bodied Members in C# 7

The concept of Expression Bodied Members (EBM) was introduced with C# 6 and as it becomes popular, many enhancements were added with C# 7. Within this article I want to give you the full picture of this feature so I … Weiterlesen

Veröffentlicht unter .NET, C# | Kommentar hinterlassen

C# Array indexer vs. List indexer

The C# CLR contains a lot of nice collection classes. They are optimized for their individual use case. But from a common perspective they all have the same behavior we expect from a collection. But there is one exception from … Weiterlesen

Veröffentlicht unter .NET, C# | Kommentar hinterlassen

Object Instance Creation

Whenever you write an application in C++ you will create a lot of object instances. So, this is a base development task. C++ offers several ways to initialize variables. These are not just syntactical variations for the same task. The … Weiterlesen

Veröffentlicht unter C++ | Kommentar hinterlassen

ctor types in C++

In C++ you will find several ways to initialize an object instance. For example, think about a class “MyClass” which can be constructed with a parameter. The object initialization can be done in several ways: MyClass x{y}; MyClass x(y); MyClass … Weiterlesen

Veröffentlicht unter C++ | Kommentar hinterlassen