Problem with using std.math: abs and std.complex: abs at the same time

berni someone at something.org
Thu Sep 19 10:25:01 UTC 2019


On Thursday, 19 September 2019 at 07:26:17 UTC, Simen Kjærås 
wrote:
> That does indeed fail to compile, and there's no easy way to 
> introduce the module-level abs() function to the scope. Again 
> though, MergeOverloads to the rescue:

I'm not sure, if MergeOverloads will be accepted into std/math.d. 
Meanwhile I've created a pull request (#7187), that does not 
handle complex numbers although the algorithm would be identical. 
Maybe handling complex numbers in math.d can be added later (or 
maybe it's better to put this in std/complex.d anyway, but then 
code duplication would be necessary).


More information about the Digitalmars-d-learn mailing list