Tag: C# 7

Be careful in using the C# null conditional operators in tests

Dangerous use of null C# conditional operator in test

Few days ago, I come across to a bunch of tests that were using the null conditional operator in the wrong way and I think it is worth sharing it. Have a look at this code and how I fixed it.What’s the problem with the original code?  When result is null, the test pass even if …

Continue reading

Permanent link to this article: https://www.productivecsharp.com/2018/01/careful-using-c-null-conditional-operators-tests/

Practical C# – How to configure the C# language version in Visual Studio 2017 projects

Productive C# Logo

New video from the Practical C# Video series to learn how to configure the C# language version used. How to configure your project C# language version Learn how to configure your C# Visual Studio 2017 (Update 3) project to compile against a specific version of the C# compiler or the latest release. Do you like these …

Continue reading

Permanent link to this article: https://www.productivecsharp.com/2017/08/practical-csharp-language-version/

Practical C# – Default Expressions in C# 7.1

Productive C# Logo

New video from the Practical C# Video series. Explore the new Default Expressions feature in C# 7.1 in a simple and practical way. Default Expressions in C# 7.1 (Preview) Learn how to use the new Default Expressions feature in C# 7.1.   Do you like these videos? Subscribe here Previous videos

Permanent link to this article: https://www.productivecsharp.com/2017/07/practical-csharp-default-expressions/

Practical C# – Async Main in C# 7.1

Productive C# Logo

New video from the Practical C# Video series. Explore the new Async Main feature in C# 7.1 in a simple and practical way. Async Main in C# 7.1 (Preview) Learn how to use the new Async Main feature in C# 7.1. You can use async in the entry point of your console application using Visual Studio …

Continue reading

Permanent link to this article: https://www.productivecsharp.com/2017/07/async-main/

All you need to know to master C# 7

Productive C# Logo

This is a collection of practical videos to learn how to use the new C# 7 features. Generalized Async Return Types (ValueTask) in C# 7 Learn how to use the generalized async return type feature (more specifically ValueTask) in order to improve the performance of your application by reducing memory pressure. ValueTask is particularly useful …

Continue reading

Permanent link to this article: https://www.productivecsharp.com/2017/07/master-csharp7/

Practical C# – Generalized Async Return Types in C# 7

Productive C# Logo

New video from the Practical C# Video series. Explore C# in a simple and practical way. Generalized Async Return Types (ValueTask) Learn how to use the generalized async return type feature in C# 7 (more specifically ValueTask) in order to improve the performance of you application by reducing memory pressure. ValueTask is particularly useful when you repeatedly …

Continue reading

Permanent link to this article: https://www.productivecsharp.com/2017/07/practical-csharp-generalized-async-return-types/

Practical C# – Expression Bodied Members in C# 7

Productive C# Logo

New video from the Practical C# Video series. Explore C# in a simple and practical way. Expression Bodied Members in C# 7 Learn how you can make you classes extremely more compact using expression bodied members in C# 7. Do you like these videos? Subscribe here Previous videos

Permanent link to this article: https://www.productivecsharp.com/2017/07/practical-csharp-expression-bodied-members/

>