C++ Logo

std-proposals

Advanced search

Re: [std-proposals] On the standardization of mp-units P3045R1

From: Thiago Macieira <thiago_at_[hidden]>
Date: Tue, 18 Jun 2024 18:02:59 -0700
On Tuesday 18 June 2024 10:06:09 GMT-7 Charles R Hogg via Std-Proposals wrote:
> A basic design principle for a units library is that the result of a
> computation shouldn't conjure up any units not mentioned in the inputs.

Why not? If I multiply an acceleration by mass, why should I not get newtons?
If I divide a charge by time, should I not get amperes?

PS: would this proposed API support a unit like ns/√km ?

-- 
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
  Principal Engineer - Intel DCAI Fleet Systems Engineering

Received on 2024-06-19 01:03:04