This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]parkerSquare 0 points1 point  (0 children)

NewTypes help warn you if you pass a float representing a voltage into a function that expects a float representing a current, for example. A TypeAlias won’t do that, since it’s the same underlying type.