Unexpected inconsistency in C# records

#567 – July 27, 2025

using with operator doesn't call the constructor

Unexpected inconsistency in records
8 minutes by Jon Skeet

In C# records, the with operator doesn't call the constructor when creating a new instance, but instead clones the original object and then modifies specified properties. This can lead to inconsistencies when records contain derived data that depends on constructor parameters. In this post John suggests several solutions to fix the problem.

How engineers at Nubank and Ramp spend more time on shipping features (vs drowning in their backlog)
sponsored by Devin AI

What do elite engineering teams at Ramp, Nubank, and Gumroad have in common? They're saving 10k+ hours monthly by delegating tedious work (bug triage, refactors, scoping, testing) to Devin so they can focus on hard problems and new features. Devin is a SWE agent built for real-world work. It analyzes your codebase to craft context-grounded plans before implementing and testing. Starting at $20.

The hidden cost of DateTime.Now — and what you should use instead
1 minute by Yaseer Arafat

Yaseer Arafat warns .NET developers about the dangers of using DateTime.Now in production code, particularly for time-sensitive operations like token validation. He explains that relying on system clocks can lead to problems due to clock drift between servers and time zone issues, potentially causing authentication failures and other unexpected behavior.

C# 14 extension members
10 minutes by Andrew Lock

Andrew takes a look at the C#14 extension members feature which is available in the latest .NET 10 previews. He describes what the feature is, how it extends the existing capabilities of extension methods, and how to create extension members in .NET 10.

Fixing C# type pattern-matching
6 minutes by Aleksey Maltsev

Are you looking for ways to make your code more robust, maintainable, and less prone to runtime errors? Aleksey is going to explore how to substitute type pattern matching in C# with the Visitors pattern.

The OWASP Top 10 for .NET developers
27 minutes by Sudhir Mangla

Sudhir's comprehensive guide helps .NET architects incorporate security into application design from the start rather than as an afterthought. He examines the OWASP Top 10 security risks specifically for .NET applications, providing practical code examples and architectural strategies to mitigate each vulnerability while emphasizing that security must be treated as a continuous process woven throughout the software development lifecycle.

And the most popular article from the last issue was:

newsletters