TickDuration deprecation

captaindet 2krnk at gmx.net
Thu Nov 23 01:05:32 UTC 2017


On 2017-11-23 12:55, sarn wrote:
> +1 to using integer arithmetic for the low-level time APIs.

and nobody is advocating to change this.

it is about being able to use such result (duration) with non-time 
focused libraries/functions (eg. general maths/stats) expecting doubles.

if this is not possible in an obvious/standard way (being to!... in D) 
this is the very moment all potential python-to-D converts will run away 
screaming. putting the solution for this common problem only in the docs 
will not appease them either but rather make them mock D.

i still don't understand how problems could arise from a supported 
one-way conversion -> double. of course, double -> time or duration is 
something different and i tend to agree that this should be left for the 
user to implement.

i for my part could live with just one supported to!double conversion 
resulting in seconds. (i guess i am biased as i prefer to use SI units 
only for all my calculations.)

/det


More information about the Digitalmars-d mailing list