Hacker News new | ask | show | jobs
by TTPrograms 1663 days ago
I've been investigating Julia AD recently - really hoping for arbitrary code diff, but nothing really works right now.

How broad will Diffractor's support of the language be? E.g. will it support mutation / exceptions / recursion?

1 comments

Mutation is tricky, because basically the only way to do it sanely is to copy all data into the residual, but since most arrays aren't actually mutated, that's extremely wasteful. I've been hoping to address this by changing mutability in the language more generally (e.g. https://github.com/JuliaLang/julia/pull/42465) to make immutable arrays the default at which point there wouldn't be a penalty anymore. I've had request to do the mutable copying optionally, but it's a bit tricky, because it needs rule system integration and the rule system currently doesn't reason about mutation.

As for exceptions and recursion, shouldn't be a problem, just needs to be implemented.

Thanks for the reply!