Our great sponsors
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
-
Roslyn
The Roslyn .NET compiler provides C# and Visual Basic languages with rich code analysis APIs.
https://github.com/dotnet/csharplang/issues/7009
[Proposal]: Interceptors #7009
> An interceptor is a method which can declaratively substitute a call to itself instead of a call to an interceptable method at compile time. This substitution occurs by having the interceptor declare the source locations of the calls that it intercepts. This provides a limited facility to change the semantics of existing code by adding new code to a compilation (e.g. in a source generator).
https://github.com/dotnet/roslyn/blob/main/docs/features/int...
Without interceptors, source generators can only add new code, but cannot modify any existing code. Interceptors enable method call substitutions.