C# Language Version and Feature Policy
AIC Standard
Production .NET 10 projects use C# 14.
C# 15 features may be evaluated in .NET 11 preview projects but must not enter production code unless the project is approved for that runtime and language version.
General Language Rules
Use modern C# features when they improve clarity, safety or performance.
Do not use language features simply because they are new.
Recommended Features
AIC encourages:
nullable reference types
records for immutable DTOs and value-like data
pattern matching where it improves clarity
requiredmembers where appropriatecollection expressions where supported and clear
primary constructors where they reduce boilerplate without hiding dependencies
file-scoped namespaces
implicit usings where project-wide consistency is maintained
usingdeclarations for deterministic disposalswitch expressions for clear mappings
Features Requiring Care
Use carefully:
reflection
dynamic
source generators
unsafe code
custom implicit conversions
operator overloads
expression tree heavy code
Native AOT-specific optimisations
global state
Forbidden or Restricted Practices
Avoid or prohibit:
async voidexcept event handlersTask.Resultand.Wait()in asynchronous flowsswallowing exceptions without logging or compensating action
using
DateTime.Nowfor persisted or cross-system timebusiness logic in property getters
mutable public static state
service locator patterns
public fields on domain objects
stringly-typed security decisions
Example: Clear Modern C#
Feature Adoption Rule
Before adopting a new C# feature across a project, consider:
Does every developer understand it?
Does ReSharper and the CI analyzer support it?
Does it work with the target framework?
Does it improve readability?
Does it affect serialization, testing or tooling?
Is there a migration risk?
Record project-wide language feature decisions in an ADR where they materially affect style.
Was this helpful?

