Use CatchableError as base instead of Exception

This commit is contained in:
Yuriy Glukhov 2019-11-22 18:59:02 +02:00
parent 943a961201
commit 4d61345978
No known key found for this signature in database
GPG Key ID: 733560674BB43E6C
2 changed files with 4 additions and 4 deletions

View File

@ -53,7 +53,7 @@ type
FutureVar*[T] = distinct Future[T]
FutureError* = object of Exception
FutureError* = object of CatchableError
cause*: FutureBase
CancelledError* = object of FutureError

View File

@ -49,11 +49,11 @@ type
queue: Deque[T]
maxsize: int
AsyncQueueEmptyError* = object of Exception
AsyncQueueEmptyError* = object of CatchableError
## ``AsyncQueue`` is empty.
AsyncQueueFullError* = object of Exception
AsyncQueueFullError* = object of CatchableError
## ``AsyncQueue`` is full.
AsyncLockError* = object of Exception
AsyncLockError* = object of CatchableError
## ``AsyncLock`` is either locked or unlocked.
proc newAsyncLock*(): AsyncLock =