Skip to content

Commit

Permalink
nph
Browse files Browse the repository at this point in the history
  • Loading branch information
arnetheduck committed Aug 14, 2024
1 parent 65c3966 commit 865e3db
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions results.nim
Original file line number Diff line number Diff line change
Expand Up @@ -385,9 +385,12 @@ const
## several large applications.

when resultsLent:
template maybeLent(T: untyped): untyped = lent T
template maybeLent(T: untyped): untyped =
lent T

else:
template maybeLent(T: untyped): untyped = T
template maybeLent(T: untyped): untyped =
T

func raiseResultOk[T, E](self: Result[T, E]) {.noreturn, noinline.} =
# noinline because raising should take as little space as possible at call
Expand Down

0 comments on commit 865e3db

Please sign in to comment.