Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions types/rnrs.arithmetic.fixnums.6.scm
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
(signature lambda () fixnum?)
(tags pure)
(desc . "Fixnum type size in bits"))
((name . "least-fixnum")
((name . "least-fixnum")
(signature lambda () fixnum?)
(tags pure)
(desc . "Smallest fixnum value"))
((name . "greatest-fixnum")
((name . "greatest-fixnum")
(signature lambda () fixnum?)
(tags pure)
(desc . "Biggest fixnum value"))
((name . "fx=?")
((name . "fx=?")
(signature lambda ((fixnum? i) ...) boolean?)
(tags pure)
(desc . "Return #t if arguments are equal, #f otherwise."))
Expand Down
8 changes: 4 additions & 4 deletions types/rnrs.conditions.6.scm
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ This type describes errors, typically caused by something that has gone wrong in

This type describes violations of the language standard or a library standard, typically caused by a programming error."))
((group
((name . "&assertion")
((name . "&assertion")
(signature value record-type-descriptor?))
((name . "make-assertion-violation")
(signature lambda () assertion-violation?)
Expand All @@ -118,7 +118,7 @@ This type describes violations of the language standard or a library standard, t

This type describes an invalid call to a procedure, either passing an invalid number of arguments, or passing an argument of the wrong type."))
((group
((name . "&irritants")
((name . "&irritants")
(signature value record-type-descriptor?))
((name . "make-irritants-condition")
(signature lambda ((list? irritants)) irritants-condition?)
Expand All @@ -136,7 +136,7 @@ This type describes an invalid call to a procedure, either passing an invalid nu

Irritants should be a list of objects. This condition provides additional information about a condition, typically the argument list of a procedure that detected an exception. Conditions of this type are created by the error and assertion-violation procedures of report section on \"Errors and violations\"."))
((group
((name . "&who")
((name . "&who")
(signature value record-type-descriptor?))
((name . "make-who-condition")
(signature lambda (((or string? symbol?) who)) who-condition?)
Expand All @@ -154,7 +154,7 @@ Irritants should be a list of objects. This condition provides additional inform

Who should be a symbol or string identifying the entity reporting the exception. Conditions of this type are created by the error and assertion-violation procedures (report section on \"Errors and violations\"), and the syntax-violation procedure (section on \"Syntax violations\")."))
((group
((name . "&non-continuable")
((name . "&non-continuable")
(signature value record-type-descriptor?))
((name . "make-non-continuable-violation")
(signature lambda () non-continuable-violation?)
Expand Down
4 changes: 2 additions & 2 deletions types/rnrs.exceptions.6.scm
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ Implementation responsibilities: The implementation must check the restrictions
(test => expression)
(else expression1 expression2 ...))))
(desc . "Evaluating a guard form evaluates <body> with an exception handler that binds the raised object to <variable> and within the scope of that binding evaluates the clauses as if they were the clauses of a cond expression. That implicit cond expression is evaluated with the continuation and dynamic environment of the guard expression. If every <cond clause>'s <test> evaluates to #f and there is no else clause, then raise is re-invoked on the raised object within the dynamic environment of the original call to raise except that the current exception handler is that of the guard expression. The final expression in a <cond> clause is in a tail context if the guard expression itself is. "))
((name . "raise")
((name . "raise")
(signature lambda (obj) undefined)
(desc . "Raises a non-continuable exception by invoking the current exception handler on obj. The handler is called with a continuation whose dynamic environment is that of the call to raise, except that the current exception handler is the one that was in place when the handler being called was installed. When the handler returns, a non-continuable exception with condition type &non-continuable is raised in the same dynamic environment as the handler."))
((name . "raise-continuable")
((name . "raise-continuable")
(signature lambda (obj) undefined)
(desc . "Raises a continuable exception by invoking the current exception handler on obj. The handler is called with a continuation that is equivalent to the continuation of the call to raise-continuable, with these two exceptions: (1) the current exception handler is the one that was in place when the handler being called was installed, and (2) if the handler being called returns, then it will again become the current exception handler. If the handler returns, the values it returns become the values returned by the call to raise-continuable.")))
2 changes: 1 addition & 1 deletion types/rnrs.hashtables.6.scm
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ Note: Hashtables are allowed to cache the results of calling the hash function a
(signature lambda ((hashtable? hashtable)) boolean?)
(tags pure)
(desc . "Returns #t if hashtable is mutable, otherwise #f."))
((name . "equal-hash")
((name . "equal-hash")
(signature lambda (obj) integer?)
(tags pure)
(desc . "Returns an integer hash value for obj, based on its structure and current contents. This hash function is suitable for use with equal? as an equivalence function.
Expand Down
8 changes: 4 additions & 4 deletions types/rnrs.io.ports.6.scm
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ If the port does not support the operation, port-position raises an exception wi
The port-has-set-port-position!? procedure returns #t if the port supports the set-port-position! operation, and #f otherwise.
The set-port-position! procedure raises an exception with condition type &assertion if the port does not support the operation, and an exception with condition type &i/o-invalid-position if pos is not in the range of valid positions of port. Otherwise, it sets the current position of the port to pos. If port is an output port, set-port-position! first flushes port. (See flush-output-port, section 8.2.10.)
If port is a binary output port and the current position is set beyond the current end of the data in the underlying data sink, the object is not extended until new data is written at that position. The contents of any intervening positions are unspecified. Binary ports created by open-file-output-port and open-file-input/output-port can always be extended in this manner within the limits of the underlying operating system. In other cases, attempts to set the port beyond the current end of data in the underlying object may result in an exception with condition type &i/o-invalid-position."))
((name . "close-port")
((name . "close-port")
(signature lambda ((port? port)) undefined)
(desc . "Closes the port, rendering the port incapable of delivering or accepting data. If port is an output port, it is flushed before being closed. This has no effect if the port has already been closed. A closed port is still a port. The close-port procedure returns unspecified values."))
((name . "call-with-port")
Expand Down Expand Up @@ -183,10 +183,10 @@ If bytevector is modified after open-bytevector-input-port has been called, the
((name . "open-string-input-port")
(signature lambda ((string? string)) input-port?)
(desc . "Returns a textual input port whose characters are drawn from string. The port may or may not have an associated transcoder; if it does, the transcoder is implementation-dependent. The port should support the port-position and set-port-position! operations. If string is modified after open-string-input-port has been called, the effect on the returned port is unspecified."))
((name . "standard-input-port")
((name . "standard-input-port")
(signature lambda () binary-port?)
(desc . "Returns a fresh binary input port connected to standard input. Whether the port supports the port-position and set-port-position! operations is implementation-dependent."))
((name . "current-input-port")
((name . "current-input-port")
(signature lambda () textual-port?)
(desc . "This returns a default textual port for input. Normally, this default port is associated with standard input, but can be dynamically re-assigned using the with-input-from-file procedure from the (rnrs io simple (6)) library (see section 8.3). The port may or may not have an associated transcoder; if it does, the transcoder is implementation-dependent."))
((name . "make-custom-binary-input-port")
Expand Down Expand Up @@ -293,7 +293,7 @@ The get-string-n! procedure reads from textual-input-port in the same manner as
(signature lambda ((input-port? input-port)) (or eof-object? string?))
(desc . "Reads from textual-input-port up to and including the linefeed character or end of file, decoding characters in the same manner as get-string-n and get-string-n!.
If a linefeed character is read, a string containing all of the text up to (but not including) the linefeed character is returned, and the port is updated to point just past the linefeed character. If an end of file is encountered before any linefeed character is read, but some characters have been read and decoded as characters, a string containing those characters is returned. If an end of file is encountered before any characters are read, the end-of-file object is returned."))
((name . "get-datum")
((name . "get-datum")
(signature lambda ((input-port? input-port)) *)
(desc . "Reads an external representation from textual-input-port and returns the datum it represents. The get-datum procedure returns the next datum that can be parsed from the given textual-input-port, updating textual-input-port to point exactly past the end of the external representation of the object.
Any <interlexeme space> (see report section on “Lexical syntax”) in the input is first skipped. If an end of file occurs after the <interlexeme space>, the end-of-file object (see section 8.2.5) is returned.
Expand Down
24 changes: 9 additions & 15 deletions types/rnrs.lists.6.scm
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
(((name . "find")
(signature lambda ((procedure? pred) (list? list)) *)
(subsigs (pred (lambda (obj) *)))
(signature lambda ((predicate pred) (list? list)) *)
(tags pure)
(desc . "Proc should accept one argument and return a single value. Proc should not mutate list. The find procedure applies proc to the elements of list in order. If proc returns a true value for an element, find immediately returns that element. If proc returns #f for all elements of the list, find returns #f. Proc is always called in the same dynamic environment as find itself."))
((name . "for-all")
Expand All @@ -14,13 +13,11 @@
(tags pure)
(desc . " The lists should all have the same length, and proc should accept n arguments and return a single value. Proc should not mutate the list arguments. For natural numbers i = 0, 1, ..., the exists procedure applies proc successively to arguments xi1 ... xin, where xij is the ith element of listj, until a true value is returned. If proc returns #f for all but the last elements of the lists, exists performs a tail call of proc on the kth elements, where k is the length of list1. If proc returns a true value on any set of elements, exists returns that value after the first such application of proc. If the lists are all empty, exists returns #f."))
((name . "filter")
(signature lambda ((procedure? pred) (list? list)) list?)
(subsigs (pred (lambda (obj) *)))
(signature lambda ((predicate pred) (list? list)) list?)
(tags pure)
(desc . "Proc should accept one argument and return a single value. Proc should not mutate list. The filter procedure applies proc to each element of list and returns a list of the elements of list for which proc returned a true value. The elements of the result list are in the same order as they appear in the input list. Proc is always called in the same dynamic environment as filter. If multiple returns occur from filter, the return values returned by earlier returns are not mutated."))
((name . "partition")
(signature lambda ((procedure? pred) (list? list)) (values list? list?))
(subsigs (pred (lambda (obj) *)))
(signature lambda ((predicate pred) (list? list)) (values list? list?))
(tags pure)
(desc . "Proc should accept one argument and return a single value. Proc should not mutate list. The partition procedure also applies proc to each element of list, but returns two values, the first one a list of the elements of list for which proc returned a true value, and the second a list of the elements of list for which proc returned #f. The elements of the result lists are in the same order as they appear in the input list. Proc is always called in the same dynamic environment as partition itself. If multiple returns occur from partitions, the return values returned by earlier returns are not mutated."))
((name . "fold-left")
Expand All @@ -34,11 +31,10 @@
(tags pure)
(desc . "The lists should all have the same length. Combine must be a procedure. It should accept one more argument than there are lists and return a single value. Combine should not mutate the list arguments. The fold-right procedure iterates the combine procedure over the elements of the lists from right to left and an accumulator value, starting with an accumulator value of nil. More specifically, fold-right returns nil if the lists are empty. If they are not empty, combine is first applied to the respective last elements of the lists in order and nil. The result becomes the new accumulator value, and combine is applied to the respective previous elements of the lists and the new accumulator value. This step is repeated until the beginning of the list is reached; then the accumulator value is returned. Proc is always called in the same dynamic environment as fold-right itself."))
((name . "remp")
(signature lambda ((procedure? pred) (list? list)) list?)
(subsigs (pred (lambda (obj) *)))
(signature lambda ((predicate pred) (list? list)) list?)
(tags pure)
(desc . "The remp procedure applies proc to each element of list and returns a list of the elements of list for which proc returned #f."))
((name . "remove")
((name . "remove")
(signature lambda (obj (list? list)) list?)
(tags pure)
(desc . "The remove procedure return a list of the elements that are not obj as according to equal?."))
Expand All @@ -51,8 +47,7 @@
(tags pure)
(desc . "The remq procedure return a list of the elements that are not obj as according to eq?."))
((name . "memp")
(signature lambda ((procedure? pred) (list? list)) (or #f list?))
(subsigs (pred (lambda (obj) *)))
(signature lambda ((predicate pred) (list? list)) (or #f list?))
(tags pure)
(desc . "Proc should accept one argument and return a single value. Proc should not mutate list. Returns the first sublist of list whose car satisfies a given condition, where the sublists of lists are the lists returned by (list-tail list k) for k less than the length of list. The memp procedure applies proc to the cars of the sublists of list until it finds one for which proc returns a true value. Proc is always called in the same dynamic environment as memp itself. If list does not contain an element satisfying the condition, then #f (not the empty list) is returned."))
((name . "member")
Expand All @@ -68,9 +63,8 @@
(tags pure)
(desc . "Returns the first sublist of list whose car satisfies a given condition, where the sublists of lists are the lists returned by (list-tail list k) for k less than the length of list. The memv procedure looks for the first occurrence of obj. If list does not contain an element satisfying the condition, then #f (not the empty list) is returned. The memv procedure uses eqv? to compare obj with the elements of list."))
((name . "assp")
(signature lambda ((procedure? pred) (list? alist)) (or pair? #f))
(subsigs
(pred (lambda (obj) *))
(signature lambda ((predicate pred) (list? alist)) (or pair? #f))
(subsigs
(alist (alist key value)))
(tags pure)
(desc . "Alist (for \"association list\") should be a list of pairs. Proc should accept one argument and return a single value. Proc should not mutate alist. The procedure finds the first pair in alist whose car field satisfies a given condition, and returns that pair without traversing alist further. If no pair in alist satisfies the condition, then #f is returned. The assp procedure successively applies proc to the car fields of alist and looks for a pair for which it returns a true value. Proc is always called in the same dynamic environment as assp itself."))
Expand All @@ -89,7 +83,7 @@
(subsigs (alist (alist key value)))
(tags pure)
(desc . " Alist (for \"association list\") should be a list of pairs. The procedure finds the first pair in alist whose car field satisfies a given condition, and returns that pair without traversing alist further. If no pair in alist satisfies the condition, then #f is returned. The assoc procedure looks for a pair that has obj as its car. The assv procedure uses eqv? to compare obj with the car fields of the pairs in alist."))
((name . "cons*")
((name . "cons*")
(signature lambda (elt1 elt2 ...) *)
(tags pure)
(desc . "If called with at least two arguments, cons* returns a freshly allocated chain of pairs whose cars are obj1, ..., objn, and whose last cdr is obj. If called with only one argument, cons* returns that argument.")))
2 changes: 1 addition & 1 deletion types/rnrs.programs.6.scm
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
(((name . "command-line")
(((name . "command-line")
(signature lambda () list?)
(desc . "Returns a nonempty list of strings. The first element is an implementation-specific name for the running top-level program. The remaining elements are command-line arguments according to the operating system's conventions."))
((name . "exit")
Expand Down
4 changes: 2 additions & 2 deletions types/rnrs.r5rs.6.scm
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@
(signature lambda ((integer? n1) (integer? n2)) integer?)
(tags pure)))
(desc . "These procedures implement number-theoretic (integer) division. N2 must be non-zero."))
((name . "delay")
((name . "delay")
(signature syntax-rules () ((_ expression) promise?))
(desc . "The delay construct is used together with the procedure force to implement lazy evaluation or call by need. (delay <expression>) returns an object called a promise which at some point in the future may be asked (by the force procedure) to evaluate <expression>, and deliver the resulting value. The effect of <expression> returning multiple values is unspecified."))
((name . "force")
((name . "force")
(signature lambda ((promise? promise)) *)
(desc . "Promise must be a promise. The force procedure forces the value of promise. If no value has been computed for the promise, then a value is computed and returned. The value of the promise is cached (or “memoized”) so that if it is forced a second time, the previously computed value is returned."))
((name . "null-environment")
Expand Down
3 changes: 1 addition & 2 deletions types/rnrs.records.procedural.6.scm
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ If rtd is an extension of another record type, and parent-constructor-descriptor
procedure?)
(desc . "Calls the protocol of constructor-descriptor (as described for make-record-constructor-descriptor) and returns the resulting constructor constructor for records of the record type associated with constructor-descriptor."))
((name . "record-predicate")
(signature lambda ((record-type-descriptor? rtd)) procedure?)
(subsigs (return (lambda (obj) boolean?)))
(signature lambda ((record-type-descriptor? rtd)) predicate)
(desc . "Returns a procedure that, given an object obj, returns #t if obj is a record of the type represented by rtd, and #f otherwise."))
((name . "record-accessor")
(signature lambda ((record-type-descriptor? rtd) (integer? k)) procedure?)
Expand Down
2 changes: 1 addition & 1 deletion types/scheme.inexact.scm
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ tan^-1 z = (log(1 + iz) - log(1 - iz)) / (2i)"))
(signature lambda ((number? z)) boolean?)
(tags pure)
(desc . "The finite? procedure returns #t on all real numbers except +inf.0, -inf.0, and +nan.0, and on complex numbers if their real and imaginary parts are both finite. Otherwise it returns #f."))
((name . "infinite?")
((name . "infinite?")
(signature lambda ((number? z)) boolean?)
(tags pure)
(desc . "The infinite? procedure returns #t on the real numbers +inf.0 and -inf.0, and on complex numbers if their real or imaginary parts or both are infinite. Otherwise it returns #f."))
Expand Down
Loading
Loading