From 9427c78506d5249fd60c56be7e7363ef92886394 Mon Sep 17 00:00:00 2001 From: Doug Coleman Date: Wed, 6 Apr 2016 17:30:22 -0700 Subject: [PATCH] ui.debugger: quotation stack effect wants ( .. -- * ), throw causes infinite loop, but rethrow works. change previous patch to rethrow everywhere. --- basis/debugger/threads/threads.factor | 2 +- basis/io/thread/thread.factor | 2 +- basis/ui/debugger/debugger.factor | 2 +- core/continuations/continuations.factor | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/basis/debugger/threads/threads.factor b/basis/debugger/threads/threads.factor index c3fd8284db..9f4163aecf 100644 --- a/basis/debugger/threads/threads.factor +++ b/basis/debugger/threads/threads.factor @@ -15,7 +15,7 @@ IN: debugger.threads ! ( error thread -- * ) [ dup initial-thread get-global eq? [ - die drop throw + die drop rethrow ] [ [ error-in-thread. nl diff --git a/basis/io/thread/thread.factor b/basis/io/thread/thread.factor index 9efd22ad8b..8c069f440c 100644 --- a/basis/io/thread/thread.factor +++ b/basis/io/thread/thread.factor @@ -18,7 +18,7 @@ TUPLE: io-thread < thread ; "I/O wait" io-thread new-thread ; -M: io-thread error-in-thread die drop throw ; +M: io-thread error-in-thread die drop rethrow ; : start-io-thread ( -- ) t io-thread-running? set-global diff --git a/basis/ui/debugger/debugger.factor b/basis/ui/debugger/debugger.factor index 4a502cb68c..30bb6fa025 100644 --- a/basis/ui/debugger/debugger.factor +++ b/basis/ui/debugger/debugger.factor @@ -13,7 +13,7 @@ IN: ui.debugger ! ( error -- * ) [ - ui-running? [ dup error-alert ] [ dup print-error ] if die + ui-running? [ dup error-alert ] [ dup print-error ] if die rethrow ] callback-error-hook set-global M: world-error error. diff --git a/core/continuations/continuations.factor b/core/continuations/continuations.factor index dbe645b828..20ea0fe399 100644 --- a/core/continuations/continuations.factor +++ b/core/continuations/continuations.factor @@ -119,7 +119,7 @@ GENERIC: error-in-thread ( error thread -- * ) SYMBOL: thread-error-hook ! ( error thread -- * ) -thread-error-hook [ [ die drop throw ] ] initialize +thread-error-hook [ [ die drop rethrow ] ] initialize M: object error-in-thread thread-error-hook get-global call( error thread -- * ) ; @@ -128,7 +128,7 @@ M: object error-in-thread SYMBOL: callback-error-hook ! ( error -- * ) -callback-error-hook [ [ die throw ] ] initialize +callback-error-hook [ [ die rethrow ] ] initialize : rethrow ( error -- * ) dup save-error