I've been learning about rust's generic system and constant evaluation lately, so I wrote this library to work on it. (While implementing a brainfuck with a type system might be more academic, I would have preferred to write something more practical.)
Unlike uom
, ucsi
expresses a type using what I call a unit table, so the user can easily create any type to participate in integration and checking.
Would like guidance on:
- Regarding unit expressions: currently derived units do not participate in data operations because
const fn
cannot yet (in stable rust) be defined in traits; - About pure data: using
PureValue
to include pure data makes the result of the type of operation difficult to express; - On type-checking results: currently
ucsi
relies onpanic
when evaluating trait's associated constants to indicate a type-checking failure, but this could not take advantage of the IDE's derivation.