News for hackers. Stuff that matters.
Re:Typedefs by dan-robertson on Wednesday November 04, 2020 @06:53PM (#24994326)
No. Units is about dimensional analysis and unit conversions (eg 1 inch = 2.54cm) but this is about defying algebraic data types (eg a scheme is http or https; a host name is a non-empty list of strings; a uri is a scheme and a host name and a path and a query and an anchor)
Re:Typedefs by wires on Thursday November 05, 2020 @08:53AM (#24998192)
Exactly. We are talking to some people at NIST about a categorical way to do units, which we hope to add to typedefs. I don't think any of the research around this is published yet
Re:Typedefs by chrisweekly on Wednesday November 04, 2020 @10:54PM (#24995522)
defying -> defining

(v good comment/answer)