From cb656c6e6baefddff8b749eee62edb0b0bacf62a Mon Sep 17 00:00:00 2001 From: Joe Groff Date: Mon, 8 Mar 2010 18:28:19 -0800 Subject: [PATCH] add polymorphic stack effects to continuations:recover, attempt-all --- core/continuations/continuations.factor | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/continuations/continuations.factor b/core/continuations/continuations.factor index 332354e302..687f7153a1 100644 --- a/core/continuations/continuations.factor +++ b/core/continuations/continuations.factor @@ -119,7 +119,7 @@ SYMBOL: thread-error-hook ] when c> continue-with ; -: recover ( try recovery -- ) +: recover ( ..a try: ( ..a -- ..b ) recovery: ( ..a error -- ..b ) -- ..b ) [ [ swap >c call c> drop ] curry ] dip ifcc ; inline : ignore-errors ( quot -- ) @@ -130,7 +130,7 @@ SYMBOL: thread-error-hook ERROR: attempt-all-error ; -: attempt-all ( seq quot -- obj ) +: attempt-all ( ... seq quot: ( ... elt -- ... obj ) -- ... obj ) over empty? [ attempt-all-error ] [ -- 2.34.1