Skip to content

[AutoDiff upstream] Update @differentiable syntax. #28211

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

Merged
merged 1 commit into from
Nov 12, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 4 additions & 8 deletions utils/gyb_syntax_support/AttributeNodes.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@
# generic-where-clause?
Node('DifferentiableAttributeArguments', kind='Syntax',
description='''
The arguments for the `@differentiable` attribute: an optional \
The arguments for the `@differentiable` attribute: an optional
differentiation parameter list and associated functions.
''',
children=[
Expand All @@ -219,10 +219,6 @@
The comma following the differentiation parameters clause,
if it exists.
''', is_optional=True),
Child('MaybePrimal', kind='DifferentiableAttributeFuncSpecifier',
is_optional=True),
Child('MaybeAdjoint', kind='DifferentiableAttributeFuncSpecifier',
is_optional=True),
Child('MaybeJVP', kind='DifferentiableAttributeFuncSpecifier',
is_optional=True),
Child('MaybeVJP', kind='DifferentiableAttributeFuncSpecifier',
Expand Down Expand Up @@ -266,7 +262,7 @@
# differentiation-param -> ('self' | identifer) ','?
Node('DifferentiationParam', kind='Syntax',
description='''
A differentiation parameter: either the "self" identifier or a \
A differentiation parameter: either the "self" identifier or a
function parameter name.
''',
traits=['WithTrailingComma'],
Expand All @@ -283,7 +279,7 @@
# ('jvp' | 'vjp') ':' func-decl-name ','?
Node('DifferentiableAttributeFuncSpecifier', kind='Syntax',
description='''
A function specifier, consisting of an identifier, colon, and a \
A function specifier, consisting of an identifier, colon, and a
function declaration name (e.g. `vjp: foo(_:_:)`).
''',
traits=['WithTrailingComma'],
Expand Down Expand Up @@ -313,7 +309,7 @@
]),
Child('Arguments', kind='DeclNameArguments',
is_optional=True, description='''
The argument labels of the referenced function, optionally \
The argument labels of the referenced function, optionally
specified.
'''),
]),
Expand Down