Closed AlekseyTs closed 1 year ago
I've added more to the test plan. I'll go through and check things off on Monday.
Just tried the feature out, and I think it would be nice to have a more specific error when a user types:
public static int operator unchecked +(int left, int right);
// ~~~~~~~~~
Saying that unchecked operators do not require the modifier. Currently, multiple unrelated errors are being shown:
@AlFasGD This issue is not meant for tracking and discussing different aspects of the feature. If you would like to report a bug or suggestion, please, open a dedicated issue.
Feature branch - https://github.com/dotnet/roslyn/tree/features/CheckedUserDefinedOperators Specification - https://github.com/dotnet/csharplang/blob/main/proposals/csharp-11.0/checked-user-defined-operators.md Proposal: https://github.com/dotnet/csharplang/issues/4665
Compiler
Compiler Public APIs
Syntax
checked
onchecked
checked
in crefunchecked
(issue)Semantics
checked
expression context calls operatorchecked
method context calls operator-checked
compiler switch calls operatorunchecked
contexts,checked
operators are ignored during lookupchecked
contexts,unchecked
operators (regular operators that have a pairedchecked
operator) are ignored during lookupchecked
contexts, regular operators that are notunchecked
are included during lookupchecked
conversions inchecked
contextsProductivity
checked
keyword classificationchecked
keyword completion https://github.com/dotnet/roslyn/pull/60183checked
keyword on the declaration goes to the doc page forchecked
keyword.Docs
checked
keyword in declarations, depending on structure of the docs. Right now it goes to a generalchecked
keyword topic.