NDepend

Improve your .NET code quality with NDepend

Hungarian Notation for Fields in C#

If there is one topic that divides the C# developers community, it is the Hungarian notation for fields. In our team we rely on Hungarian notation for fields, not just...
Patrick Smacchia April 21, 2021

Is Artificial Intelligence Assisted Coding the Next Developer Productivity Silver Bullet?

The famous Fred Brooks paper “No Silver Bullet – Essence and Accident in Software Engineering“ published in 1987 stated that: “there is no single development, in either technology or management technique,...
Patrick Smacchia January 26, 2021

When your brain can’t handle the complexity: NDepend and PostSharp

The size and complexity of codebases have exploded in the last decade. What can you do when your codebase no longer fits your brain? In this article I’ll suggest two...
Patrick Smacchia November 2, 2020

Strategies to Catch Regression Bugs before Production: A Case Study

That’s quite a coincidence that a few days after promoting the joy of immutability in the post C#9 records: immutable classes we stumbled on a bug due to a mutable...
Patrick Smacchia October 19, 2020

.NET 5.0 App Trimming and Potential for Future Progress

In this article we will: go through the various ways to publish a .NET 5.0 application, play with .NET 5.0 app trimming to reduce the size of our deliverable use...
Patrick Smacchia September 28, 2020

Top 10 .NET 5.0 new APIs

When a new major .NET version hits Release Candidate, it is time to use the NDepend code review changes capabilities to browse which new APIs have been added. It is...
Patrick Smacchia September 21, 2020

Business Complexity vs. Implementation Complexity

It is good software design practice to make sure that methods can be entirely viewed in the code editor that typically shows 30 to 45 lines at a time. The...
Patrick Smacchia September 19, 2019

Static Analysis and Dependency Injection

For quite some years now, we (the NDepend team) got some demand about resolving Dependency Injection, see this page on our User Voices. Lately we’ve been considering such support carefully...
Patrick Smacchia September 3, 2019

SOLID Design: The Interface Segregation Principle (ISP)

After having covered The Open-Close Principle (OCP), The Liskov Substitution Principle (LSP) and the Single Responsibility Principle (SRP) let’s talk about the Interface Segregation Principle (ISP) which is the I...
Patrick Smacchia August 20, 2019

Are SOLID principles Cargo Cult?

My last post about SOLID Design: The Single Responsibility Principle (SRP) generated some discussion on reddit. The discussion originated from a remark considering SOLID principles as a Cargo Cult. Taking...
Patrick Smacchia August 13, 2019

Exploring .NET Core 3.0 new API

.NET Core 3.0 is representing a major step for the .NET community. It is interesting to analyze what’s new in the API directly from the compiled bits. In this post...
Patrick Smacchia February 21, 2019

Advanced Code Search : A Case Study

This morning I stumbled on a complex test to write. The need was to create and show a custom Form (written with Windows Form) that relies on the System.ComponentModel.BackgroundWorker to do...
Patrick Smacchia January 16, 2019

Log4net vs NLog: A Comparison of How They Affect Codebases

Ah, the old “versus” Google search.  Invariably, you’re in the research stage of some decision when you type this word into a search engine.  Probably not something like Coke vs...
Erik Dietrich June 12, 2018

The Singleton Design Pattern: Impact Quantified

This post has been about a month in the offing.  Back in August, I wrote about what the singleton pattern costs you.  This prompted a good bit of discussion, most...
Erik Dietrich October 26, 2017

Static analysis of .NET Core 2.0 applications

NDepend v2017.3 has just been released with major improvements. One of the most requested features, now available, is the support for analyzing .NET Core 2.0 and .NET Standard 2.0 projects. .NET...
Patrick Smacchia October 12, 2017

Understanding Cyclomatic Complexity

Wander the halls of an enterprise software outfit looking to improve, and you’ll hear certain things.  First and foremost, you’ll probably hear about unit test coverage.  But, beyond that, you’ll...
Erik Dietrich September 14, 2017

Understanding the Difference Between Static And Dynamic Code Analysis

I’m going to cover some relative basics today.  At least, they’re basics when it comes to differentiating between static and dynamic code analysis.  If you’re new to the software development...
Erik Dietrich August 31, 2017

The Role of Static Analysis in Testing

“What do you do?” In the United States, people ask this almost immediately upon meeting one another for the first time.  These days, I answer the question by saying that...
Erik Dietrich August 10, 2017

How Has Static Code Analysis Changed Through the Years?

Years ago, I found myself staring at about 10 lines of source code.  This code had me stymied, and I could feel the onset of a headache as I read...
Erik Dietrich August 3, 2017

Is Your Team Wrong About Your Codebase? Prove It. Visually.

I don’t think I’ll shock anyone by pointing out that you can find plenty of disagreements among software developers. Are singletons evil? What’s the best IDE? You can see this...
Erik Dietrich July 20, 2017

Code Quality Metrics: Separating the Signal from the Noise

Say you’re working in some software development shop and you find yourself concerned with code quality metrics.  Reverse engineering your team’s path to this point isn’t terribly hard because, in...
Erik Dietrich July 13, 2017

What is Static Analysis? An Explanation for Everyone

Static analysis, as a concept, seems to earn itself a certain reputation.  The general population may regard programming as a technocratic, geeky pursuit.  But inside the world of programmers, static...
Erik Dietrich June 29, 2017

How to Evaluate Your Static Analysis Process

I often get inquiries from clients and prospects about setting up and operationalizing static analysis.  This makes sense.  After all, we live in a world short on time and with...
Erik Dietrich April 27, 2017

How to Analyze a Static Analyzer

First things first.  I really wanted to call this post, “who will analyze the analyzer,” because I fancy myself clever.  This title would have mirrored the relatively famous Latin question...
Erik Dietrich March 30, 2017

Static Analysis Issue Management Gets a Boost

Years ago, I led a team of software developers.  We owned an eclectic portfolio of software real estate.  It included some Winforms, Webforms, MVC, and even a bit of WPF sprinkled...
Erik Dietrich March 23, 2017

Quality Gates with NDepend to Help You Fail Fast

I had this car once.  I loved the thing, but, before the end of its life, my wife and I had developed sort of a running joke about it.  Specifically,...
Erik Dietrich March 9, 2017

Adding Static Analysis to Your Team’s DNA

Stop me if this sounds familiar.  (Well, not literally.  I realize that asynchronous publication makes it hard for you to actually stop me as I type.  Indulge me the figure...
Erik Dietrich January 12, 2017

New Year’s Resolutions for Code Quality

Perhaps more than any other holiday I can think of, New Year’s Day has specific traditions.  With other holidays, they range all over the map.  While Christmas has trees, presents, rotund...
Erik Dietrich December 29, 2016

Concreteness: Entering the Zone of Pain

Years ago, when I first downloaded a trial of NDepend, I chuckled when I saw the “Abstractness vs. Instability” graph.  The concept itself does not amuse, obviously.  Rather, the labels...
Erik Dietrich November 10, 2016

Making Devs, Architects, and Managers Happy with the Static Analysis Tool

Organizations come to possess a static analysis tool in a variety of ways.  In some cases, management decides on some kind of quality initiative and buys the tool to make...
Erik Dietrich October 27, 2016