From 37cbd6d5a9c420d2bd031cac8a98412ca3d5f7eb Mon Sep 17 00:00:00 2001 From: Asumu Takikawa Date: Wed, 7 Nov 2012 18:07:10 -0500 Subject: [PATCH] Docs for prompt tag & mark key types original commit: aae8890cd3939bf6dd6d0bddc640a2e03dcd1c3f --- .../scribblings/reference/types.scrbl | 30 ++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/collects/typed-racket/scribblings/reference/types.scrbl b/collects/typed-racket/scribblings/reference/types.scrbl index c446c501..fe6247f6 100644 --- a/collects/typed-racket/scribblings/reference/types.scrbl +++ b/collects/typed-racket/scribblings/reference/types.scrbl @@ -194,7 +194,6 @@ needed to check the desired bounds at runtime. @defidform[Null] @defidform[EOF] @defidform[Continuation-Mark-Set] -@defidform[Prompt-Tag] @defidform[Undefined] @defidform[Module-Path] @defidform[Module-Path-Index] @@ -384,6 +383,35 @@ of type @racket[Syntax-E].} @racket[(Sexpof Syntax)].} +@section{Control} + +The following types represent @rtech{prompt tag}s and +keys for @rtech{continuation mark}s for use with delimited continuation +functions and continuation mark functions. + +@defform[(Prompt-Tag s t)]{ + A prompt tag to be used in a continuation prompt whose body + produces the type @racket[_s] and whose handler has the type + @racket[_t]. The type @racket[_t] must be a function type. + + The domain of @racket[_t] determines the type of the values + that can be aborted, using @racket[abort-current-continuation], + to a prompt with this prompt tag. + + @ex[(make-continuation-prompt-tag 'prompt-tag)] +} + +@defform[(Continuation-Mark-Key t)]{ + A continuation mark key that is used for continuation mark + operations such as @racket[with-continuation-mark] and + @racket[continuation-mark-set->list]. The type @racket[_t] + represents the type of the data that is stored in the + continuation mark with this key. + + @ex[(make-continuation-mark-key 'mark-key)] +} + + @section{Other Type Constructors} @defform*[#:id -> #:literals (* ...)