Skip to content
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

[SR-13167] Parse: add parsing/syntax support for @differentiable(default, ...) #55609

Open
dan-zheng opened this issue Jul 7, 2020 · 1 comment
Labels
compiler The Swift compiler in itself

Comments

@dan-zheng
Copy link
Collaborator

Previous ID SR-13167
Radar rdar://problem/69987999
Original Reporter @dan-zheng
Type Sub-task
Additional Detail from JIRA
Votes 0
Component/s Compiler
Labels Sub-task
Assignee None
Priority Medium

md5: dc508f6543b2cdff61b1f36c59bd25d9

Parent-Task:

  • SR-13166 Default derivative implementations for protocol requirements

Issue Description:

See relevant section from the differentiable programming manifesto: https://github.com/apple/swift/blob/master/docs/DifferentiableProgramming.md#default-derivatives-and-transposes.

The optional "default" component should appear after the optional "linear" component and before the optional "wrt:" clause.

The following ~fully elaborated @differentiable attribute should parse and pass syntax testing (but doesn't type-check).

@differentiable(linear, default, wrt: (x, y) where T: FloatingPoint)
func foo<T>(_ x: T, _ y: T) -> T {}
@rxwei
Copy link
Member

rxwei commented Oct 6, 2020

@swift-ci create

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compiler The Swift compiler in itself
Projects
None yet
Development

No branches or pull requests

2 participants