-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Constructor decorated with the JsonConstructor attribute should be able to be non-public #38327
Comments
Removing label as this is not proposing new API surface. |
We want to hold off on doing this until the ramifications to the ongoing JSON code generation efforts are well understood - https://github.com/dotnet/runtimelab/tree/JsonCodeGen. |
The last link does not exist. I believe it should be https://github.com/dotnet/runtimelab/tree/feature/JsonCodeGen. |
Merging this into #31511 which considers support for non-public members in general, not just ctors. |
In general, a constructor decorated with the [JsonConstructor] attribute should be able to be a non-public constructor.
This would address cases where there is a special internal constructor that is solely used for json deserializing and that should not be called from user code.
Category: Design
The text was updated successfully, but these errors were encountered: