diff options
author | hlaaftana <10591326+hlaaftana@users.noreply.github.com> | 2020-04-22 17:49:41 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-22 16:49:41 +0200 |
commit | 01523b2b58c8007cc2595f6bcf33cf2ba1d9e38a (patch) | |
tree | 6926fd2872a7d3d4be1207b801a5c95709f24178 /lib | |
parent | 5c26a83a4a3b8cf3d77773709e84afd8ec512f51 (diff) | |
download | Nim-01523b2b58c8007cc2595f6bcf33cf2ba1d9e38a.tar.gz |
change some Exceptions to CatchableError or Defect, fixes #10288 (#14069)
Diffstat (limited to 'lib')
-rw-r--r-- | lib/impure/nre.nim | 2 | ||||
-rw-r--r-- | lib/pure/asyncfutures.nim | 2 | ||||
-rw-r--r-- | lib/pure/net.nim | 4 | ||||
-rw-r--r-- | lib/pure/selectors.nim | 2 |
4 files changed, 5 insertions, 5 deletions
diff --git a/lib/impure/nre.nim b/lib/impure/nre.nim index 1d0952274..24b6ff0c7 100644 --- a/lib/impure/nre.nim +++ b/lib/impure/nre.nim @@ -198,7 +198,7 @@ type Captures* = distinct RegexMatch CaptureBounds* = distinct RegexMatch - RegexError* = ref object of Exception + RegexError* = ref object of CatchableError RegexInternalError* = ref object of RegexError ## Internal error in the module, this probably means that there is a bug diff --git a/lib/pure/asyncfutures.nim b/lib/pure/asyncfutures.nim index 236a829e3..c1e2770bb 100644 --- a/lib/pure/asyncfutures.nim +++ b/lib/pure/asyncfutures.nim @@ -33,7 +33,7 @@ type FutureVar*[T] = distinct Future[T] - FutureError* = object of Exception + FutureError* = object of Defect cause*: FutureBase when not defined(release): diff --git a/lib/pure/net.nim b/lib/pure/net.nim index 30355226c..ee00878d3 100644 --- a/lib/pure/net.nim +++ b/lib/pure/net.nim @@ -83,7 +83,7 @@ when defineSsl: type Certificate* = string ## DER encoded certificate - SslError* = object of Exception + SslError* = object of CatchableError SslCVerifyMode* = enum CVerifyNone, CVerifyPeer, CVerifyPeerUseEnvVars @@ -146,7 +146,7 @@ type ReadLineResult* = enum ## result for readLineAsync ReadFullLine, ReadPartialLine, ReadDisconnected, ReadNone - TimeoutError* = object of Exception + TimeoutError* = object of CatchableError SocketFlag* {.pure.} = enum Peek, diff --git a/lib/pure/selectors.nim b/lib/pure/selectors.nim index 743a92dd0..a2329a2dc 100644 --- a/lib/pure/selectors.nim +++ b/lib/pure/selectors.nim @@ -252,7 +252,7 @@ else: VnodeRename, VnodeRevoke type - IOSelectorsException* = object of Exception + IOSelectorsException* = object of CatchableError ReadyKey* = object fd* : int |