[Breaking] Allow value and partials to have distinct types #463
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is one of those love/hate changes...in brief, it allows one to set up alternate rules for how the "epsilon" component of dual numbers behaves by changing the type of
Dual
fromto
Happy to discuss motivations for this change at my poster at JuliaCon (we should leave this open at least until then).
It also throws in a commit to change from
one
tooneunit
in places where IMO the latter is technically the correct choice.IMO, someone with permissions should tag this "breaking change" (note the version bump to 0.11). From the very minor modifications to the tests, it's reasonable to hope that this is non-breaking in "ordinary" usage, but any package that explicitly constructs a
Dual{Tag,V,N}
directly (by type) will be effectively broken. I guess it's a little bit ambiguous whether that counts as breaking, sinceDual
isn't an exported type.