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

Package extensions #106

Open
aplavin opened this issue Dec 8, 2024 · 1 comment
Open

Package extensions #106

aplavin opened this issue Dec 8, 2024 · 1 comment

Comments

@aplavin
Copy link

aplavin commented Dec 8, 2024

This package defines rules for functions from LogExpFunctions, NaNMath, and SpecialFunctions packages, in addition to Base. Looking at https://github.com/JuliaDiff/DiffRules.jl/blob/master/src/rules.jl, their rules are pretty self-contained (*) and can easily be turned into package extensions to enable using DiffRules as a dependency in other lightweight packages.
Would you support and accept such a PR turning them into weakdeps?

(*) One exception: a SpecialFunctions function used in a NaNMath rule definition,

@define_diffrule NaNMath.lgamma(x) = :( SpecialFunctions.digamma($x) )
.

@devmotion
Copy link
Member

My impression from #90 was that the current design doesn't allow to define rules in extensions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants