NDepend Blog

Improve your .NET code quality with NDepend

Architecture of a .NET Application: 8 Case Studies

January 30, 2024 9 minutes read This recent question on Reddit’s Number of projects per solution led to interesting debates. Of course, the answer depends largely on the overall size...
NDepend January 30, 2024

C# ValueTuple Full Guide

January 18, 2024 9 minutes read In 2017 C# 7.0 introduced ValueTuple. This feature makes it convenient to handle lightweight data structures. Here is an example of relying on the...
NDepend January 18, 2024

WPF vs WinForms – Making the Right Decision in 2024

January 12, 2024 7 minutes read If you’re a developer faced with the decision of selecting between Windows Presentation Foundation (WPF) and Windows Forms (WinForms) commonly referred to as WPF...
NDepend January 12, 2024

A Guide to Code Coverage Tools for C# in 2024

January 11, 2024 3 minutes read In this post, we’ll go through 8 different .NET code coverage tools and list their features to help you make a decision. But first,...
Erik Dietrich January 11, 2024

.NET – 7 Decompiler Compared (2024)

January 10, 2024 9 minutes read Looking to reverse engineer or disassemble some .NET code? Then learning how to decompile .NET assemblies is an essential skill for any .NET developer...
NDepend January 10, 2024

C# Index and Range Operators Explained

December 11, 2023 3 minutes read In this post, we are demystifying both the C# index ^ and range .. operators most comprehensively. The index operator ^ Let’s start with...
NDepend December 11, 2023

Visual Studio Enterprise vs. Professional: Essential Differences in 2023

November 8, 2023 1 minutes read If you’re a .NET developer, chances are you’re using Visual Studio, the go-to product for developing .NET applications. However, with several versions available, it...
Erik Dietrich November 8, 2023

C# Async Await Explained

November 2, 2023 9 minutes read In 2012 C#5 was released. This version introduced two new keywords async and await. At that time CPU clock speed reached an upper limit...
NDepend November 2, 2023

Clean Architecture in ASP.NET Core

October 20, 2023 9 minutes read The Clean Architecture approach has gained significant popularity for the design and development of software applications, emphasizing key principles such as maintainability, testability, and...
NDepend October 20, 2023

Improve Visual Studio Build Performance

August 11, 2023 7 minutes read Time is your most precious asset and slow build is high in the list of developer’s productivity killers. With slow build the penalty is...
NDepend August 11, 2023

.NET Build Improvement: Stop Wasting Resources

February 4, 2023 5 minutes read I am working on .NET development full-time since 2002 and there is a point that still annoys me after all these years: the default...
NDepend February 4, 2023

C# 11 required members

November 15, 2022 3 minutes read C# 11 proposes the new keyword required that can apply to an instance property or an instance field declaration within a class, a record...
NDepend November 15, 2022

Visual Studio vs. Jetbrains Rider Performance

June 28, 2022 5 minutes read I work daily with Visual Studio since 1997 but still use Rider from time to time to keep up with progresses since we plan...
NDepend June 28, 2022

C# 11 static abstract members

June 14, 2022 5 minutes read C# 11 proposed interface members declared as static abstract. This is useful to handle both: Polymorphism at the type level, for example when abstracting...
NDepend June 14, 2022

WPF / Winforms UI Refactoring: A Case Study

May 11, 2022 4 minutes read WPF and Winforms are still so massively used that Microsoft fully supports those technologies in .NET Core, .NET 5, 6 , 7 and so...
NDepend May 11, 2022

How to collect return values from Parallel.ForEach?

January 26, 2022 1 minutes read Today I took 10 minutes to answer the 9 years old stackoverflow’s question: How do I collect return values from Parallel.ForEach? I though the...
NDepend January 26, 2022

Modern C# Hello World

November 23, 2021 6 minutes read With Visual Studio 2022 when you create a new console project based on .NET 6, the Hello World source code generated is now as...
NDepend November 23, 2021

Solution to Visual Studio 2022 messing up Visual Studio 2019

November 10, 2021 3 minutes read As all .NET developers I am quite excited by Visual Studio 2022 and .NET 6 going RTM. However I noticed that Visual Studio 2022...
NDepend November 10, 2021

Debugging a .NET App on Linux from Windows Visual Studio with WSL

September 15, 2021 6 minutes read NDepend analysis, reporting, API and Power-Tools will run on Linux and MacOS with the next version 2021.2. To achieve that, a major refactoring session...
NDepend September 15, 2021

Code Testability: A Case Study

September 1, 2021 2 minutes read [crayon-65dc4c7a84611885950627/] This method is untestable because its logic depends on NdpOperatingSystem.Kind which returns an OSPlatform object. Notice the usage of the attribute UncoverableByTest that...
NDepend September 1, 2021

3 productivity Resharper features missing in Visual Studio

August 10, 2021 5 minutes read Resharper is a great Visual Studio productivity extension but on the other hand it slows down significantly the IDE, especially when working with large...
NDepend August 10, 2021

Top 10 New .NET 6.0 API

July 7, 2021 5 minutes read .NET 6 introduces new handy APIs that will make our development journey easier. Let’s go through the top 10 new API in terms of...
NDepend July 7, 2021

How to Logically Name Embedded Resources in .csproj?

June 16, 2021 1 minutes read You can work with .NET for two decades and still discover some useful stuff.  One thing that bothered me till now is that an...
NDepend June 16, 2021

On replacing Thread.Abort() in .NET Core

May 19, 2021 3 minutes read Thread.Abort() is not supported in .NET 5 / .NET Core We are actually migrating the NDepend analysis and reporting to .NET 5 and figured...
NDepend May 19, 2021

Visual Studio 2022 64 bits: Elements of history

May 11, 2021 7 minutes read Finally after all these years of waiting Visual Studio 2022 will run in a 64 bits process on 64 bits machines! As a consequence...
NDepend May 11, 2021

Covariance and Contravariance in C# Explained

May 4, 2021 6 minutes read Introduction Covariance and contravariance allow more flexibility when dealing with C# class hierarchy. This article explains and demonstrates the concepts of Covariance and Contravariance...
NDepend May 4, 2021

6 Reasons Visual Studio Theme Affects Productivity

April 14, 2021 4 minutes read Themes can be fascinating. Humans are vulnerable to attachments. It could be anything – person, thing, color, food, etc. some people are attracted to...
NDepend April 14, 2021

Visual Studio IntelliCode : AI Assisted Coding

January 19, 2021 5 minutes read We are all amazed by recent progresses made possible thanks to Artificial Intelligence (AI). In 2017 Microsoft announced Visual Studio IntelliCode which used Machine...
NDepend January 19, 2021

How we quickly refactored with Resharper more than 23.000 calls to Debug.Assert() into more meaningful assertions

January 11, 2021 6 minutes read Since the NDepend inception more than 15 years ago, we stuffed our code with calls to Debug.Assert(). This results today in more than 23.000...
NDepend January 11, 2021

The proper usages of the keyword ‘static’ in C#

December 8, 2020 6 minutes read The keyword static is somewhat awkward in a pure Oriented-Object world. I would like to explain here what are the right usages of static I...
NDepend December 8, 2020