[SR-13152] Add diagnostic for derivative registration instance/static method mismatch #54274
Labels
AutoDiff
compiler
The Swift compiler in itself
diagnostics QoI
Bug: Diagnostics Quality of Implementation
Additional Detail from JIRA
md5: 65c5d8981325b3779edb5f7276072344
Parent-Task:
@derivative
and@transpose
type-checking diagnostic improvementsis duplicated by:
Issue Description:
Example using
@differentiable
attribute:Example using
@derivative
attribute:These diagnostics are technically correct, but aren't very understandable or actionable.
We could detect instance/static method mismatches for derivative registration and produce a more specific diagnostic ("did you mean to make 'vjpInit' a static function?").
Example:
The text was updated successfully, but these errors were encountered: