Skip to content

Commit

Permalink
Improve type docs
Browse files Browse the repository at this point in the history
  • Loading branch information
PhilippMDoerner committed Sep 9, 2023
1 parent 3b39cfc commit b792b53
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/nimword/private/types.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
type Password* = distinct string
type Password* = distinct string ## A special type for plain-text password string to prevent performing normal string operations with them. They are security critical and should not be accidentally logged or the like.

converter toPassword*(str: string): Password = str.Password
converter toPassword*(str: string): Password = str.Password ## Converter that implicitly converts any string to a `Password` type. Makes it easier to use procs with strings.

type Hash* = seq[byte]
type Hash* = seq[byte] ## A convenience type to better express hashes.

0 comments on commit b792b53

Please sign in to comment.