Skip to content

Guard default RevocableProxy instances with a clear exception - #2679

Merged
lahma merged 1 commit into
sebastienros:mainfrom
lahma:proxy-revocable-guard
Jul 13, 2026
Merged

Guard default RevocableProxy instances with a clear exception#2679
lahma merged 1 commit into
sebastienros:mainfrom
lahma:proxy-revocable-guard

Conversation

@lahma

@lahma lahma commented Jul 13, 2026

Copy link
Copy Markdown
Collaborator

Small follow-up to #2678: default(RevocableProxy) (an uninitialized struct someone stored in a field or default-constructed) threw NullReferenceException from both Proxy and Revoke(). Both now throw InvalidOperationException with a message pointing to Engine.Advanced.CreateRevocableProxy.

🤖 Generated with Claude Code

https://claude.ai/code/session_01EsHuKuE4UihKZp5HYapDHE

default(RevocableProxy) threw NullReferenceException from Proxy and
Revoke(). Both members now throw InvalidOperationException pointing to
Engine.Advanced.CreateRevocableProxy as the way to obtain instances.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EsHuKuE4UihKZp5HYapDHE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant