Skip to content

Parse and format Quantities - #63

Merged
istathar merged 8 commits into
technique-lang:mainfrom
istathar:parse-quantity
Aug 8, 2025
Merged

Parse and format Quantities#63
istathar merged 8 commits into
technique-lang:mainfrom
istathar:parse-quantity

Conversation

@istathar

@istathar istathar commented Aug 7, 2025

Copy link
Copy Markdown
Member

The last thing remaining needing support from the v0 version of the language was the Quantity type, whereby numeric values can have uncertainty, magnitude, and units, for example

5.9722 ± 0.0006 × 10²⁴ kg

We add support in the parser for detecting quantity numericals, and appropriate code for presenting them nicely when formatting output.

It also turned out that we weren't accounting for the width of Unicode characters when printing error messages. That is fixed, along with ensuring that the caret points to the best location relative to where the problem is.

@istathar istathar self-assigned this Aug 7, 2025
@istathar
istathar merged commit b1022da into technique-lang:main Aug 8, 2025
1 check passed
@istathar
istathar deleted the parse-quantity branch August 14, 2025 13:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant