From e91f243b641016468b2f8a98376193f26aae2302 Mon Sep 17 00:00:00 2001
From: Eli Barzilay
Date: Wed, 2 Feb 2011 16:09:06 -0500
Subject: [PATCH 01/68] Avoid compiling plot if the source directory is missing
---
src/racket/configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/racket/configure.ac b/src/racket/configure.ac
index 861fce62ca..cf2256881c 100644
--- a/src/racket/configure.ac
+++ b/src/racket/configure.ac
@@ -1259,7 +1259,7 @@ fi
makefiles="$makefiles foreign/Makefile"
ac_configure_args="$ac_configure_args$SUB_CONFIGURE_EXTRAS"
-if test "${enable_plot}" = "yes" ; then
+if test -d "${srcdir}/plot" && test "${enable_plot}" = "yes" ; then
makefiles="$makefiles
plot/Makefile"
MAKE_PLOT=plot
From 9d204c01cf910c1290838fe9712e083acc4eb474 Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Tue, 1 Feb 2011 20:39:43 -0700
Subject: [PATCH 02/68] fix problem with allocation while holding a future lock
Merge to 5.1
---
src/racket/src/future.c | 23 ++++++++++++++++-------
1 file changed, 16 insertions(+), 7 deletions(-)
diff --git a/src/racket/src/future.c b/src/racket/src/future.c
index deeb313052..9c60c64a03 100644
--- a/src/racket/src/future.c
+++ b/src/racket/src/future.c
@@ -227,7 +227,7 @@ typedef struct Scheme_Future_State {
future_t *future_waiting_lwc;
int next_futureid;
- mzrt_mutex *future_mutex;
+ mzrt_mutex *future_mutex; /* BEWARE: don't allocate while holding this lock */
mzrt_sema *future_pending_sema;
mzrt_sema *gc_ok_c;
mzrt_sema *gc_done_c;
@@ -825,19 +825,28 @@ Scheme_Object *touch(int argc, Scheme_Object *argv[])
mzrt_mutex_lock(fs->future_mutex);
if (ft->work_completed)
{
+ int id;
+ double time_of_start;
+ double time_of_completion;
+
retval = ft->retval;
+ id = ft->id;
+ time_of_start = ft->time_of_start;
+ time_of_completion = ft->time_of_completion;
+
+ mzrt_mutex_unlock(fs->future_mutex);
+
/* Log execution time */
if (scheme_log_level_p(scheme_main_logger, SCHEME_LOG_DEBUG)) {
scheme_log(scheme_main_logger, SCHEME_LOG_DEBUG, 0,
- "future: %d finished. start time: %f, finish time: %f (%f ms)",
- ft->id,
- ft->time_of_start,
- ft->time_of_completion,
- ft->time_of_completion - ft->time_of_start);
+ "future: %d finished. start time: %f, finish time: %f (%f ms)",
+ id,
+ time_of_start,
+ time_of_completion,
+ time_of_completion - time_of_start);
}
- mzrt_mutex_unlock(fs->future_mutex);
break;
}
else if (ft->rt_prim)
From d704f9565b8db7cf456dac84c025b188425c06c9 Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Wed, 2 Feb 2011 16:09:21 -0700
Subject: [PATCH 03/68] fix typo
---
collects/scribblings/scribble/manual.scrbl | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/collects/scribblings/scribble/manual.scrbl b/collects/scribblings/scribble/manual.scrbl
index cdf1288bb7..c3baaea8bc 100644
--- a/collects/scribblings/scribble/manual.scrbl
+++ b/collects/scribblings/scribble/manual.scrbl
@@ -208,7 +208,7 @@ without insetting the code.}
@defform[(RACKETRESULTBLOCK0 datum ...)]
)]{
-Like @racketblock[racketblock], etc., but colors the typeset text as a
+Like @racket[racketblock], etc., but colors the typeset text as a
result (i.e., a single color with no hyperlinks) instead of code.}
@deftogether[(
From 309e1aec4f800c5a5f947fc5ce07bf80bed07e5e Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Wed, 2 Feb 2011 16:10:40 -0700
Subject: [PATCH 04/68] re-generate `configure' script Merge to 5.1, along
with e91f243b64101
---
src/configure | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/configure b/src/configure
index 93be470962..32c4d54373 100755
--- a/src/configure
+++ b/src/configure
@@ -9920,7 +9920,7 @@ fi
makefiles="$makefiles foreign/Makefile"
ac_configure_args="$ac_configure_args$SUB_CONFIGURE_EXTRAS"
-if test "${enable_plot}" = "yes" ; then
+if test -d "${srcdir}/plot" && test "${enable_plot}" = "yes" ; then
makefiles="$makefiles
plot/Makefile"
MAKE_PLOT=plot
From 63aa388d495fc753c9772cc645e32672a841cc89 Mon Sep 17 00:00:00 2001
From: Robby Findler
Date: Wed, 2 Feb 2011 16:05:59 -0600
Subject: [PATCH 05/68] missed a multiple-vlaues change in a short-cut case.
Please merge to the 5.1 release branch
---
collects/framework/private/color.rkt | 17 ++++++++++-------
1 file changed, 10 insertions(+), 7 deletions(-)
diff --git a/collects/framework/private/color.rkt b/collects/framework/private/color.rkt
index a1203f8fd1..365c48f0ea 100644
--- a/collects/framework/private/color.rkt
+++ b/collects/framework/private/color.rkt
@@ -825,20 +825,23 @@ added get-regions
(define/public (get-token-range position)
(define-values (tokens ls) (get-tokens-at-position 'get-token-range position))
- (values (and tokens (+ (lexer-state-start-pos ls)
- (send tokens get-root-start-position)))
- (and tokens (+ (lexer-state-start-pos ls)
- (send tokens get-root-end-position)))))
+ (values (and tokens ls
+ (+ (lexer-state-start-pos ls)
+ (send tokens get-root-start-position)))
+ (and tokens ls
+ (+ (lexer-state-start-pos ls)
+ (send tokens get-root-end-position)))))
(define/private (get-tokens-at-position who position)
(when stopped?
(error who "called on a color:text<%> whose colorer is stopped."))
(let ([ls (find-ls position)])
- (and ls
- (let ([tokens (lexer-state-tokens ls)])
+ (if ls
+ (let ([tokens (lexer-state-tokens ls)])
(tokenize-to-pos ls position)
(send tokens search! (- position (lexer-state-start-pos ls)))
- (values tokens ls)))))
+ (values tokens ls))
+ (values #f #f))))
(define/private (tokenize-to-pos ls position)
(when (and (not (lexer-state-up-to-date? ls))
From c2c6c79a15b12d2ca689a75ed519f1fb364e1fd8 Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Wed, 2 Feb 2011 19:00:27 -0700
Subject: [PATCH 06/68] fix `image-snip%' unmarshaling with filename Merge to
5.1
---
collects/racket/snip/private/snip.rkt | 3 +--
collects/tests/gracket/wxme.rkt | 19 +++++++++++++++++++
2 files changed, 20 insertions(+), 2 deletions(-)
diff --git a/collects/racket/snip/private/snip.rkt b/collects/racket/snip/private/snip.rkt
index 5ccae9bab5..fecdc0bd7c 100644
--- a/collects/racket/snip/private/snip.rkt
+++ b/collects/racket/snip/private/snip.rkt
@@ -787,8 +787,7 @@
(def/override (read [editor-stream-in% f])
(let ([scl (get-the-snip-class-list)]
[can-inline? ((send f do-reading-version this) . > . 1)])
- (let ([filename (let ([s (send f get-bytes #f)])
- (subbytes s 0 (max 0 (sub1 (bytes-length s)))))])
+ (let ([filename (send f get-bytes #f)])
(let-boxes ([type 0]
[w 0.0]
[h 0.0]
diff --git a/collects/tests/gracket/wxme.rkt b/collects/tests/gracket/wxme.rkt
index 4208af35ff..c436b39fb9 100644
--- a/collects/tests/gracket/wxme.rkt
+++ b/collects/tests/gracket/wxme.rkt
@@ -1347,4 +1347,23 @@
;; ----------------------------------------
+(let ()
+ (define (mk) (make-object image-snip% (collection-file-path "b-run.png" "icons") 'unknown #f #f))
+
+ (define is (mk))
+ (define copy-is
+ (let ()
+ (define sp (open-output-string))
+ (define t (new text%))
+ (send t insert (mk))
+ (send t save-port sp)
+ (define t2 (new text%))
+ (send t2 insert-port (open-input-string (get-output-string sp)))
+ (send t2 find-first-snip)))
+
+ (expect (send (mk) get-filename)
+ (send copy-is get-filename)))
+
+;; ----------------------------------------
+
(done)
From 0fce29f552eeef416bfb66459123614518f02513 Mon Sep 17 00:00:00 2001
From: Robby Findler
Date: Wed, 2 Feb 2011 20:10:44 -0600
Subject: [PATCH 07/68] adjust the wxme reader so that it now creates
image-snip%s when it finds image-snips in file it used to create image%
objects that were simple containers for the data in the file; the change
_should_ be backwards compatibile; the only know incompatibility is that
the get-filename method now returns a path instead of bytes (this is to
match the image-snip% class)
closes PR 1168
please merge to the 5.1 release branch
---
collects/racket/snip/private/snip.rkt | 6 +-
collects/scribblings/gui/wxme.scrbl | 20 +--
.../gracket/image-snip-unmarshalling.rkt | 142 ++++++++++++++++++
collects/wxme/image.rkt | 59 +++++++-
collects/wxme/wxme.rkt | 8 +-
5 files changed, 219 insertions(+), 16 deletions(-)
create mode 100644 collects/tests/gracket/image-snip-unmarshalling.rkt
diff --git a/collects/racket/snip/private/snip.rkt b/collects/racket/snip/private/snip.rkt
index fecdc0bd7c..1bcd4f27dc 100644
--- a/collects/racket/snip/private/snip.rkt
+++ b/collects/racket/snip/private/snip.rkt
@@ -49,7 +49,8 @@
readable-snip<%>
- image-type?)
+ image-type?
+ int->img-type)
;; these are used only in contracts
;; we don't want the real definitions b/c they require the gui
@@ -826,6 +827,9 @@
(values filename
(int->img-type type)
#f))])
+ ;; the call to create an image-snip% object
+ ;; here should match the way that super-make-object
+ ;; is called in wxme/image.rkt
(let ([snip (make-object image-snip%
(if (equal? loadfile #"")
#f
diff --git a/collects/scribblings/gui/wxme.scrbl b/collects/scribblings/gui/wxme.scrbl
index e49260956a..875dd4bdd9 100644
--- a/collects/scribblings/gui/wxme.scrbl
+++ b/collects/scribblings/gui/wxme.scrbl
@@ -3,6 +3,7 @@
(for-label wxme
wxme/editor
wxme/image
+ racket/snip
(except-in wxme/comment reader)
(except-in wxme/xml reader)
(except-in wxme/scheme reader)
@@ -302,7 +303,7 @@ Several compatibility mappings are installed automatically for the
@racketmodname[wxme] library. They correspond to popular graphical
elements supported by various versions of DrRacket, including comment
boxes, fractions, XML boxes, Racket boxes, text boxes, and images
-generated by the ``world'' and ``image'' teachpacks (or, more
+generated by the @racketmodname[htdp/image] teachpack (or, more
generally, from @racketmodname[mrlib/cache-image-snip]), and test-case
boxes.
@@ -323,7 +324,8 @@ special-comment content is the readable instance. XML, Racket, and
text boxes similarly produce instances of @racket[editor%] and
@racket[readable<%>] that expand in the usual way; see
@racketmodname[wxme/xml], @racketmodname[wxme/scheme], and
-@racket[wxme/text]. Images from the ``world'' and ``image'' teachpacks
+@racket[wxme/text]. Images from the
+@racketmodname[htdp/image] teachpack
are packaged as instances of @racket[cache-image%] from the
@racketmodname[wxme/cache-image] library. Test-case boxes are packaged
as instances of @racket[test-case%] from the
@@ -353,14 +355,14 @@ editor's content.}
@defmodule[wxme/image]
-@defclass[image% object% ()]{
+@defclass[image% image-snip% ()]{
Instantiated for images in a @tech{WXME} stream in text mode.
-
-@defmethod[(get-filename) (or/c bytes? false/c)]{
-
-Returns a filename as bytes, or @racket[#f] if data is available
-instead.}
+This class can just be treated like @racket[image-snip%] and should
+behave just like it, except it has the methods below in addition
+in case old code still needs them. In other words, the methods
+below are provided for backwards compatibility with earlier
+verisons of Racket.
@defmethod[(get-data) (or/c bytes? false/c)]{
@@ -543,7 +545,7 @@ rational numbers.}]
@defthing[reader (is-a?/c snip-reader<%>)]{
A text-mode reader for images in a WXME stream generated by the
-``image'' and ``world'' teachpacks---or, more generally, by
+@racketmodname[htdp/image] teachpack---or, more generally, by
@racketmodname[mrlib/cache-image-snip].}]
diff --git a/collects/tests/gracket/image-snip-unmarshalling.rkt b/collects/tests/gracket/image-snip-unmarshalling.rkt
new file mode 100644
index 0000000000..cb8a4937ea
--- /dev/null
+++ b/collects/tests/gracket/image-snip-unmarshalling.rkt
@@ -0,0 +1,142 @@
+#lang racket/gui
+(require wxme
+ wxme/image)
+
+#|
+
+This file tests the wxme image-snip reader against the normal
+image-snip reader (ie image-snip-class%'s read method)
+
+It creates a bunch of different image-snip% objects
+(the try-perms and below functions)
+and then feeds them thru both paths to get two new image snips
+(in the beginning of test-wxme-image-snip-reader/proc)
+and compares a bunch of properties of them
+(the end of that function).
+
+|#
+
+(define-syntax (test-wxme-image-snip-reader stx)
+ (syntax-case stx ()
+ [(_ is)
+ (with-syntax ([line (syntax-line stx)])
+ #'(test-wxme-image-snip-reader/proc line is))]))
+
+(define tests 0)
+(define (test-wxme-image-snip-reader/proc line is)
+ (set! tests (+ tests 1))
+ (define t (new text%))
+ (send t insert is)
+ (define sp (open-output-string))
+ (void (send t save-port sp))
+ (define wp (wxme-port->port (open-input-string (get-output-string sp))))
+ (define wxme-is (read-char-or-special wp))
+
+ (define t2 (new text%))
+ (send t2 insert-port (open-input-string (get-output-string sp)))
+ (define copy-is (send t2 find-first-snip))
+
+ (define (warn . args)
+ (fprintf (current-error-port)
+ (string-append (format "FAILED test-wxme-image-snip-reader.rkt line ~a: " line)
+ (apply format args))))
+
+ (define-syntax-rule (cmp mtd) (cmp/proc (λ (x) (send x mtd)) 'mtd))
+ (define (cmp/proc call-mtd mtd)
+ (let ([is-ans (call-mtd is)]
+ [wxme-is-ans (call-mtd wxme-is)]
+ [copy-is-ans (call-mtd copy-is)])
+ (unless (same? copy-is-ans wxme-is-ans)
+ (warn "~a returned different results; copy-is: ~s wxme-is: ~s\n"
+ mtd
+ copy-is-ans
+ wxme-is-ans))
+ #;
+ (unless (same? is-ans copy-is-ans)
+ (warn "~a returned different results; is: ~s copy-is: ~s\n"
+ mtd
+ is-ans
+ copy-is-ans))))
+
+ (when (is-a? is image%)
+ (warn "the input image-snip% is an image%\n"))
+
+ (unless (is-a? wxme-is image%)
+ (warn "new image snip is not an image%\n"))
+
+ (cmp get-filename)
+ (cmp get-filetype)
+ (cmp get-bitmap)
+ (cmp get-bitmap-mask))
+
+(define (same? x y)
+ (cond
+ [(and (is-a? x bitmap%)
+ (is-a? y bitmap%))
+ (and (= (send x get-width)
+ (send y get-width))
+ (= (send x get-height)
+ (send y get-height))
+ (= (send x get-depth)
+ (send y get-depth))
+ (check? (bitmap->bytes x #f)
+ (bitmap->bytes y #f)
+ 'bitmap/#f)
+ (check? (bitmap->bytes x #t)
+ (bitmap->bytes y #t)
+ 'bitmap/#t))]
+ [else (equal? x y)]))
+
+
+(define (check? a b what)
+ (cond
+ [(equal? a b) #t]
+ [else
+ ;(fprintf (current-error-port) "checking ~s, doesn't match\n~s\nvs\n~s\n\n" what a b)
+ #f]))
+
+(define (bitmap->bytes bmp alpha?)
+ (define w (send bmp get-width))
+ (define h (send bmp get-height))
+ (define bytes (make-bytes (* 4 w h) 0))
+ (send bmp get-argb-pixels 0 0 w h bytes alpha?)
+ bytes)
+
+(define (try-perms files kinds relative-path?s inline?s)
+ (for* ([file (in-list files)]
+ [kind (in-list kinds)]
+ [relative-path? (in-list relative-path?s)]
+ [inline? (in-list inline?s)])
+ (test-wxme-image-snip-reader (make-object image-snip% file kind relative-path? inline?))))
+
+(try-perms (list (collection-file-path "b-run.png" "icons"))
+ '(unknown unknown/mask unknown/alpha
+ png png/mask png/alpha)
+ '(#f)
+ '(#f #t))
+
+(parameterize ([current-directory (collection-path "icons")])
+ (try-perms (list "b-run.png")
+ '(unknown unknown/mask unknown/alpha
+ png png/mask png/alpha)
+ '(#f)
+ '(#f #t)))
+
+(define (draw-circle bm)
+ (define bdc (make-object bitmap-dc% bm))
+ (send bdc set-smoothing 'smoothed)
+ (send bdc set-brush "red" 'solid)
+ (send bdc draw-ellipse 1 1 8 8)
+ (send bdc set-bitmap #f))
+
+(let ([bm (make-bitmap 10 10 #f)])
+ (draw-circle bm)
+ (test-wxme-image-snip-reader (make-object image-snip% bm))
+ (test-wxme-image-snip-reader (make-object image-snip% bm #f))
+ (test-wxme-image-snip-reader (make-object image-snip% bm bm)))
+
+(let ([bm (make-bitmap 10 10)])
+ (draw-circle bm)
+ (test-wxme-image-snip-reader (make-object image-snip% bm)))
+
+(printf "ran ~a tests\n" tests)
diff --git a/collects/wxme/image.rkt b/collects/wxme/image.rkt
index 27915207b2..24e3dba79b 100644
--- a/collects/wxme/image.rkt
+++ b/collects/wxme/image.rkt
@@ -1,11 +1,62 @@
+#lang racket/base
+(require racket/class
+ racket/snip
+ "private/class-help.ss")
-(module image mzscheme
- (require mzlib/class
- "private/class-help.ss")
+(provide image%)
- (provide image%)
+#|
+
+This code is a bit strange in order to attempt to
+preserve backwards compatibility with pre-5.1 versions.
+
+The old version is:
(define image%
(class object%
(init-accessible filename data w h dx dy)
(super-new))))
+
+The things I attempted to preserve:
+
+ - image% as a class whose objects can be tested with is-a?
+
+ - the get-* methods that init-accessible provides; with the exception
+ of get-filename, which is now the image-snip% method, these are done
+ still with init-accessible
+
+ The get-filename method changed, tho: it now returns a path (it returned
+ bytes before)
+
+ - the constructor arity (there are now additional optional arguments that
+ wxme supplies to be able to call super-make-object)
+
+The main change is to make this file depend on racket/snip so that
+image% can be a subclass of image-snip% and thus work with things like
+the 2htdp/universe libraries (in executables)
+
+
+|#
+
+(define image%
+ (class image-snip%
+ (init filename)
+ (init-accessible data w h dx dy)
+ (init [relative 1] [type 'unknown])
+ ;; the call to super-make-object is intended to mimic the way that racket/snip/private/snip.rkt
+ ;; creates an image-snip% object in the image-snip-class% class's read method
+ (let ([data (get-data)])
+ (super-make-object
+ (if data
+ (let-values ([(in out) (make-pipe)])
+ (thread (λ () (display data out) (close-output-port out)))
+ in)
+ (if (bytes? filename)
+ (bytes->path filename)
+ #f))
+ (if data 'unknown/alpha type)
+ (positive? relative)
+ (and data #t)))
+ (inherit resize set-offset)
+ (resize (get-w) (get-h))
+ (set-offset (get-dx) (get-dy))))
diff --git a/collects/wxme/wxme.rkt b/collects/wxme/wxme.rkt
index 819e60b1b1..97f110c0dd 100644
--- a/collects/wxme/wxme.rkt
+++ b/collects/wxme/wxme.rkt
@@ -8,6 +8,7 @@
mzlib/list
scheme/gui/dynamic
syntax/modread
+ (only racket/snip/private/snip int->img-type)
"image.ss"
"editor.ss"
"private/compat.ss")
@@ -449,7 +450,7 @@
[h (read-inexact who port vers "image-snip height")]
[dx (read-inexact who port vers "image-snip x-offset")]
[dy (read-inexact who port vers "image-snip y-offset")]
- [rel? (read-integer who port vers "image-snip relative?")])
+ [relative (read-integer who port vers "image-snip relative?")])
(let ([data
(and (and (equal? filename #"")
(cvers . > . 1)
@@ -466,7 +467,10 @@
(loop (add1 i))))))))])
(if (header-plain-text? header)
#"."
- (make-object image% (if data #f filename) data w h dx dy)))))]
+ (make-object image%
+ (if data #f filename)
+ data w h dx dy
+ relative (int->img-type type))))))]
[else
(if (header-skip-content? header)
#f
From 16eb172e5af019ce8f0aa6563c65f8c06ad7bee8 Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Thu, 3 Feb 2011 06:16:26 -0700
Subject: [PATCH 08/68] fix jpeg writing Closes PR 11701 Merge to 5.1
---
collects/racket/draw/unsafe/jpeg.rkt | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/collects/racket/draw/unsafe/jpeg.rkt b/collects/racket/draw/unsafe/jpeg.rkt
index 08e7753d1c..9399aec0fc 100644
--- a/collects/racket/draw/unsafe/jpeg.rkt
+++ b/collects/racket/draw/unsafe/jpeg.rkt
@@ -562,11 +562,13 @@
(define (init-destination m)
(void))
-(define (empty-output-buffer m)
+(define (do-empty-output-buffer m all?)
(let* ([d (jpeg_compress_struct-dest m)]
[b (jpeg_destination_mgr-buffer d)]
[bstr (scheme_make_sized_byte_string b
- (- BUFFER-SIZE (jpeg_destination_mgr-free_in_buffer d))
+ (if all?
+ BUFFER-SIZE
+ (- BUFFER-SIZE (jpeg_destination_mgr-free_in_buffer d)))
0)]
[out (ptr-ref (jpeg_compress_struct-client_data m) _scheme)])
(write-bytes bstr out)
@@ -574,8 +576,11 @@
(set-jpeg_destination_mgr-free_in_buffer! d BUFFER-SIZE)
#t))
+(define (empty-output-buffer m)
+ (do-empty-output-buffer m #t))
+
(define (term-destination m)
- (empty-output-buffer m)
+ (do-empty-output-buffer m #f)
;; Maybe add support to optionally close port as early as possible?
(when #f
(let ([in (ptr-ref (jpeg_decompress_struct-client_data m) _scheme)])
From 08cc4dffb2ebdf5d60abce6a121adf32817b4fdb Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Thu, 3 Feb 2011 06:30:10 -0700
Subject: [PATCH 09/68] fix guide typos Closes PR 11700 Merge to 5.1
---
collects/scribblings/guide/match.scrbl | 6 +++---
collects/scribblings/guide/performance.scrbl | 4 ++--
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/collects/scribblings/guide/match.scrbl b/collects/scribblings/guide/match.scrbl
index 426294d992..2918045db4 100644
--- a/collects/scribblings/guide/match.scrbl
+++ b/collects/scribblings/guide/match.scrbl
@@ -84,9 +84,9 @@ variables} that are bound in the result expressions:
(match '(1 2)
[(list x) (+ x 1)]
[(list x y) (+ x y)])
-(match (make-hat 23 'bowler)
- [(struct shoe (sz col)) sz]
- [(struct hat (sz stl)) sz])
+(match (hat 23 'bowler)
+ [(shoe sz col) sz]
+ [(hat sz stl) sz])
]
An ellipsis, written @litchar{...}, act like a Kleene star within a
diff --git a/collects/scribblings/guide/performance.scrbl b/collects/scribblings/guide/performance.scrbl
index 396a46b3c5..e1db549753 100644
--- a/collects/scribblings/guide/performance.scrbl
+++ b/collects/scribblings/guide/performance.scrbl
@@ -64,10 +64,10 @@ The module system aids optimization by helping to ensure that
identifiers have the usual bindings. That is, the @racket[+] provided
by @racketmodname[racket/base] can be recognized by the compiler and
inlined, which is especially important for @tech{JIT}-compiled code.
-In contrast, in a traditional interactive Racket system, the top-level
+In contrast, in a traditional interactive Scheme system, the top-level
@racket[+] binding might be redefined, so the compiler cannot assume a
fixed @racket[+] binding (unless special flags or declarations
-act as a poor-man's module system to indicate otherwise).
+are used to compensate for the lack of a module system).
Even in the top-level environment, importing with @racket[require]
enables some inlining optimizations. Although a @racket[+] definition
From b683ba3918a4245b50454260092c7f2833bd3cab Mon Sep 17 00:00:00 2001
From: Robby Findler
Date: Thu, 3 Feb 2011 09:02:12 -0600
Subject: [PATCH 10/68] doubled the timeout for the future random tests
---
collects/meta/props | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/collects/meta/props b/collects/meta/props
index 6159e50ac2..39b005a8ee 100755
--- a/collects/meta/props
+++ b/collects/meta/props
@@ -1465,7 +1465,7 @@ path/s is either such a string or a list of them.
"collects/tests/frtime" responsible (gcooper jay)
"collects/tests/frtime/time.rkt" drdr:command-line (gracket-text "-t" *)
"collects/tests/future" responsible (jamesswaine mflatt robby)
-"collects/tests/future/random-future.rkt" drdr:timeout 240
+"collects/tests/future/random-future.rkt" drdr:timeout 480
"collects/tests/gracket" responsible (mflatt)
"collects/tests/gracket/auto.rktl" drdr:command-line #f
"collects/tests/gracket/blits.rkt" drdr:command-line (gracket "-f" *)
From 83d2e5c151609f8c578007b5b2f74fbee8c4e71d Mon Sep 17 00:00:00 2001
From: Eli Barzilay
Date: Thu, 3 Feb 2011 10:23:16 -0500
Subject: [PATCH 11/68] Check for libracket instead of any .so file
---
collects/setup/unixstyle-install.rkt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/collects/setup/unixstyle-install.rkt b/collects/setup/unixstyle-install.rkt
index ef16708e3d..c731c6d958 100644
--- a/collects/setup/unixstyle-install.rkt
+++ b/collects/setup/unixstyle-install.rkt
@@ -383,7 +383,7 @@
(define (move/copy-distribution move?)
(define do-tree (move/copy-tree move?))
(current-directory rktdir)
- (when (ormap (lambda (p) (regexp-match #rx"[.]so" p)) (ls "lib"))
+ (when (ormap (lambda (p) (regexp-match #rx"libracket.*[.]so" p)) (ls "lib"))
(error "Cannot handle distribution of shared-libraries (yet)"))
(with-handlers ([exn? (lambda (e) (undo-changes) (raise e))])
(define binfiles (ls "bin")) ; see below
From 4344fe004ae70c41767d23f00d138eec7e0da0c5 Mon Sep 17 00:00:00 2001
From: John Clements
Date: Thu, 27 Jan 2011 10:02:21 -0800
Subject: [PATCH 12/68] added purpose statement for fn
---
collects/drracket/private/debug.rkt | 2 ++
1 file changed, 2 insertions(+)
diff --git a/collects/drracket/private/debug.rkt b/collects/drracket/private/debug.rkt
index cbf6abd678..ac148ea612 100644
--- a/collects/drracket/private/debug.rkt
+++ b/collects/drracket/private/debug.rkt
@@ -472,6 +472,8 @@ profile todo:
[(pair? cms) (list (car cms))]
[else '()])))
+ ;; show-syntax-error-context :
+ ;; display the source information associated with a syntax error (if present)
(define (show-syntax-error-context port exn)
(let ([error-text-style-delta (make-object style-delta%)]
[send-out
From b60aca2f8fe1a75d34bba01245d13af54e90ff15 Mon Sep 17 00:00:00 2001
From: John Clements
Date: Thu, 3 Feb 2011 10:24:42 -0800
Subject: [PATCH 13/68] stepper HISTORY.txt updated
---
doc/release-notes/stepper/HISTORY.txt | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/doc/release-notes/stepper/HISTORY.txt b/doc/release-notes/stepper/HISTORY.txt
index e3f0cf543e..c47a687563 100644
--- a/doc/release-notes/stepper/HISTORY.txt
+++ b/doc/release-notes/stepper/HISTORY.txt
@@ -1,5 +1,12 @@
Stepper
-------
+Changes for v5.1:
+
+Quite a bit of rackety, retabbing, refactoring. There's no longer a closure
+table, but instead functions expand into applicable structures. Cleanup of
+unnecessary function arguments. Got rid of '2vals' idiom. Improved jump
+to ... error messages.
+
Changes for v5.0.2:
Bug fixes, Big Bang working again. Define-struct in local not working.
From d2771cfb5337cb6622cc39f6f04b6ba1c7e95d65 Mon Sep 17 00:00:00 2001
From: John Clements
Date: Thu, 3 Feb 2011 10:27:20 -0800
Subject: [PATCH 14/68] added big-bang-test.rkt
---
collects/tests/stepper/big-bang-test.rkt | 10 ++++++++++
1 file changed, 10 insertions(+)
create mode 100644 collects/tests/stepper/big-bang-test.rkt
diff --git a/collects/tests/stepper/big-bang-test.rkt b/collects/tests/stepper/big-bang-test.rkt
new file mode 100644
index 0000000000..972b9f9a92
--- /dev/null
+++ b/collects/tests/stepper/big-bang-test.rkt
@@ -0,0 +1,10 @@
+;; The first three lines of this file were inserted by DrRacket. They record metadata
+;; about the language level of this file in a form that our tools can easily process.
+#reader(lib "htdp-intermediate-reader.ss" "lang")((modname big-bang-test) (read-case-sensitive #t) (teachpacks ((lib "universe.ss" "teachpack" "2htdp") (lib "image.ss" "teachpack" "2htdp"))) (htdp-settings #(#t constructor repeating-decimal #f #t none #f ((lib "universe.ss" "teachpack" "2htdp") (lib "image.ss" "teachpack" "2htdp")))))
+(define (draw-world x) (rectangle 100 (round (* x 0.1)) "solid" "red"))
+
+(draw-world 500)
+
+(big-bang 0
+ [on-tick add1]
+ [to-draw draw-world 500 500])
\ No newline at end of file
From 528948291ddfe3ef07f7216946628553928c20f6 Mon Sep 17 00:00:00 2001
From: Kevin Tew
Date: Thu, 3 Feb 2011 13:13:23 -0700
Subject: [PATCH 15/68] Fix creation of types and events after the master gc
has been switched out
---
src/racket/gc2/gc2.h | 7 +++
src/racket/gc2/newgc.c | 6 +++
src/racket/include/schthread.h | 4 ++
src/racket/src/thread.c | 86 +++++++++++++++++++++++-----------
src/racket/src/type.c | 13 ++++-
5 files changed, 87 insertions(+), 29 deletions(-)
diff --git a/src/racket/gc2/gc2.h b/src/racket/gc2/gc2.h
index ccf513479f..957186bcf8 100644
--- a/src/racket/gc2/gc2.h
+++ b/src/racket/gc2/gc2.h
@@ -484,6 +484,13 @@ GC2_EXTERN void GC_adopt_message_allocator(void *msg_memory);
the current receiving place's gc
*/
+GC2_EXTERN intptr_t GC_is_place();
+/*
+ Returns 1 if current GC is a place gc.
+ Otherwise returns 0;
+*/
+
+
# ifdef __cplusplus
};
diff --git a/src/racket/gc2/newgc.c b/src/racket/gc2/newgc.c
index 5dab1d7835..7188f5a475 100644
--- a/src/racket/gc2/newgc.c
+++ b/src/racket/gc2/newgc.c
@@ -152,6 +152,12 @@ inline static int postmaster_and_master_gc(NewGC *gc) {
inline static int postmaster_and_place_gc(NewGC *gc) {
return (MASTERGC && gc != MASTERGC);
}
+
+intptr_t GC_is_place() {
+ NewGC *gc = GC_get_GC();
+ return postmaster_and_place_gc(gc);
+}
+
static void master_collect_initiate(NewGC *gc);
#endif
diff --git a/src/racket/include/schthread.h b/src/racket/include/schthread.h
index 59f81f1199..39a808bea9 100644
--- a/src/racket/include/schthread.h
+++ b/src/racket/include/schthread.h
@@ -307,6 +307,8 @@ typedef struct Thread_Local_Variables {
struct FFI_Sync_Queue *ffi_sync_queue_;
struct Scheme_GC_Pre_Post_Callback_Desc *gc_prepost_callback_descs_;
struct Scheme_Hash_Table *place_local_misc_table_;
+ int place_evts_array_size_;
+ struct Evt **place_evts_;
} Thread_Local_Variables;
#if defined(IMPLEMENT_THREAD_LOCAL_VIA_PTHREADS)
@@ -619,6 +621,8 @@ XFORM_GC_VARIABLE_STACK_THROUGH_THREAD_LOCAL;
#define ffi_sync_queue XOA (scheme_get_thread_local_variables()->ffi_sync_queue_)
#define gc_prepost_callback_descs XOA (scheme_get_thread_local_variables()->gc_prepost_callback_descs_)
#define place_local_misc_table XOA (scheme_get_thread_local_variables()->place_local_misc_table_)
+#define place_evts_array_size XOA (scheme_get_thread_local_variables()->place_evts_array_size_)
+#define place_evts XOA (scheme_get_thread_local_variables()->place_evts_)
/* **************************************** */
diff --git a/src/racket/src/thread.c b/src/racket/src/thread.c
index 85697facc9..32af2b0364 100644
--- a/src/racket/src/thread.c
+++ b/src/racket/src/thread.c
@@ -240,6 +240,10 @@ THREAD_LOCAL_DECL(static int recycle_cc_count);
THREAD_LOCAL_DECL(struct Scheme_Hash_Table *place_local_misc_table);
+#if defined(MZ_PRECISE_GC) && defined(MZ_USE_PLACES)
+extern intptr_t GC_is_place();
+#endif
+
#ifdef MZ_PRECISE_GC
extern intptr_t GC_get_memory_use(void *c);
@@ -5435,31 +5439,31 @@ typedef struct Evt {
/* PLACE_THREAD_DECL */
-FIXME_LATER static int evts_array_size;
-FIXME_LATER static Evt **evts;
+static int evts_array_size;
+static Evt **evts;
+THREAD_LOCAL_DECL(static int place_evts_array_size);
+THREAD_LOCAL_DECL(static Evt **place_evts);
-void scheme_add_evt(Scheme_Type type,
- Scheme_Ready_Fun ready,
- Scheme_Needs_Wakeup_Fun wakeup,
- Scheme_Sync_Filter_Fun filter,
- int can_redirect)
+void scheme_add_evt_worker(Evt ***evt_array,
+ int *evt_size,
+ Scheme_Type type,
+ Scheme_Ready_Fun ready,
+ Scheme_Needs_Wakeup_Fun wakeup,
+ Scheme_Sync_Filter_Fun filter,
+ int can_redirect)
{
Evt *naya;
- if (!evts) {
- REGISTER_SO(evts);
- }
-
- if (evts_array_size <= type) {
+ if (*evt_size <= type) {
Evt **nevts;
int new_size;
new_size = type + 1;
if (new_size < _scheme_last_type_)
new_size = _scheme_last_type_;
nevts = MALLOC_N(Evt*, new_size);
- memcpy(nevts, evts, evts_array_size * sizeof(Evt*));
- evts = nevts;
- evts_array_size = new_size;
+ memcpy(nevts, (*evt_array), (*evt_size) * sizeof(Evt*));
+ (*evt_array) = nevts;
+ (*evt_size) = new_size;
}
naya = MALLOC_ONE_RT(Evt);
@@ -5472,7 +5476,31 @@ void scheme_add_evt(Scheme_Type type,
naya->filter = filter;
naya->can_redirect = can_redirect;
- evts[type] = naya;
+ (*evt_array)[type] = naya;
+}
+
+void scheme_add_evt(Scheme_Type type,
+ Scheme_Ready_Fun ready,
+ Scheme_Needs_Wakeup_Fun wakeup,
+ Scheme_Sync_Filter_Fun filter,
+ int can_redirect)
+{
+#if defined(MZ_PRECISE_GC) && defined(MZ_USE_PLACES)
+ if (GC_is_place()) {
+ if (!place_evts) {
+ REGISTER_SO(place_evts);
+ }
+ scheme_add_evt_worker(&place_evts, &place_evts_array_size, type, ready, wakeup, filter, can_redirect);
+ }
+ else {
+#endif
+ if (!evts) {
+ REGISTER_SO(evts);
+ }
+ scheme_add_evt_worker(&evts, &evts_array_size, type, ready, wakeup, filter, can_redirect);
+#if defined(MZ_PRECISE_GC) && defined(MZ_USE_PLACES)
+ }
+#endif
}
void scheme_add_evt_through_sema(Scheme_Type type,
@@ -5486,21 +5514,23 @@ void scheme_add_evt_through_sema(Scheme_Type type,
static Evt *find_evt(Scheme_Object *o)
{
Scheme_Type t;
- Evt *w;
+ Evt *w = NULL;
t = SCHEME_TYPE(o);
- w = evts[t];
- if (w) {
- if (w->filter) {
- Scheme_Sync_Filter_Fun filter;
- filter = w->filter;
- if (!filter(o))
- return NULL;
- }
- return w;
- }
+ if (t < evts_array_size)
+ w = evts[t];
+#if defined(MZ_PRECISE_GC) && defined(MZ_USE_PLACES)
+ if (place_evts && w == NULL)
+ w = place_evts[t];
+#endif
- return NULL;
+ if (w && w->filter) {
+ Scheme_Sync_Filter_Fun filter;
+ filter = w->filter;
+ if (!filter(o))
+ return NULL;
+ }
+ return w;
}
int scheme_is_evt(Scheme_Object *o)
diff --git a/src/racket/src/type.c b/src/racket/src/type.c
index 07e66682d3..e2af1f9bb8 100644
--- a/src/racket/src/type.c
+++ b/src/racket/src/type.c
@@ -289,6 +289,12 @@ scheme_init_type ()
Scheme_Type scheme_make_type(const char *name)
{
+ Scheme_Type newtype;
+#if defined(MZ_USE_PLACES) && defined(MZ_PRECISE_GC)
+ void *saved_gc;
+ saved_gc = GC_switch_to_master_gc();
+#endif
+
if (!type_names)
init_type_arrays();
@@ -341,7 +347,12 @@ Scheme_Type scheme_make_type(const char *name)
type_names[maxtype] = tn;
}
- return maxtype++;
+ newtype = maxtype;
+ maxtype++;
+#if defined(MZ_USE_PLACES) && defined(MZ_PRECISE_GC)
+ GC_switch_back_from_master(saved_gc);
+#endif
+ return newtype;
}
char *scheme_get_type_name(Scheme_Type t)
From 2fe690b29ebe2c0df572b25f675051e3f0232d3f Mon Sep 17 00:00:00 2001
From: Eli Barzilay
Date: Thu, 3 Feb 2011 15:55:44 -0500
Subject: [PATCH 16/68] Try to kill the test thread after a minute, and exit
after another minute.
---
collects/tests/run-automated-tests.rkt | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/collects/tests/run-automated-tests.rkt b/collects/tests/run-automated-tests.rkt
index de5ce084a1..6fb9427d53 100755
--- a/collects/tests/run-automated-tests.rkt
+++ b/collects/tests/run-automated-tests.rkt
@@ -73,7 +73,13 @@
(lambda ()
(sleep (* 60 timeout))
(echo "Timeout!")
- (break-thread th)))))
+ (break-thread th)
+ (sleep 60)
+ (echo " A minute has passed, killing the test thread!")
+ (kill-thread th)
+ (sleep 60)
+ (echo " Another minute passed, aborting!")
+ (abort 1 "Goodbye.")))))
(parameterize* ([exit-handler
(lambda (n) (abort n "exit with error code ~a" n))]
[current-namespace (make-base-empty-namespace)])
From e4c4170d31282835a7382a0f7143f6e1cce2adc5 Mon Sep 17 00:00:00 2001
From: John Clements
Date: Thu, 3 Feb 2011 14:16:59 -0800
Subject: [PATCH 17/68] updated props in test dir
---
collects/meta/props | 1 +
collects/tests/stepper/universe-test.rkt | 11 -----------
2 files changed, 1 insertion(+), 11 deletions(-)
delete mode 100644 collects/tests/stepper/universe-test.rkt
diff --git a/collects/meta/props b/collects/meta/props
index 39b005a8ee..66a39d23e0 100755
--- a/collects/meta/props
+++ b/collects/meta/props
@@ -1899,6 +1899,7 @@ path/s is either such a string or a list of them.
"collects/tests/stepper/already-defined.rktl" drdr:command-line #f
"collects/tests/stepper/automatic-tests.rkt" drdr:timeout 600
"collects/tests/stepper/bad-letrec-test.rktl" drdr:command-line #f
+"collects/tests/stepper/big-bang-test.rkt" drdr:command-line (mzc *)
"collects/tests/stepper/constructor-redexes.rktl" drdr:command-line #f
"collects/tests/stepper/global-prim-reduction.rktl" drdr:command-line #f
"collects/tests/stepper/image-test.rktl" drdr:command-line #f
diff --git a/collects/tests/stepper/universe-test.rkt b/collects/tests/stepper/universe-test.rkt
deleted file mode 100644
index a03203778c..0000000000
--- a/collects/tests/stepper/universe-test.rkt
+++ /dev/null
@@ -1,11 +0,0 @@
-;; The first three lines of this file were inserted by DrRacket. They record metadata
-;; about the language level of this file in a form that our tools can easily process.
-#reader(lib "htdp-intermediate-reader.ss" "lang")((modname universe-test) (read-case-sensitive #t) (teachpacks ((lib "universe.ss" "teachpack" "2htdp") (lib "image.ss" "teachpack" "2htdp"))) (htdp-settings #(#t constructor repeating-decimal #f #t none #f ((lib "universe.ss" "teachpack" "2htdp") (lib "image.ss" "teachpack" "2htdp")))))
-(define (zug state)
- (overlay
- (rectangle 100 state "solid" "blue")
- (rectangle 100 200 "solid" "red")))
-
-(big-bang 14
- (on-tick add1)
- (to-draw zug))
\ No newline at end of file
From 6099806a7209d0d9e4ba85412dac0e13d8910111 Mon Sep 17 00:00:00 2001
From: Sam Tobin-Hochstadt
Date: Mon, 31 Jan 2011 10:44:59 -0500
Subject: [PATCH 18/68] codeblock: fix language regexp to accept numbers in
#lang
---
collects/scribble/private/manual-code.rkt | 2 +-
collects/tests/racket/benchmarks/common/conform.scm | 2 ++
2 files changed, 3 insertions(+), 1 deletion(-)
create mode 100644 collects/tests/racket/benchmarks/common/conform.scm
diff --git a/collects/scribble/private/manual-code.rkt b/collects/scribble/private/manual-code.rkt
index 1ad662ad52..6c0835176c 100644
--- a/collects/scribble/private/manual-code.rkt
+++ b/collects/scribble/private/manual-code.rkt
@@ -121,7 +121,7 @@
[else null]))]
[has-hash-lang? (regexp-match? #rx"^#lang " bstr)]
[language (if has-hash-lang?
- (let ([m (regexp-match #rx"^#lang ([-a-zA-Z/._+]+)" bstr)])
+ (let ([m (regexp-match #rx"^#lang ([-0-9a-zA-Z/._+]+)" bstr)])
(if m
(link-mod
#:orig? #t
diff --git a/collects/tests/racket/benchmarks/common/conform.scm b/collects/tests/racket/benchmarks/common/conform.scm
new file mode 100644
index 0000000000..2573bc24fa
--- /dev/null
+++ b/collects/tests/racket/benchmarks/common/conform.scm
@@ -0,0 +1,2 @@
+(load "r5rs-wrap.rktl")
+(load "conform.sch")
From c9519fd11300b07292df8619e86f48533eff6e4d Mon Sep 17 00:00:00 2001
From: David Van Horn
Date: Wed, 2 Feb 2011 14:56:42 -0500
Subject: [PATCH 19/68] Fixed various spelling errors.
---
.../tests/image-equality-performance-htdp.rkt | 2 +-
.../2htdp/tests/image-equality-performance.rkt | 2 +-
collects/compiler/private/vmphase.rkt | 2 +-
collects/embedded-gui/doc.txt | 2 +-
.../embedded-gui/scribblings/embedded-gui.scrbl | 2 +-
collects/framework/main.rkt | 2 +-
collects/framework/private/scheme.rkt | 2 +-
collects/frtime/doc.txt | 2 +-
collects/frtime/gui/doc.txt | 2 +-
collects/honu/core/private/honu.rkt | 2 +-
collects/htdp/tests/guess-gui.rkt | 2 +-
collects/lazy/force.rkt | 2 +-
collects/mred/private/wx/cocoa/gauge.rkt | 2 +-
collects/mred/private/wx/gtk/frame.rkt | 2 +-
collects/mred/private/wx/win32/gl-context.rkt | 2 +-
collects/mred/private/wxme/editor-snip.rkt | 2 +-
collects/mred/private/wxme/mline.rkt | 2 +-
collects/mrlib/image-core.rkt | 2 +-
.../geometry-managed-pasteboard.rkt | 2 +-
collects/mrlib/private/image-core-bitmap.rkt | 2 +-
collects/mzlib/kw.rkt | 2 +-
collects/mzlib/thread.rkt | 2 +-
collects/mzscheme/examples/README | 2 +-
collects/openssl/mzssl.rkt | 2 +-
collects/parser-tools/lex.rkt | 2 +-
collects/parser-tools/private-yacc/grammar.rkt | 2 +-
collects/planet/private/short-syntax-helpers.rkt | 2 +-
collects/plot/fit.rkt | 14 +++++++-------
collects/plot/math.rkt | 2 +-
collects/plot/plot.rkt | 2 +-
collects/racket/private/serialize.rkt | 2 +-
collects/redex/redex.scrbl | 2 +-
collects/scribblings/framework/canvas.scrbl | 2 +-
collects/scribblings/framework/editor.scrbl | 2 +-
collects/scribblings/framework/text.scrbl | 2 +-
collects/scribblings/guide/simple-syntax.scrbl | 2 +-
collects/scribblings/raco/exe-api.scrbl | 2 +-
collects/scribblings/reference/contracts.scrbl | 4 ++--
collects/scribblings/reference/control-lib.scrbl | 2 +-
collects/scribblings/reference/networking.scrbl | 2 +-
collects/scribblings/reference/reader.scrbl | 2 +-
collects/scribblings/tools/rep.scrbl | 10 +++++-----
collects/scribblings/tools/tools.scrbl | 2 +-
collects/sirmail/readr.rkt | 2 +-
collects/srfi/26/cut.rkt | 2 +-
collects/srfi/optional.rkt | 4 ++--
collects/srpersist/doc.txt | 2 +-
collects/stepper/private/lifting.rkt | 2 +-
collects/syntax-color/paren-tree.rkt | 4 ++--
collects/syntax/doc.txt | 2 +-
collects/syntax/scribblings/modcode.scrbl | 2 +-
collects/syntax/scribblings/parse/intro.scrbl | 2 +-
collects/teachpack/2htdp/scribblings/image.scrbl | 4 ++--
collects/tests/drracket/drracket-test-util.rkt | 2 +-
.../typed-scheme/scribblings/ts-reference.scrbl | 2 +-
collects/typed-scheme/typecheck/tc-app.rkt | 2 +-
collects/unstable/scribblings/gui/slideshow.scrbl | 2 +-
collects/web-server/private/configure.rkt | 2 +-
collects/web-server/scribblings/contracts.scrbl | 2 +-
collects/web-server/scribblings/web.scrbl | 2 +-
doc/release-notes/drracket/HISTORY.txt | 4 ++--
doc/release-notes/gracket/HISTORY.txt | 4 ++--
doc/release-notes/racket/HISTORY.txt | 2 +-
doc/srfi-std/srfi-4.html | 2 +-
doc/srfi-std/srfi-40.html | 2 +-
doc/srfi-std/srfi-67/srfi-67.html | 2 +-
doc/srfi-std/srfi-98.html | 2 +-
src/foreign/libffi/src/dlmalloc.c | 2 +-
src/foreign/libffi/src/x86/ffi64.c | 2 +-
src/foreign/libffi/texinfo.tex | 6 +++---
src/plot/plplot/plmap.c | 2 +-
src/plot/plplot/plplot.h | 2 +-
src/plot/plplot/plplotP.h | 4 ++--
src/plot/plplot/plshade.c | 4 ++--
src/plot/plplot/plsym.c | 4 ++--
src/racket/gc/Makefile.dj | 2 +-
src/racket/gc/doc/README.changes | 2 +-
src/racket/gc/dyn_load.c | 2 +-
src/racket/gc/win32_threads.c | 2 +-
src/racket/include/scheme.h | 2 +-
src/racket/sgc/sgc.c | 2 +-
src/racket/src/dlcompat.inc | 2 +-
src/racket/src/jit.c | 4 ++--
src/racket/src/portfun.c | 2 +-
src/racket/src/regexp.c | 2 +-
src/racket/src/thread.c | 2 +-
86 files changed, 108 insertions(+), 108 deletions(-)
diff --git a/collects/2htdp/tests/image-equality-performance-htdp.rkt b/collects/2htdp/tests/image-equality-performance-htdp.rkt
index 547c0c9286..cf04ed3989 100644
--- a/collects/2htdp/tests/image-equality-performance-htdp.rkt
+++ b/collects/2htdp/tests/image-equality-performance-htdp.rkt
@@ -411,7 +411,7 @@ Also added the timing code at the end.
;;purpose :given the board ,square to be played,column and row label and returns a new board
-;;with the square to be played at the position reffered
+;;with the square to be played at the position referred
;; play-on-board : board square symbol symbol -> board
;;test
diff --git a/collects/2htdp/tests/image-equality-performance.rkt b/collects/2htdp/tests/image-equality-performance.rkt
index 1c76b51030..19808deed0 100644
--- a/collects/2htdp/tests/image-equality-performance.rkt
+++ b/collects/2htdp/tests/image-equality-performance.rkt
@@ -416,7 +416,7 @@ Also added the timing code at the end.
;;purpose :given the board ,square to be played,column and row label and returns a new board
-;;with the square to be played at the position reffered
+;;with the square to be played at the position referred
;; play-on-board : board square symbol symbol -> board
;;test
diff --git a/collects/compiler/private/vmphase.rkt b/collects/compiler/private/vmphase.rkt
index 8bf7fc7324..acbeb71a80 100644
--- a/collects/compiler/private/vmphase.rkt
+++ b/collects/compiler/private/vmphase.rkt
@@ -803,7 +803,7 @@
;; distinguish between tail & non-tail calls
;; implement tail calls to "simple" primitives a regular calls
;; no need to pass anything to tail here because it's already
- ;; a tail value if its a tail-apply
+ ;; a tail value if it's a tail-apply
;; the vm-optimizer will refine the multi-ness of this application,
;; and worry about inter & intra-vehicle calls
;;
diff --git a/collects/embedded-gui/doc.txt b/collects/embedded-gui/doc.txt
index f528ab78b6..09ff60afa1 100644
--- a/collects/embedded-gui/doc.txt
+++ b/collects/embedded-gui/doc.txt
@@ -257,7 +257,7 @@ alignment<%>.
_stretchable-editor-snip-mixin_ gives an editor snip the
_stretchable-snip<%>_ interface allowing it to be stretched
-to fit it's alignment-parent<%>'s alloted width. Stretchable
+to fit its alignment-parent<%>'s alloted width. Stretchable
snips are useful as the snip of a snip-wrapper%.
_stretchable-editor-snip%_ is (stretcable-editor-snip-mixin editor-snip%)
diff --git a/collects/embedded-gui/scribblings/embedded-gui.scrbl b/collects/embedded-gui/scribblings/embedded-gui.scrbl
index 2d5bd51a5e..e8c937fe7f 100644
--- a/collects/embedded-gui/scribblings/embedded-gui.scrbl
+++ b/collects/embedded-gui/scribblings/embedded-gui.scrbl
@@ -81,7 +81,7 @@ t hat are labeled from a particular set of strings.}
Sets the tabbing order of @scheme[tabbable-text<%>]s by setting each
text's @method[tabbable-text<%> set-ahead] and
-@method[tabbable-text<%> set-back] thunks to point to it's neighbor in
+@method[tabbable-text<%> set-back] thunks to point to its neighbor in
the argument list.}
diff --git a/collects/framework/main.rkt b/collects/framework/main.rkt
index 85c921a59c..82b15b12dd 100644
--- a/collects/framework/main.rkt
+++ b/collects/framework/main.rkt
@@ -802,7 +802,7 @@
@scheme[filename].
@itemize[
@item{If a handler is found, it is applied to
- @scheme[filename] and it's result is the final
+ @scheme[filename] and its result is the final
result.}
@item{If not, @scheme[make-default] is used.}]}]}
@item{If @scheme[filename] is @scheme[#f], @scheme[make-default] is
diff --git a/collects/framework/private/scheme.rkt b/collects/framework/private/scheme.rkt
index be69a203af..6bf517c16c 100644
--- a/collects/framework/private/scheme.rkt
+++ b/collects/framework/private/scheme.rkt
@@ -604,7 +604,7 @@
[(not contains)
;; Something went wrong matching. Should we get here?
(do-indent 0)]
- #; ;; disable this to accomodate PLAI programs; return to this when a #lang capability is set up.
+ #; ;; disable this to accommodate PLAI programs; return to this when a #lang capability is set up.
[(curley-brace-sexp?)
;; when we are directly inside an sexp that uses {}s,
;; we indent in a more C-like fashion (to help Scribble)
diff --git a/collects/frtime/doc.txt b/collects/frtime/doc.txt
index 30fb635df5..452a9256e1 100644
--- a/collects/frtime/doc.txt
+++ b/collects/frtime/doc.txt
@@ -278,7 +278,7 @@ Generates a mixin that sends an event on stream-name when
callback is called. The class has an init field called
[stream-name]-event-processor, which is a function. The
function is applied to an event stream that has an
-occurence every time callback is called, and the value
+occurrence every time callback is called, and the value
of the events is a list of the arguments to the callback.
The public method (get-[stream-name]) is a public method
of the resulting class that gets the result of applying
diff --git a/collects/frtime/gui/doc.txt b/collects/frtime/gui/doc.txt
index 4d5c3a246b..568ee054d9 100644
--- a/collects/frtime/gui/doc.txt
+++ b/collects/frtime/gui/doc.txt
@@ -32,7 +32,7 @@ when the event should just be the value of the first
argument of the callback. split-*-events/type sets up an
appropriate split (see FrTime docs for split information,
GRacket docs for key-event codes and mouse-event types) over
-the type of event occurence.
+the type of event occurrence.
events->callbacks and callbacks->args-evts are the backbone
diff --git a/collects/honu/core/private/honu.rkt b/collects/honu/core/private/honu.rkt
index 2661df35a6..ff0b705ce5 100644
--- a/collects/honu/core/private/honu.rkt
+++ b/collects/honu/core/private/honu.rkt
@@ -1026,7 +1026,7 @@
(if (eq? #t (syntax-e #'type-name))
;; Context guarantees correct use, as long as we report our type:
#'(honu-report-type val orig-expr val-type protect-id)
- ;; Context gurantees use at a particular type...
+ ;; Context guarantees use at a particular type...
(if (check-compatible-type #'val #'orig-expr #'val-type #'type-name type-mismatch)
;; Declared type subsumes actual type:
(if (and (syntax-e #'protect-id)
diff --git a/collects/htdp/tests/guess-gui.rkt b/collects/htdp/tests/guess-gui.rkt
index f1c9d82576..68feb1c9c7 100644
--- a/collects/htdp/tests/guess-gui.rkt
+++ b/collects/htdp/tests/guess-gui.rkt
@@ -11,7 +11,7 @@
;; convert : (listof DIGIT) -> number
;; to convert a list of digits into a number
-;; the leading digit is the least signifcant one
+;; the leading digit is the least significant one
(define (convert alod)
(cond
[(empty? alod) 0]
diff --git a/collects/lazy/force.rkt b/collects/lazy/force.rkt
index 06280dca71..d89f336266 100644
--- a/collects/lazy/force.rkt
+++ b/collects/lazy/force.rkt
@@ -9,7 +9,7 @@
(define ~? promise?)
;; force a top-level list structure; works with improper lists (will force the
-;; dotted item when it checks if its a pair); does not handle cycles
+;; dotted item when it checks if it's a pair); does not handle cycles
(define (!list x)
(let ([x (! x)])
(if (list? x) ; cheap check,
diff --git a/collects/mred/private/wx/cocoa/gauge.rkt b/collects/mred/private/wx/cocoa/gauge.rkt
index 153b821b18..caab798559 100644
--- a/collects/mred/private/wx/cocoa/gauge.rkt
+++ b/collects/mred/private/wx/cocoa/gauge.rkt
@@ -33,7 +33,7 @@
(super-new [parent parent]
[cocoa (let ([cocoa (as-objc-allocation
;; Beware that a guage may be finally deallocated in
- ;; a seperate OS-level thread
+ ;; a separate OS-level thread
(tell (tell MyProgressIndicator alloc) init))])
(tellv cocoa setIndeterminate: #:type _BOOL #f)
(tellv cocoa setMaxValue: #:type _double* rng)
diff --git a/collects/mred/private/wx/gtk/frame.rkt b/collects/mred/private/wx/gtk/frame.rkt
index 8c43cf8e9e..7db96daf3b 100644
--- a/collects/mred/private/wx/gtk/frame.rkt
+++ b/collects/mred/private/wx/gtk/frame.rkt
@@ -216,7 +216,7 @@
(adjust-client-delta 0 h))
;; Hack: calls back into the mred layer to re-compute
;; sizes. By calling this early enough, the frame won't
- ;; grow if it doesn't have to grow to accomodate the menu bar.
+ ;; grow if it doesn't have to grow to accommodate the menu bar.
(send this resized))
(define saved-enforcements (vector 0 0 -1 -1))
diff --git a/collects/mred/private/wx/win32/gl-context.rkt b/collects/mred/private/wx/win32/gl-context.rkt
index 3da5c6e3f1..f7b8f0ce08 100644
--- a/collects/mred/private/wx/win32/gl-context.rkt
+++ b/collects/mred/private/wx/win32/gl-context.rkt
@@ -137,7 +137,7 @@
PFD_SUPPORT_GDI)
(bitwise-ior PFD_DRAW_TO_WINDOW)))
PFD_TYPE_RGBA ; color type
- (if offscreen? 32 24) ; prefered color depth
+ (if offscreen? 32 24) ; preferred color depth
0 0 0 0 0 0 ; color bits (ignored)
0 ; no alpha buffer
0 ; alpha bits (ignored)
diff --git a/collects/mred/private/wxme/editor-snip.rkt b/collects/mred/private/wxme/editor-snip.rkt
index 14f573695b..0d715396a7 100644
--- a/collects/mred/private/wxme/editor-snip.rkt
+++ b/collects/mred/private/wxme/editor-snip.rkt
@@ -111,7 +111,7 @@
(when (and s-admin
(has-flag? s-flags USES-BUFFER-PATH))
- ;; propogate a filename change:
+ ;; propagate a filename change:
(if (and editor
(no-permanent-filename? editor))
(let ([b (send s-admin get-editor)])
diff --git a/collects/mred/private/wxme/mline.rkt b/collects/mred/private/wxme/mline.rkt
index 6d81eac8d0..0794bb893f 100644
--- a/collects/mred/private/wxme/mline.rkt
+++ b/collects/mred/private/wxme/mline.rkt
@@ -1039,7 +1039,7 @@ Debugging tools:
[next (mline-next mline)])
(when (or (not (eq? (mline-snip next) asnip))
(not (has-flag? (snip->flags (mline-last-snip next)) NEWLINE)))
- ;; Effect can propogate to more lines, merging the
+ ;; Effect can propagate to more lines, merging the
;; next several. (Handle prefixing the remains of the source of
;; the extension to this line onto the next line. Implemented
;; as the next line eating the next->next line.)
diff --git a/collects/mrlib/image-core.rkt b/collects/mrlib/image-core.rkt
index 3cbd78905d..8df14e75b3 100644
--- a/collects/mrlib/image-core.rkt
+++ b/collects/mrlib/image-core.rkt
@@ -255,7 +255,7 @@ has been moved out).
(or (and (not (skip-image-equality-fast-path)) ;; this is here to make testing more effective
(equal? (get-normalized-shape) (send that get-normalized-shape)))
(let ([w (+ 1 (round (inexact->exact (bb-right bb))))] ;; some shapes (ie, rectangles) draw 1 outside the bounding box
- [h (+ 1 (round (inexact->exact (bb-bottom bb))))]) ;; so we make the bitmap slightly bigger to accomodate that.
+ [h (+ 1 (round (inexact->exact (bb-bottom bb))))]) ;; so we make the bitmap slightly bigger to accommodate that.
(or ;(zero? w)
;(zero? h)
(let ([bm1 (make-bitmap w h #t)]
diff --git a/collects/mrlib/private/aligned-pasteboard/geometry-managed-pasteboard.rkt b/collects/mrlib/private/aligned-pasteboard/geometry-managed-pasteboard.rkt
index 9d5e2abe5c..2773b2e794 100644
--- a/collects/mrlib/private/aligned-pasteboard/geometry-managed-pasteboard.rkt
+++ b/collects/mrlib/private/aligned-pasteboard/geometry-managed-pasteboard.rkt
@@ -50,7 +50,7 @@
(get-aligned-min-sizes type (find-first-snip)))))
;; set-algined-min-sizes (-> void?)
- ;; set the aligned min width and height of the pasteboard based on it's children snips
+ ;; set the aligned min width and height of the pasteboard based on its children snips
(inherit in-edit-sequence?)
(define/public (aligned-min-sizes-invalid)
;; This in-edit-sequence? is not sound. It causes me to percollate invalidation
diff --git a/collects/mrlib/private/image-core-bitmap.rkt b/collects/mrlib/private/image-core-bitmap.rkt
index 9b694af253..6a56a7f096 100644
--- a/collects/mrlib/private/image-core-bitmap.rkt
+++ b/collects/mrlib/private/image-core-bitmap.rkt
@@ -27,7 +27,7 @@ instead of this scaling code, we use the dc<%>'s scaling code.
; bmbytes: a bytes which represents an image --
-; it's size is a multiple of 4, and each
+; its size is a multiple of 4, and each
; four consecutive bytes represent alpha,r,g,b.
diff --git a/collects/mzlib/kw.rkt b/collects/mzlib/kw.rkt
index 66456276c1..014f5969dd 100644
--- a/collects/mzlib/kw.rkt
+++ b/collects/mzlib/kw.rkt
@@ -128,7 +128,7 @@
[else (ormap (lambda (k) (and (assq k rests) #t)) ; suggested?
(car (cddddr processed-spec)))])))
(define (make-keyword-get-expr key rest default known-vars)
- ;; expand (for id macros) and check if its a simple expression, because if
+ ;; expand (for id macros) and check if it's a simple expression, because if
;; it is, evaluation cannot have side-effects and we can use keyword-get*
(define default*
(local-expand default 'expression (cons #'#%app known-vars)))
diff --git a/collects/mzlib/thread.rkt b/collects/mzlib/thread.rkt
index 4c4d00585a..c4bcf7a798 100644
--- a/collects/mzlib/thread.rkt
+++ b/collects/mzlib/thread.rkt
@@ -7,7 +7,7 @@
#|
t accepts a function, f, and creates a thread. It returns the thread and a
- function, g. When g is applied it passes it's argument to f, and evaluates
+ function, g. When g is applied it passes its argument to f, and evaluates
the call of f in the time of the thread that was created. Calls to g do not
block.
|#
diff --git a/collects/mzscheme/examples/README b/collects/mzscheme/examples/README
index ee128c7580..a90d33a2da 100644
--- a/collects/mzscheme/examples/README
+++ b/collects/mzscheme/examples/README
@@ -28,7 +28,7 @@ end use the mzc `c-lambda', etc. forms.
exceptions while evaluating a string. Demonstrates how to catch
exceptions from C code.
- * bitmatrix.c - implements two-dimentional bit matrixes with some
+ * bitmatrix.c - implements two-dimensional bit matrixes with some
operations. Demonstrates defining a new Scheme data type, data
allocation, fancy integer type checking, general exception raising,
and registering static variables. Also demonstrates supplying
diff --git a/collects/openssl/mzssl.rkt b/collects/openssl/mzssl.rkt
index d2ec22b506..6bfca6e48a 100644
--- a/collects/openssl/mzssl.rkt
+++ b/collects/openssl/mzssl.rkt
@@ -185,7 +185,7 @@
(define-mzscheme scheme_end_atomic (-> _void))
(define-mzscheme scheme_make_custodian (_pointer -> _scheme))
- ;; Make this bigger than 4096 to accomodate at least
+ ;; Make this bigger than 4096 to accommodate at least
;; 4096 of unencrypted data
(define BUFFER-SIZE 8000)
diff --git a/collects/parser-tools/lex.rkt b/collects/parser-tools/lex.rkt
index e9983ab962..2db2ecbb8f 100644
--- a/collects/parser-tools/lex.rkt
+++ b/collects/parser-tools/lex.rkt
@@ -252,7 +252,7 @@
;; including a match at the current state
(longest-match-action
(vector-ref actions start-state))
- ;; how many bytes preceed char
+ ;; how many bytes precede char
(length-bytes 0)
;; how many characters have been read
;; including the one just read
diff --git a/collects/parser-tools/private-yacc/grammar.rkt b/collects/parser-tools/private-yacc/grammar.rkt
index dd71a88fbd..fe20c5a361 100644
--- a/collects/parser-tools/private-yacc/grammar.rkt
+++ b/collects/parser-tools/private-yacc/grammar.rkt
@@ -12,7 +12,7 @@
(define-struct prod (lhs rhs index prec action) (make-inspector))
;; The dot-pos field is the index of the element in the rhs
- ;; of prod that the dot immediately preceeds.
+ ;; of prod that the dot immediately precedes.
;; Thus 0 <= dot-pos <= (vector-length rhs).
(define-struct item (prod dot-pos) (make-inspector))
diff --git a/collects/planet/private/short-syntax-helpers.rkt b/collects/planet/private/short-syntax-helpers.rkt
index df517cca4f..10c7808c9d 100644
--- a/collects/planet/private/short-syntax-helpers.rkt
+++ b/collects/planet/private/short-syntax-helpers.rkt
@@ -38,7 +38,7 @@
;; parse-package : string (string -> 'a) -> (values string nat min-spec)
;; given a package specifier, returns the package name, the package major version, and a descriptor
-;; for the acceptible minor versions
+;; for the acceptable minor versions
(define (parse-package package yell)
(try-parsing package
([pkgname (get-to-next-colon-or-end)]
diff --git a/collects/plot/fit.rkt b/collects/plot/fit.rkt
index a3b388a7a1..437c8eab22 100644
--- a/collects/plot/fit.rkt
+++ b/collects/plot/fit.rkt
@@ -15,24 +15,24 @@
; fit-int : (number* -> number) (list-of (symbol number)) (list-of (vector number [number] number number)) -> fit-result
(define (fit-int function guesses data)
- (let* ((independant-vars (- (procedure-arity function) (length guesses)))
+ (let* ((independent-vars (- (procedure-arity function) (length guesses)))
(f-of-x-y (cond
- [(= 1 independant-vars)
+ [(= 1 independent-vars)
(lambda (x y . rest)
(apply function x rest))]
- [(= 2 independant-vars)
+ [(= 2 independent-vars)
function]
[else
- (error "Function provided is eitehr not of one or two independant variables or the number of
+ (error "Function provided is either not of one or two independent variables or the number of
guesses given is incorrect")]))
(x-vals (map vector-x data))
- (y-vals (if (= 1 independant-vars)
+ (y-vals (if (= 1 independent-vars)
x-vals
(map vector-y data)))
- (z-vals (if (= 1 independant-vars)
+ (z-vals (if (= 1 independent-vars)
(map vector-y data)
(map vector-z data)))
- (err-vals (if (= 1 independant-vars)
+ (err-vals (if (= 1 independent-vars)
(map vector-z data)
(map (lambda (vec) (vector-ref vec 4)) data)))
(result (fit-internal f-of-x-y x-vals y-vals z-vals err-vals (map cadr guesses))))
diff --git a/collects/plot/math.rkt b/collects/plot/math.rkt
index 7019ce2826..a8ef955d88 100644
--- a/collects/plot/math.rkt
+++ b/collects/plot/math.rkt
@@ -4,7 +4,7 @@
(require mzlib/list mzlib/etc mzlib/math)
- ; using vectors for n-dimentional points
+ ; using vectors for n-dimensional points
; vector-magnitude : (vectorof number) -> number
; computes the magnituded of the vector by using pythegorean theorem
diff --git a/collects/plot/plot.rkt b/collects/plot/plot.rkt
index 49ae2dd88a..87250389bf 100644
--- a/collects/plot/plot.rkt
+++ b/collects/plot/plot.rkt
@@ -36,7 +36,7 @@
;; make-2d-renderer : (2d-view% -> void)
;; provides a user with the ability to create their own renderers
-;; without providing the implimentation
+;; without providing the implementation
(define custom identity)
;;
diff --git a/collects/racket/private/serialize.rkt b/collects/racket/private/serialize.rkt
index b2d90f853e..bd632a18b7 100644
--- a/collects/racket/private/serialize.rkt
+++ b/collects/racket/private/serialize.rkt
@@ -415,7 +415,7 @@
(define (lookup-shared! share n mod-map module-path-index-join)
;; The shared list is not necessarily in order of
- ;; refereds before referees. A `not-ready' object
+ ;; referreds before referees. A `not-ready' object
;; indicates a reference before a value is ready,
;; so we need to recur to make it ready. Cycles
;; have been broken, though, so we don't run into
diff --git a/collects/redex/redex.scrbl b/collects/redex/redex.scrbl
index 27c0792a82..53b6ca4d2b 100644
--- a/collects/redex/redex.scrbl
+++ b/collects/redex/redex.scrbl
@@ -2438,7 +2438,7 @@ The line, line-span, column, and column-span correspond to
the logical spacing for the redex program, not the actual
spacing that will be used when they are rendered. The
logical spacing is only used when determining where to place
-typeset portions of the program. In the absense of any
+typeset portions of the program. In the absence of any
rewriters, these numbers correspond to the line and column
numbers in the original program.
diff --git a/collects/scribblings/framework/canvas.scrbl b/collects/scribblings/framework/canvas.scrbl
index ec1cc5c3a0..af73ef2bfa 100644
--- a/collects/scribblings/framework/canvas.scrbl
+++ b/collects/scribblings/framework/canvas.scrbl
@@ -53,7 +53,7 @@
Any
@scheme[canvas%]
that matches this interface will automatically
- resize selected snips when it's size changes. Use
+ resize selected snips when its size changes. Use
@method[canvas:wide-snip<%> add-tall-snip]
and
@method[canvas:wide-snip<%> add-wide-snip]
diff --git a/collects/scribblings/framework/editor.scrbl b/collects/scribblings/framework/editor.scrbl
index 64a353be79..b683634f0a 100644
--- a/collects/scribblings/framework/editor.scrbl
+++ b/collects/scribblings/framework/editor.scrbl
@@ -346,7 +346,7 @@
the filesystem.
The class that this mixin produces uses the same initialization
- arguments as it's input.
+ arguments as its input.
@defmethod*[#:mode override (((set-filename (name string) (temp? boolean |#f|)) void))]{
Updates the filename on each frame displaying this editor, for each
diff --git a/collects/scribblings/framework/text.scrbl b/collects/scribblings/framework/text.scrbl
index 7aa92bce03..09188b9b3c 100644
--- a/collects/scribblings/framework/text.scrbl
+++ b/collects/scribblings/framework/text.scrbl
@@ -156,7 +156,7 @@
objects in the framework.
The class that this mixin produces uses the same initialization
- arguments as it's input.
+ arguments as its input.
@defmethod*[#:mode override (((on-paint (before? any/c) (dc (is-a?/c dc<%>)) (left real?) (top real?) (right real?) (bottom real?) (dx real?) (dy real?) (draw-caret (one-of/c (quote no-caret) (quote show-inactive-caret) (quote show-caret)))) void))]{
Draws the rectangles installed by
diff --git a/collects/scribblings/guide/simple-syntax.scrbl b/collects/scribblings/guide/simple-syntax.scrbl
index 8f4578b35b..83748241c9 100644
--- a/collects/scribblings/guide/simple-syntax.scrbl
+++ b/collects/scribblings/guide/simple-syntax.scrbl
@@ -379,7 +379,7 @@ clearly written as follows:
The use of square brackets for @racket[cond] clauses is a
convention. In Racket, parentheses and square brackets are actually
-interchangable, as long as @litchar{(} is matched with @litchar{)} and
+interchangeable, as long as @litchar{(} is matched with @litchar{)} and
@litchar{[} is matched with @litchar{]}. Using square brackets in a
few key places makes Racket code even more readable.
diff --git a/collects/scribblings/raco/exe-api.scrbl b/collects/scribblings/raco/exe-api.scrbl
index 6085885dda..25323d77cf 100644
--- a/collects/scribblings/raco/exe-api.scrbl
+++ b/collects/scribblings/raco/exe-api.scrbl
@@ -256,7 +256,7 @@ currently supported keys are as follows:
@racket[#t] means that, to the degree that the generated
executable must refer to another, it can use a relative path
(so the executables can be moved together, but not
- seperately); a @racket[#f] value (the default) means that
+ separately); a @racket[#f] value (the default) means that
absolute paths should be used (so the generated executable can
be moved).}
diff --git a/collects/scribblings/reference/contracts.scrbl b/collects/scribblings/reference/contracts.scrbl
index e906df1dc3..7caa081896 100644
--- a/collects/scribblings/reference/contracts.scrbl
+++ b/collects/scribblings/reference/contracts.scrbl
@@ -1088,8 +1088,8 @@ on integers looks like this:
Although these projections have the right error behavior,
they are not quite ready for use as contracts, because they
-do not accomodate blame, and do not provide good error
-messages. In order to accomodate these, contracts do not
+do not accommodate blame, and do not provide good error
+messages. In order to accommodate these, contracts do not
just use simple projections, but use functions that accept a
@deftech{blame object} encapsulating
the names of two parties that are the candidates for blame,
diff --git a/collects/scribblings/reference/control-lib.scrbl b/collects/scribblings/reference/control-lib.scrbl
index ed46da84cc..c748d289c4 100644
--- a/collects/scribblings/reference/control-lib.scrbl
+++ b/collects/scribblings/reference/control-lib.scrbl
@@ -173,7 +173,7 @@ The essential reduction rules are:
(lambda (_v) (reset0 _E[_v])))
]
-The @scheme[reset0] and @scheme[prompt0] forms are interchangable.
+The @scheme[reset0] and @scheme[prompt0] forms are interchangeable.
Furthermore, the following reductions apply:
@schemeblock[
diff --git a/collects/scribblings/reference/networking.scrbl b/collects/scribblings/reference/networking.scrbl
index a0285c74fe..ffae05cbde 100644
--- a/collects/scribblings/reference/networking.scrbl
+++ b/collects/scribblings/reference/networking.scrbl
@@ -45,7 +45,7 @@ accepts only connections to @racket["127.0.0.1"] (the loopback
interface) from the local machine.
(Racket implements a listener with multiple sockets, if necessary, to
-accomodate multiple addresses with different protocol families. Under
+accommodate multiple addresses with different protocol families. Under
Linux, if @racket[hostname] maps to both IPv4 and IPv6 addresses, then
the behavior depends on whether IPv6 is supported and IPv6 sockets can
be configured to listen to only IPv6 connections: if IPv6 is not
diff --git a/collects/scribblings/reference/reader.scrbl b/collects/scribblings/reference/reader.scrbl
index dbdf6a4d37..87a132fba0 100644
--- a/collects/scribblings/reference/reader.scrbl
+++ b/collects/scribblings/reference/reader.scrbl
@@ -322,7 +322,7 @@ the recursive reads.
If the reader finds two data between the matching parentheses
that are separated by a delimited @litchar{.}, then it creates a
pair. More generally, if it finds two or more data where the
-last is preceeded by a delimited @litchar{.}, then it constructs
+last is preceded by a delimited @litchar{.}, then it constructs
nested pairs: the next-to-last element is paired with the last, then
the third-to-last is paired with that pair, and so on.
diff --git a/collects/scribblings/tools/rep.scrbl b/collects/scribblings/tools/rep.scrbl
index 86f8dcaae9..bc07584f18 100644
--- a/collects/scribblings/tools/rep.scrbl
+++ b/collects/scribblings/tools/rep.scrbl
@@ -60,9 +60,9 @@ submitted at the prompt.
@methimpl{
The function @scheme[run-loop] is called. It is expected to loop, calling
-it's argument with a thunk that corresponds to the user's
-evaluation. It should call it's argument once for each expression the
-user is evaluating. It should pass a thunk to it's argument that
+its argument with a thunk that corresponds to the user's
+evaluation. It should call its argument once for each expression the
+user is evaluating. It should pass a thunk to its argument that
actually does the users's evaluation.
@@ -297,7 +297,7 @@ This method resets the highlighting being displayed for this repl. See also:
void?]{
@methspec{
-This function runs it's arguments in the user evaluation thread. This
+This function runs its arguments in the user evaluation thread. This
thread is the same as the user's eventspace main thread.
See also
@@ -369,7 +369,7 @@ interactions windows.}
@definterface[drracket:rep:context<%> ()]{
Objects that match this interface provide all of the services that the
-@scheme[drracket:rep:text%] class needs to connect with it's context.
+@scheme[drracket:rep:text%] class needs to connect with its context.
diff --git a/collects/scribblings/tools/tools.scrbl b/collects/scribblings/tools/tools.scrbl
index c3bb91b7d3..79a91424aa 100644
--- a/collects/scribblings/tools/tools.scrbl
+++ b/collects/scribblings/tools/tools.scrbl
@@ -472,7 +472,7 @@ is bound to an extender function. In order to change the
behavior of DrRacket, you can derive new classes from the
standard classes for the frame, texts, canvases. Each
extender accepts a function as input. The function it
-accepts must take a class as it's argument and return a
+accepts must take a class as its argument and return a
classes derived from that class as its result. For example:
@racketblock[
diff --git a/collects/sirmail/readr.rkt b/collects/sirmail/readr.rkt
index 93919ecd52..81872e23f6 100644
--- a/collects/sirmail/readr.rkt
+++ b/collects/sirmail/readr.rkt
@@ -2010,7 +2010,7 @@
(sleep 10)
(loop)))))))
- ;; copied from framerok/private/frame.sss -- be sure to propogate fixes....
+ ;; copied from framerok/private/frame.sss -- be sure to propagate fixes....
;; or establish single point of control.
(define (format-number n)
(if n
diff --git a/collects/srfi/26/cut.rkt b/collects/srfi/26/cut.rkt
index 762f367d06..16f344d16f 100644
--- a/collects/srfi/26/cut.rkt
+++ b/collects/srfi/26/cut.rkt
@@ -16,7 +16,7 @@
; Given the arguments for the macro call to cut (or cute) as a syntax-list,
; call build with four lists:
; 1) a list of names given to each <>-slot
-; 2) [cut] a list of the macro arguments, except that all occurences
+; 2) [cut] a list of the macro arguments, except that all occurrences
; of a <>-slots have been substituted with the chosen name.
; 3) [cute] a list the names given to the exprs and the <>-slots
; 4) [cute] a list of lists of name-expression pairs, i.e. the bindings
diff --git a/collects/srfi/optional.rkt b/collects/srfi/optional.rkt
index 44e9078d7b..16af7a4ede 100644
--- a/collects/srfi/optional.rkt
+++ b/collects/srfi/optional.rkt
@@ -1,6 +1,6 @@
;;;
;;; ---- Let-optionals macros
-;;; Time-stamp: <02/07/15 09:25:27 solsona>
+;;; Time-stamp: <2011-02-02 11:44:21 dvanhorn>
;;;
;;; Usually, I would add a copyright notice, and the announce that
;;; this code is under the LGPL licence. This code is been copied
@@ -39,7 +39,7 @@
;;
;; Commentary:
;;
-;; this is a port of commonly refered (in SRFI mostly) macros, and
+;; this is a port of commonly referred (in SRFI mostly) macros, and
;; utilities, to the PLT Scheme system. I'm not sure if I should use
;; the word "port", because I hardly touched Olin Shivers' superiour
;; macros. :-)
diff --git a/collects/srpersist/doc.txt b/collects/srpersist/doc.txt
index 2262db0df4..d703360da5 100644
--- a/collects/srpersist/doc.txt
+++ b/collects/srpersist/doc.txt
@@ -1561,7 +1561,7 @@
'sql-param-success-with-info
'sql-param-error
'sql-param-unused
- 'sql-param-diag-unavilable
+ 'sql-param-diag-unavailable
> (get-stmt-option hstmt option)
diff --git a/collects/stepper/private/lifting.rkt b/collects/stepper/private/lifting.rkt
index 2094fdf565..4e01615766 100644
--- a/collects/stepper/private/lifting.rkt
+++ b/collects/stepper/private/lifting.rkt
@@ -262,7 +262,7 @@
(loop (cdr ctx-list) next-defs next-body))))))
; lift-helper takes a syntax object and a split path and a list of syntax objects and breaks it up
- ; iff its a let/rec, wrapping those before the split and those after the split around the list of syntax
+ ; iff it's a let/rec, wrapping those before the split and those after the split around the list of syntax
; objects
; (->* (syntax? (union false? (listof number?)) (listof syntax?)) ((listof syntax?) syntax?))
(define (lift-helper stx path so-far-defs)
diff --git a/collects/syntax-color/paren-tree.rkt b/collects/syntax-color/paren-tree.rkt
index 73280ecb76..b856dad3f2 100644
--- a/collects/syntax-color/paren-tree.rkt
+++ b/collects/syntax-color/paren-tree.rkt
@@ -38,7 +38,7 @@
;; records whose type field is a symbol that indicates which type of
;; (opening or closing) parenthesis begins the range being mapped.
;; The length field indicates how many characters the actual parenthesis
- ;; is. In the special case that there is a region that is not preceeded
+ ;; is. In the special case that there is a region that is not preceded
;; with a parenthesis (that is, the region before the first parenthesis in
;; a buffer), the type will be #f, and the length will be 0.
@@ -122,7 +122,7 @@
;; If it indicates an error, the first two results give the
;; starting and stoping positions for error highlighting.
;; If all three return #f, then there was no tree to search, or
- ;; the position did not immediately preceed an open.
+ ;; the position did not immediately precede an open.
(define/public (match-forward pos)
(send tree search! pos)
(cond
diff --git a/collects/syntax/doc.txt b/collects/syntax/doc.txt
index b770b258ed..db2405d6c2 100644
--- a/collects/syntax/doc.txt
+++ b/collects/syntax/doc.txt
@@ -362,7 +362,7 @@ _modcode.ss_: getting module compiled code
only a native-code non_loader version exists (i.e., `path' itself
does not exist). A _loader extension is selected a last resort.
- If an extension is prefered or is the only file that exists, it is
+ If an extension is preferred or is the only file that exists, it is
supplied to `ext-proc' when `ext-proc' is #f, or an exception is
raised (to report that an extension file cannot be used) when
`ext-proc' is #f.
diff --git a/collects/syntax/scribblings/modcode.scrbl b/collects/syntax/scribblings/modcode.scrbl
index 9b21efa167..f9d8d69e89 100644
--- a/collects/syntax/scribblings/modcode.scrbl
+++ b/collects/syntax/scribblings/modcode.scrbl
@@ -58,7 +58,7 @@ are ignored, unless only a native-code non-@tt{_loader} version exists
(i.e., @scheme[path] itself does not exist). A @tt{_loader} extension
is selected a last resort.
-If an extension is prefered or is the only file that exists, it is
+If an extension is preferred or is the only file that exists, it is
supplied to @scheme[ext-proc] when @scheme[ext-proc] is @scheme[#f],
or an exception is raised (to report that an extension file cannot be
used) when @scheme[ext-proc] is @scheme[#f].
diff --git a/collects/syntax/scribblings/parse/intro.scrbl b/collects/syntax/scribblings/parse/intro.scrbl
index 033275df4c..d57811b32d 100644
--- a/collects/syntax/scribblings/parse/intro.scrbl
+++ b/collects/syntax/scribblings/parse/intro.scrbl
@@ -52,7 +52,7 @@ to what one would write using @scheme[syntax-rules] or perhaps
]
Note the use of @scheme[...] and @scheme[...+] in the pattern;
-@scheme[...] means match zero or more repetitions of the preceeding
+@scheme[...] means match zero or more repetitions of the preceding
pattern; @scheme[...+] means match one or more. Only @scheme[...] may
be used in the template, however.
diff --git a/collects/teachpack/2htdp/scribblings/image.scrbl b/collects/teachpack/2htdp/scribblings/image.scrbl
index cb54ea8d11..6d5682a70a 100644
--- a/collects/teachpack/2htdp/scribblings/image.scrbl
+++ b/collects/teachpack/2htdp/scribblings/image.scrbl
@@ -95,7 +95,7 @@ Existing images can be rotated, scaled, flipped, and overlaid on top of each oth
Adds a line to the image @racket[image], starting from the point (@racket[x1],@racket[y1])
and going to the point (@racket[x2],@racket[y2]).
Unlike @racket[scene+line], if the line passes outside of @racket[image], the image
- gets larger to accomodate the line.
+ gets larger to accommodate the line.
@image-examples[(add-line (ellipse 40 40 "outline" "maroon")
0 40 40 0 "maroon")
@@ -126,7 +126,7 @@ long the curve tries to stay with that angle. Larger numbers
mean that the curve stays with the angle longer.
Unlike @racket[scene+curve], if the line passes outside of @racket[image], the image
- gets larger to accomodate the curve.
+ gets larger to accommodate the curve.
@image-examples[(add-curve (rectangle 100 100 "solid" "black")
diff --git a/collects/tests/drracket/drracket-test-util.rkt b/collects/tests/drracket/drracket-test-util.rkt
index 7c343930c0..17b25c7fea 100644
--- a/collects/tests/drracket/drracket-test-util.rkt
+++ b/collects/tests/drracket/drracket-test-util.rkt
@@ -570,7 +570,7 @@
;; run-one/sync : (-> A) -> A
;; runs the thunk `f' as a test action, and
- ;; waits for it to complete. Also propogates
+ ;; waits for it to complete. Also propagates
;; exceptions.
(define (run-one/sync f)
(not-on-eventspace-handler-thread 'repl-in-edit-sequence?)
diff --git a/collects/typed-scheme/scribblings/ts-reference.scrbl b/collects/typed-scheme/scribblings/ts-reference.scrbl
index 48bcd6dc7b..d70af32bdf 100644
--- a/collects/typed-scheme/scribblings/ts-reference.scrbl
+++ b/collects/typed-scheme/scribblings/ts-reference.scrbl
@@ -442,7 +442,7 @@ can be used anywhere a definition form may be used.}
the types @racket[t], and also provides all of the @racket[v]s.}
@litchar{#{v : t}} This declares that the variable @racket[v] has type
-@racket[t]. This is legal only for binding occurences of @racket[_v].
+@racket[t]. This is legal only for binding occurrences of @racket[_v].
@defform[(ann e t)]{Ensure that @racket[e] has type @racket[t], or
some subtype. The entire expression has type @racket[t].
diff --git a/collects/typed-scheme/typecheck/tc-app.rkt b/collects/typed-scheme/typecheck/tc-app.rkt
index a21d9ecf1d..15df18a18e 100644
--- a/collects/typed-scheme/typecheck/tc-app.rkt
+++ b/collects/typed-scheme/typecheck/tc-app.rkt
@@ -657,7 +657,7 @@
(match-let* ([(list last tys-r ...) (reverse (map tc-expr/t (syntax->list #'args)))]
[tys (reverse tys-r)])
(ret (foldr make-Pair last tys)))]
- ;; special case for `reverse' to propogate expected type info
+ ;; special case for `reverse' to propagate expected type info
[(#%plain-app reverse arg)
(match expected
[(tc-result1: (Listof: _))
diff --git a/collects/unstable/scribblings/gui/slideshow.scrbl b/collects/unstable/scribblings/gui/slideshow.scrbl
index 3c3ddad1b5..9047d293d3 100644
--- a/collects/unstable/scribblings/gui/slideshow.scrbl
+++ b/collects/unstable/scribblings/gui/slideshow.scrbl
@@ -159,7 +159,7 @@ Shades @scheme[pict] to show with @scheme[ratio] of its normal opacity; if
These pict control flow operators decide which pict of several to use. All
branches are evaluated; the resulting pict is a combination of the pict chosen
by normal conditional flow with @scheme[ghost] applied to all the other picts.
-The result is a picture large enough to accomodate each alternative, but showing
+The result is a picture large enough to accommodate each alternative, but showing
only the chosen one. This is useful for staged slides, as the pict chosen may
change with each slide but its size and position will not.
diff --git a/collects/web-server/private/configure.rkt b/collects/web-server/private/configure.rkt
index 96b13bab55..a097b56a69 100644
--- a/collects/web-server/private/configure.rkt
+++ b/collects/web-server/private/configure.rkt
@@ -740,7 +740,7 @@
[copy-conf
(lambda (from to)
(let ([to-path (build-path-unless-absolute conf to)])
- ; more here - check existance of from path
+ ; more here - check existence of from path
(copy-file* (build-path from-conf from) to-path)))])
(copy-conf "passwords-refresh.html" (messages-passwords-refreshed messages))
(copy-conf "servlet-refresh.html" (messages-servlets-refreshed messages))
diff --git a/collects/web-server/scribblings/contracts.scrbl b/collects/web-server/scribblings/contracts.scrbl
index 4e01b86ecd..b83bdef33f 100644
--- a/collects/web-server/scribblings/contracts.scrbl
+++ b/collects/web-server/scribblings/contracts.scrbl
@@ -9,7 +9,7 @@
@defmodule[web-server/servlet/servlet-structs]{
Servlets communicate to the Web Server by returning HTTP responses. In order to
-accomodate lightweight programs (and backwards compatibility), the Web Server
+accommodate lightweight programs (and backwards compatibility), the Web Server
provides an indirection from application-specific response formats and the internal
HTTP response format, @racket[response].
diff --git a/collects/web-server/scribblings/web.scrbl b/collects/web-server/scribblings/web.scrbl
index 9968ea3a02..d94f166d7e 100644
--- a/collects/web-server/scribblings/web.scrbl
+++ b/collects/web-server/scribblings/web.scrbl
@@ -97,7 +97,7 @@ functions of interest for the servlet developer.
"+")))))))))
]
Notice that in this example the result of the handlers are returned to the continuation of @racket[send/suspend/dispatch].
- However, it is very common that the return value of @racket[send/suspend/dispatch] is irrevelant in
+ However, it is very common that the return value of @racket[send/suspend/dispatch] is irrelevant in
your application and you may think of it as ``embedding'' value-less callbacks. Here is the same example in this style:
@racketblock[
(define (count-dot-com i)
diff --git a/doc/release-notes/drracket/HISTORY.txt b/doc/release-notes/drracket/HISTORY.txt
index 338420147f..701c34ce1a 100644
--- a/doc/release-notes/drracket/HISTORY.txt
+++ b/doc/release-notes/drracket/HISTORY.txt
@@ -873,7 +873,7 @@ GENERAL
now it shows `('a 'a).
- The portion of space between the definitions and
- interactions window is now interactively changable.
+ interactions window is now interactively changeable.
- the bug report form now connects to bugs.drscheme.org
instead of cs.rice.edu directly, so earthlink users
@@ -962,7 +962,7 @@ General
- files added to projects are now stored as relative files,
by default. (use project menu to change the default)
- - project files are saved using a platform-independant syntax for
+ - project files are saved using a platform-independent syntax for
paths now.
- Using file|open and choosing a project file (based on contents) will open
diff --git a/doc/release-notes/gracket/HISTORY.txt b/doc/release-notes/gracket/HISTORY.txt
index 75948fb329..8085ccf1fe 100644
--- a/doc/release-notes/gracket/HISTORY.txt
+++ b/doc/release-notes/gracket/HISTORY.txt
@@ -1285,7 +1285,7 @@ System:
Changed force-redraw to ignore refresh requests when the
redraw-requesting window is not shown. Redraw requests are now
- propogated to the top-level frame or dialog via child-redraw-request.
+ propagated to the top-level frame or dialog via child-redraw-request.
- if your application is unititized, then you need to change the
startup procedure. See the application startup section in the
toolbox manual.
@@ -1655,7 +1655,7 @@ Bug fixes, especially Motif and memory bugs
Rewrote editor line-maintenance
Faster caret updating
Upgraded garbage collector
-File format changed to accomodate nested buffers with
+File format changed to accommodate nested buffers with
separate style lists
Standard system standardized
Code changes for compiling on MSWindows (almost works...)
diff --git a/doc/release-notes/racket/HISTORY.txt b/doc/release-notes/racket/HISTORY.txt
index 21d404529f..05ecb5f2e2 100644
--- a/doc/release-notes/racket/HISTORY.txt
+++ b/doc/release-notes/racket/HISTORY.txt
@@ -1314,7 +1314,7 @@ Refined error messages
Version 49, May 31, 1997
Multiple superclass inheritance is no longer supported
Added (Java-ish) interfaces to object system
-class* syntax changed to accomodate interfaces and removed
+class* syntax changed to accommodate interfaces and removed
multiple superclasses
uq-ivar always takes two arguments; class is not a legal argument
uq-make-generic accepts a class or an interface
diff --git a/doc/srfi-std/srfi-4.html b/doc/srfi-std/srfi-4.html
index 00f474d9dc..5dab25b2ff 100644
--- a/doc/srfi-std/srfi-4.html
+++ b/doc/srfi-std/srfi-4.html
@@ -187,7 +187,7 @@ must be quoted just like heterogeneous vectors must be. Homogeneous
vectors can appear in quasiquotations but must not contain
unquote
or unquote-splicing
forms
(i.e. `(,x #u8(1 2))
is legal but `#u8(1 ,x
-2)
is not). This restriction is to accomodate the many Scheme
+2) is not). This restriction is to accommodate the many Scheme
systems that use the read
procedure to parse programs.
diff --git a/doc/srfi-std/srfi-40.html b/doc/srfi-std/srfi-40.html
index 902fba7e8a..734078142c 100644
--- a/doc/srfi-std/srfi-40.html
+++ b/doc/srfi-std/srfi-40.html
@@ -259,7 +259,7 @@ and even streams. We expect the two constructors nil
and
nil
and cons
return a strict list, but the
even nil
and cons
return promises.
Nil?
, car
and cdr
change to
-accomodate the underlying representation differences.
+accommodate the underlying representation differences.
Cutoff
is identical in the two versions, because it
doesn't return a stream.
diff --git a/doc/srfi-std/srfi-67/srfi-67.html b/doc/srfi-std/srfi-67/srfi-67.html
index 26dd01f9b5..f8fd0cb482 100644
--- a/doc/srfi-std/srfi-67/srfi-67.html
+++ b/doc/srfi-std/srfi-67/srfi-67.html
@@ -377,7 +377,7 @@ procedures, as explained in Section 5.
Also note the implicit use of refine-compare in
the bowl?-case.
-The preceeding example illustrates the main functionality of this SRFI.
+The preceding example illustrates the main functionality of this SRFI.
For other examples, refer to Section 4.4,
and to the file examples.scm included in the reference
implementation.
diff --git a/doc/srfi-std/srfi-98.html b/doc/srfi-std/srfi-98.html
index d8fe1be7be..8ff8dfbb8f 100644
--- a/doc/srfi-std/srfi-98.html
+++ b/doc/srfi-std/srfi-98.html
@@ -51,7 +51,7 @@ environment variables.
Most operating systems provide a mechanism for passing auxiliary
parameters implicitly to child processes. Usually, this mechanism is
called "the environment", and is conceptually a map from string names
-to string values. The string names are called enviornment
+to string values. The string names are called environment
variables.
Some applications rely on environment variables to modify their
diff --git a/src/foreign/libffi/src/dlmalloc.c b/src/foreign/libffi/src/dlmalloc.c
index 0fa235af22..615dc4f35d 100644
--- a/src/foreign/libffi/src/dlmalloc.c
+++ b/src/foreign/libffi/src/dlmalloc.c
@@ -5088,7 +5088,7 @@ History:
Wolfram Gloger (Gloger@lrz.uni-muenchen.de).
* Use last_remainder in more cases.
* Pack bins using idea from colin@nyx10.cs.du.edu
- * Use ordered bins instead of best-fit threshhold
+ * Use ordered bins instead of best-fit threshold
* Eliminate block-local decls to simplify tracing and debugging.
* Support another case of realloc via move into top
* Fix error occuring when initial sbrk_base not word-aligned.
diff --git a/src/foreign/libffi/src/x86/ffi64.c b/src/foreign/libffi/src/x86/ffi64.c
index 07a2627b1f..05ebf17568 100644
--- a/src/foreign/libffi/src/x86/ffi64.c
+++ b/src/foreign/libffi/src/x86/ffi64.c
@@ -366,7 +366,7 @@ ffi_prep_cif_machdep (ffi_cif *cif)
/* Go over all arguments and determine the way they should be passed.
If it's in a register and there is space for it, let that be so. If
- not, add it's size to the stack byte count. */
+ not, add its size to the stack byte count. */
for (bytes = 0, i = 0, avn = cif->nargs; i < avn; i++)
{
if (examine_argument (cif->arg_types[i], classes, 0, &ngpr, &nsse) == 0
diff --git a/src/foreign/libffi/texinfo.tex b/src/foreign/libffi/texinfo.tex
index ff2c40654b..24ecf36d0e 100644
--- a/src/foreign/libffi/texinfo.tex
+++ b/src/foreign/libffi/texinfo.tex
@@ -3,7 +3,7 @@
% Load plain if necessary, i.e., if running under initex.
\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
%
-\def\texinfoversion{2005-07-05.19}
+\def\texinfoversion{2011-02-02.11}
%
% Copyright (C) 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software
@@ -415,7 +415,7 @@
\def\argremovecomment#1\comment#2\ArgTerm{\argremovec #1\c\ArgTerm}
\def\argremovec#1\c#2\ArgTerm{\argcheckspaces#1\^^M\ArgTerm}
-% Each occurence of `\^^M' or `\^^M' is replaced by a single space.
+% Each occurrence of `\^^M' or `\^^M' is replaced by a single space.
%
% \argremovec might leave us with trailing space, e.g.,
% @end itemize @c foo
@@ -498,7 +498,7 @@
% used to check whether the current environment is the one expected.
%
% Non-false conditionals (@iftex, @ifset) don't fit into this, so they
-% are not treated as enviroments; they don't open a group. (The
+% are not treated as environments; they don't open a group. (The
% implementation of @end takes care not to call \endgroup in this
% special case.)
diff --git a/src/plot/plplot/plmap.c b/src/plot/plplot/plmap.c
index 52cc62982a..399795a049 100644
--- a/src/plot/plplot/plmap.c
+++ b/src/plot/plplot/plmap.c
@@ -47,7 +47,7 @@
*
* plot continental outline in world coordinates
*
- * v1.4: machine independant version
+ * v1.4: machine independent version
* v1.3: replaced plcontinent by plmap, added plmeridians
* v1.2: 2 arguments: mapform, type of plot
*
diff --git a/src/plot/plplot/plplot.h b/src/plot/plplot/plplot.h
index acd3e7bf10..7a09f5362c 100644
--- a/src/plot/plplot/plplot.h
+++ b/src/plot/plplot/plplot.h
@@ -387,7 +387,7 @@ typedef struct {
* change the object names, but then everybody who wants to use the
* package must throw these same switches, leading to no end of trouble.
*
- * Note that this definition should not cause any noticable effects except
+ * Note that this definition should not cause any noticeable effects except
* when debugging PLplot calls, in which case you will need to remember
* the real function names (same as before but with a 'c_' prepended).
*
diff --git a/src/plot/plplot/plplotP.h b/src/plot/plplot/plplotP.h
index 71b5c636aa..d963d1e83b 100644
--- a/src/plot/plplot/plplotP.h
+++ b/src/plot/plplot/plplotP.h
@@ -627,12 +627,12 @@ plP_gprec(PLINT *p_setp, PLINT *p_prec);
PLFLT
plstrl(const char *string);
-/* Similar to strpos, but searches for occurence of string str2. */
+/* Similar to strpos, but searches for occurrence of string str2. */
PLINT
plP_stindex(const char *str1, const char *str2);
-/* Searches string str for first occurence of character chr. */
+/* Searches string str for first occurrence of character chr. */
PLINT
plP_strpos(char *str, int chr);
diff --git a/src/plot/plplot/plshade.c b/src/plot/plplot/plshade.c
index b2cb7843b0..6ce1b4e77c 100644
--- a/src/plot/plplot/plshade.c
+++ b/src/plot/plplot/plshade.c
@@ -347,8 +347,8 @@ plfshade(PLFLT (*f2eval) (PLINT, PLINT, PLPointer),
* parameters:
*
* f2eval, f2eval_data: data to plot
- * c2eval, c2eval_data: defined mask (not implimented)
- * defined: defined mask (old API - implimented)
+ * c2eval, c2eval_data: defined mask (not implemented)
+ * defined: defined mask (old API - implemented)
* missing_min, missing_max: yet another way to set data to undefined
* nx, ny: array dimensions
* xmin, xmax, ymin, ymax: grid coordinates
diff --git a/src/plot/plplot/plsym.c b/src/plot/plplot/plsym.c
index 2d0dba4bb0..e708f940c1 100644
--- a/src/plot/plplot/plsym.c
+++ b/src/plot/plplot/plsym.c
@@ -917,7 +917,7 @@ pldeco(short int **symbol, PLINT *length, const char *text)
/*--------------------------------------------------------------------------*\
* PLINT plP_strpos()
*
- * Searches string str for first occurence of character chr. If found
+ * Searches string str for first occurrence of character chr. If found
* the position of the character in the string is returned (the first
* character has position 0). If the character is not found a -1 is
* returned.
@@ -937,7 +937,7 @@ plP_strpos(char *str, int chr)
/*--------------------------------------------------------------------------*\
* PLINT plP_stindex()
*
- * Similar to strpos, but searches for occurence of string str2.
+ * Similar to strpos, but searches for occurrence of string str2.
\*--------------------------------------------------------------------------*/
PLINT
diff --git a/src/racket/gc/Makefile.dj b/src/racket/gc/Makefile.dj
index c56ea7b03f..4b0c7b48d7 100644
--- a/src/racket/gc/Makefile.dj
+++ b/src/racket/gc/Makefile.dj
@@ -84,7 +84,7 @@ CFLAGS= -gstabs+ -O2 -I$(srcdir)/include -DATOMIC_UNCOLLECTABLE -DALL_INTERIOR_P
# -DJAVA_FINALIZATION makes it somewhat safer to finalize objects out of
# order by specifying a nonstandard finalization mark procedure (see
# finalize.c). Objects reachable from finalizable objects will be marked
-# in a sepearte postpass, and hence their memory won't be reclaimed.
+# in a separate postpass, and hence their memory won't be reclaimed.
# Not recommended unless you are implementing a language that specifies
# these semantics. Since 5.0, determines only only the initial value
# of GC_java_finalization variable.
diff --git a/src/racket/gc/doc/README.changes b/src/racket/gc/doc/README.changes
index 27bf33eaaa..34c494eb2e 100644
--- a/src/racket/gc/doc/README.changes
+++ b/src/racket/gc/doc/README.changes
@@ -1554,7 +1554,7 @@ Since 6.1alpha3:
- Force 64 bit alignment with GCJ support. (Reflects Bryce McKinley's
patch to the gcc tree.)
- Refined the choice of sa_handler vs. sa_sigaction in GC_dirty_init
- to accomodate some glibc5 systems. (Thanks to Dan Fandrich for the
+ to accommodate some glibc5 systems. (Thanks to Dan Fandrich for the
patch.)
- Compensated for the fact that current versions of glibc set
__libc_stack_end incorrectly on Linux/IA64 while initialization code
diff --git a/src/racket/gc/dyn_load.c b/src/racket/gc/dyn_load.c
index 57ddce8955..ef4db4219d 100644
--- a/src/racket/gc/dyn_load.c
+++ b/src/racket/gc/dyn_load.c
@@ -1194,7 +1194,7 @@ void GC_register_dynamic_libraries()
PCR_IL_LoadedFile * p = PCR_IL_GetLastLoadedFile();
PCR_IL_LoadedSegment * q;
- /* Skip uncommited files */
+ /* Skip uncommitted files */
while (p != NIL && !(p -> lf_commitPoint)) {
/* The loading of this file has not yet been committed */
/* Hence its description could be inconsistent. */
diff --git a/src/racket/gc/win32_threads.c b/src/racket/gc/win32_threads.c
index 272af63a43..fed8ec6e57 100644
--- a/src/racket/gc/win32_threads.c
+++ b/src/racket/gc/win32_threads.c
@@ -1249,7 +1249,7 @@ int GC_pthread_join(pthread_t pthread_id, void **retval) {
}
/* Cygwin-pthreads calls CreateThread internally, but it's not
- * easily interceptible by us..
+ * easily interceptable by us..
* so intercept pthread_create instead
*/
int
diff --git a/src/racket/include/scheme.h b/src/racket/include/scheme.h
index 58e50d815d..a5ce5aad71 100644
--- a/src/racket/include/scheme.h
+++ b/src/racket/include/scheme.h
@@ -389,7 +389,7 @@ typedef intptr_t (*Scheme_Secondary_Hash_Proc)(Scheme_Object *obj, void *cycle_d
#define SCHEME_PATHP(obj) SAME_TYPE(SCHEME_TYPE(obj), SCHEME_PLATFORM_PATH_KIND)
#define SCHEME_GENERAL_PATHP(obj) ((SCHEME_TYPE(obj) >= scheme_unix_path_type) && (SCHEME_TYPE(obj) <= scheme_windows_path_type))
- /* A path is guranteed to have the same shape as a byte string */
+ /* A path is guaranteed to have the same shape as a byte string */
#define SCHEME_PATH_STRINGP(x) (SCHEME_CHAR_STRINGP(x) || SCHEME_PATHP(x))
#define SCHEME_PATH_STRING_STR "path or string"
diff --git a/src/racket/sgc/sgc.c b/src/racket/sgc/sgc.c
index 43fea9f8e6..5545169f52 100644
--- a/src/racket/sgc/sgc.c
+++ b/src/racket/sgc/sgc.c
@@ -315,7 +315,7 @@
malloc() to avoid waste when obtaining the proper alignment. */
#define SECTOR_SEGMENT_GROUP_SIZE 32
-/* Number of bits used in 32-bit level table for checking existance of
+/* Number of bits used in 32-bit level table for checking existence of
a sector. Creates a table of (1 << SECTOR_LOOKUP_SHIFT) pointers
to individual page tables of size SECTOR_LOOKUP_PAGESIZE. */
#define SECTOR_LOOKUP_PAGESETBITS 12
diff --git a/src/racket/src/dlcompat.inc b/src/racket/src/dlcompat.inc
index 5736b41ecb..a11e5caff3 100644
--- a/src/racket/src/dlcompat.inc
+++ b/src/racket/src/dlcompat.inc
@@ -153,7 +153,7 @@ static const char * safegetenv(const char * s)
* trying to locate a module. We first look at the values of LD_LIBRARY_PATH
* and DYLD_LIBRARY_PATH, and then finally fall back to looking into
* /usr/lib and /lib. Since both of the environments variables can contain a
- * list of colon seperated paths, we simply concat them and the two other paths
+ * list of colon separated paths, we simply concat them and the two other paths
* into one big string, which we then can easily parse.
* Splitting this string into the actual path list is done by getSearchPath()
*/
diff --git a/src/racket/src/jit.c b/src/racket/src/jit.c
index 7a9249c8eb..ee5591338c 100644
--- a/src/racket/src/jit.c
+++ b/src/racket/src/jit.c
@@ -920,7 +920,7 @@ static void *top4;
that multiple adjustments to the register can be collapsed; this
mostly improves code size, rather than speed. Functions that cause
the register to be de-sync'd are marked as such. Functions that can
- accomodate a de-sync'd register on entry are marked as such. All
+ accommodate a de-sync'd register on entry are marked as such. All
other fuctions can assume a sync'd regsiter and ensure a sync'd
register. Note that branches and calls normally require a sync'd
register. */
@@ -5289,7 +5289,7 @@ static int generate_arith(mz_jit_state *jitter, Scheme_Object *rator, Scheme_Obj
If rand is NULL, then we're generating part of the fast path for an
nary arithmatic over a binary operator; the first argument is
already in R0 (fixnum or min/max) or a floating-point register
- (flonum) and the second arguement is in R1 (fixnum or min/max) or a
+ (flonum) and the second argument is in R1 (fixnum or min/max) or a
floating-point register (flonum).
For unsafe_fx or unsafe_fl, -1 means safe but specific to the type.
*/
diff --git a/src/racket/src/portfun.c b/src/racket/src/portfun.c
index 36ea75dbbb..44f5557813 100644
--- a/src/racket/src/portfun.c
+++ b/src/racket/src/portfun.c
@@ -1829,7 +1829,7 @@ static intptr_t pipe_write_bytes(Scheme_Output_Port *p,
avail = pipe->bufstart - pipe->bufend - 1;
}
if (pipe->bufmax) {
- /* Again, it's possible that the port grew to accomodate
+ /* Again, it's possible that the port grew to accommodate
past peeks... */
intptr_t extra;
extra = pipe->buflen - (pipe->bufmax + pipe->bufmaxextra);
diff --git a/src/racket/src/regexp.c b/src/racket/src/regexp.c
index 17de31368f..a37f9e5ece 100644
--- a/src/racket/src/regexp.c
+++ b/src/racket/src/regexp.c
@@ -2075,7 +2075,7 @@ regunicode(int negate)
regparse += len + 1;
ret = regnode(UNIPROP);
- /* This encoding accomodates up to 63 categories: */
+ /* This encoding accommodates up to 63 categories: */
regarg((negate << 13) | (bottom << 6) | top);
return ret;
diff --git a/src/racket/src/thread.c b/src/racket/src/thread.c
index 32af2b0364..ecee0b1441 100644
--- a/src/racket/src/thread.c
+++ b/src/racket/src/thread.c
@@ -22,7 +22,7 @@
/* This file implements Racket threads.
Usually, Racket threads are implemented by copying the stack.
- The scheme_thread_block() function is called occassionally by the
+ The scheme_thread_block() function is called occasionally by the
evaluator so that the current thread can be swapped out.
do_swap_thread() performs the actual swap. Threads can also be
implemented by the OS; the bottom part of this file contains
From c119cef915e7e739540eb07bb31693713f2aea0c Mon Sep 17 00:00:00 2001
From: Robby Findler
Date: Thu, 3 Feb 2011 17:59:43 -0600
Subject: [PATCH 20/68] don't show themodule langauge opt-in buttons when we're
not in the module language anymore (this extra check is necessary because
we might have moved languages between the time the timer is started and
when it fires)
closes PR 11705
Please merge to the release 5.1 branch
---
collects/drracket/private/module-language-tools.rkt | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/collects/drracket/private/module-language-tools.rkt b/collects/drracket/private/module-language-tools.rkt
index e4360fb184..a230666c34 100644
--- a/collects/drracket/private/module-language-tools.rkt
+++ b/collects/drracket/private/module-language-tools.rkt
@@ -100,7 +100,9 @@
(unless timer
(set! timer (new timer%
[notify-callback
- (λ () (move-to-new-language))]
+ (λ ()
+ (when in-module-language?
+ (move-to-new-language)))]
[just-once? #t])))
(send timer stop)
(send timer start 200 #t)))))
From 4ef3dfe6a8770e385fd9dd70d68d599df43b9cd1 Mon Sep 17 00:00:00 2001
From: Ryan Culpepper
Date: Thu, 3 Feb 2011 14:22:12 -0700
Subject: [PATCH 21/68] fixed doc typo Fixes PR 11703 Merge to release
branch
---
collects/syntax/scribblings/parse/patterns.scrbl | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/collects/syntax/scribblings/parse/patterns.scrbl b/collects/syntax/scribblings/parse/patterns.scrbl
index 610f094579..9c15c86423 100644
--- a/collects/syntax/scribblings/parse/patterns.scrbl
+++ b/collects/syntax/scribblings/parse/patterns.scrbl
@@ -147,7 +147,7 @@ One of @ref[~commit s] or @ref[~commit h]:
@defidform[~delimit-cut]{
-One of @ref[~delimit-cut s] or @ref[~describe h]:
+One of @ref[~delimit-cut s] or @ref[~delimit-cut h]:
@itemize[
@item{@ref[~delimit-cut h] if the subpattern is a @tech{proper @Hpattern}}
@item{@ref[~delimit-cut s] otherwise}
From 1054c504ead66fc348487ec726c92bb83a51bd67 Mon Sep 17 00:00:00 2001
From: Ryan Culpepper
Date: Thu, 3 Feb 2011 14:32:34 -0700
Subject: [PATCH 22/68] fix macro stepper bug (missing hash) Merge to release
branch
---
collects/macro-debugger/syntax-browser/widget.rkt | 4 ++--
collects/macro-debugger/view/step-display.rkt | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/collects/macro-debugger/syntax-browser/widget.rkt b/collects/macro-debugger/syntax-browser/widget.rkt
index fd75cdd0ff..b84fddc62f 100644
--- a/collects/macro-debugger/syntax-browser/widget.rkt
+++ b/collects/macro-debugger/syntax-browser/widget.rkt
@@ -117,8 +117,8 @@
(send -text change-style clickback-style a b)))))
(define/public (add-syntax stx
- #:binders [binders #f]
- #:shift-table [shift-table #f]
+ #:binders [binders '#hash()]
+ #:shift-table [shift-table '#hash()]
#:definites [definites #f]
#:hi-colors [hi-colors null]
#:hi-stxss [hi-stxss null]
diff --git a/collects/macro-debugger/view/step-display.rkt b/collects/macro-debugger/view/step-display.rkt
index 51259a617e..d2f6f7d58d 100644
--- a/collects/macro-debugger/view/step-display.rkt
+++ b/collects/macro-debugger/view/step-display.rkt
@@ -84,9 +84,9 @@
(show-poststep step shift-table)]))
(define/public (add-syntax stx
- #:binders [binders #f]
+ #:binders [binders '#hash()]
#:definites [definites #f]
- #:shift-table [shift-table #f])
+ #:shift-table [shift-table '#hash()])
(send/i sbview sb:syntax-browser<%> add-syntax stx
#:binders binders
#:definites definites
From 9d42ef9235e40de846fc480d6fcd13fa0f00a929 Mon Sep 17 00:00:00 2001
From: Ryan Culpepper
Date: Thu, 3 Feb 2011 16:42:05 -0700
Subject: [PATCH 23/68] fixed race in rackunit gui Merge to release branch
---
collects/rackunit/private/gui/view.rkt | 67 ++++++++++++++------------
1 file changed, 36 insertions(+), 31 deletions(-)
diff --git a/collects/rackunit/private/gui/view.rkt b/collects/rackunit/private/gui/view.rkt
index 79315f597f..4de4a148df 100644
--- a/collects/rackunit/private/gui/view.rkt
+++ b/collects/rackunit/private/gui/view.rkt
@@ -71,8 +71,16 @@ still be there, just not visible?
(view this)
(controller controller)))
- ;; for update management
- (define update-queue (make-hasheq))
+ ;; Update management
+ ;; Do adds in order, then updates in any order (hash).
+
+ ;; add-queue : (listof (-> void))
+ (define add-queue null)
+
+ ;; update-queue : (imm-hashof model<%> #t)
+ (define update-queue '#hasheq())
+
+ ;; update-lock : semaphore
(define update-lock (make-semaphore 1))
(send editor lock #t)
@@ -83,12 +91,6 @@ still be there, just not visible?
;; View Links
- (define/public (create-view-link model parent)
- (parameterize ((current-eventspace eventspace))
- (queue-callback
- (lambda ()
- (send tree-view create-view-link model parent)))))
-
(define/private (get-view-link model)
(send tree-view get-view-link model))
@@ -108,10 +110,18 @@ still be there, just not visible?
;; Update Management
+ ;; create-view-link : model suite-result<%>/#f -> void
+ (define/public (create-view-link model parent)
+ (let ([proc (lambda () (send tree-view create-view-link model parent))])
+ (semaphore-wait update-lock)
+ (set! add-queue (cons proc add-queue))
+ (semaphore-post update-lock)
+ (process-updates)))
+
;; queue-for-update : model -> void
(define/public (queue-for-update model)
(semaphore-wait update-lock)
- (hash-set! update-queue model #t)
+ (set! update-queue (hash-set update-queue model #t))
(semaphore-post update-lock)
(process-updates))
@@ -120,38 +130,33 @@ still be there, just not visible?
(parameterize ((current-eventspace eventspace))
(queue-callback
(lambda ()
- (let ([models-to-update (grab+clear-update-queue)])
- (for ([model models-to-update])
+ (let-values ([(adds updates) (grab+clear-update-queue)])
+ (for ([add (in-list adds)])
+ (add))
+ (for ([model (in-hash-keys updates)])
(do-model-update model)))))))
- ;; grab+clear-update-queue : -> void
+ ;; grab+clear-update-queue : -> (values list hash)
;; ** Must be called from eventspace thread.
(define/private (grab+clear-update-queue)
(semaphore-wait update-lock)
- (if (positive? (hash-count update-queue))
- (let ([old-queue update-queue])
- (set! update-queue (make-hasheq))
- (semaphore-post update-lock)
- (reverse
- (hash-map old-queue (lambda (k v) k))))
- (begin (semaphore-post update-lock)
- null)))
+ (begin0
+ (values (reverse add-queue)
+ update-queue)
+ (set! add-queue null)
+ (set! update-queue '#hasheq())
+ (semaphore-post update-lock)))
;; do-model-update : model<%> -> void
;; ** Must be called from eventspace thread.
(define/private (do-model-update model)
(let ([view-link (get-view-link model)])
- (cond [view-link
- (send tree-view update-item view-link)
- (when (eq? model (get-selected-model))
- (show-model model))]
- [(not view-link)
- ;; If the view-link has not been created,
- ;; yield until it is.
- (unless (yield)
- (error 'rackunit-gui
- "internal error: no progress waiting for view-link"))
- (do-model-update model)])))
+ (unless view-link
+ ;; should not be possible
+ (error 'rackunit-gui "internal error: no view-link"))
+ (send tree-view update-item view-link)
+ (when (eq? model (get-selected-model))
+ (show-model model))))
;; Update display
From e3c02f7072638719d3d7b81cd3dcde4c1171a101 Mon Sep 17 00:00:00 2001
From: Ryan Culpepper
Date: Thu, 3 Feb 2011 16:53:49 -0700
Subject: [PATCH 24/68] auto-open top-level test suites in rackunit gui Merge
to release branch
---
collects/rackunit/private/gui/view.rkt | 25 ++++++++++++++-----------
1 file changed, 14 insertions(+), 11 deletions(-)
diff --git a/collects/rackunit/private/gui/view.rkt b/collects/rackunit/private/gui/view.rkt
index 4de4a148df..9a716b04f5 100644
--- a/collects/rackunit/private/gui/view.rkt
+++ b/collects/rackunit/private/gui/view.rkt
@@ -222,19 +222,22 @@ still be there, just not visible?
;; Construction
- ;; create-view-link : result<%> suite-result<%>/#f-> item
+ ;; create-view-link : result<%> suite-result<%>/#f-> void
(define/public (create-view-link model parent)
- (let ([parent-link
- (if parent
- (get-view-link parent)
- this)])
- (initialize-view-link (cond [(is-a? model suite<%>)
- (send parent-link new-list)]
- [(is-a? model case<%>)
- (send parent-link new-item)])
- model)))
+ (let* ([parent-link
+ (if parent
+ (get-view-link parent)
+ this)]
+ [view-link
+ (cond [(is-a? model suite<%>)
+ (send parent-link new-list)]
+ [(is-a? model case<%>)
+ (send parent-link new-item)])])
+ (initialize-view-link view-link model)
+ (when (and (is-a? model suite<%>) (not parent))
+ (send view-link open))))
- ;; initialize-view-link : result<%> (U compound-item% item%) -> item
+ ;; initialize-view-link : result<%> (U compound-item% item%) -> void
(define/private (initialize-view-link item model)
(set-view-link model item)
(send item user-data model)
From d2a6da75617b3c97235f489188c50daa3aab23b8 Mon Sep 17 00:00:00 2001
From: Eli Barzilay
Date: Thu, 3 Feb 2011 21:24:11 -0500
Subject: [PATCH 25/68] Proxy the irc logs from pre.racket-lang.org.
That's where the bot needs to run; use a proxy instead of NFS.
---
collects/meta/web/www/irc.rkt | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/collects/meta/web/www/irc.rkt b/collects/meta/web/www/irc.rkt
index 5e10970200..42835d509e 100644
--- a/collects/meta/web/www/irc.rkt
+++ b/collects/meta/web/www/irc.rkt
@@ -11,9 +11,14 @@
@page[#:title "IRC" #:part-of 'community]{
@iframe[src: webchat-link width: "100%" height: "400"]})
-(define irc-logs-symlink
- (symlink "/home/scheme/irc-logs/racket/" "irc-logs"))
-(define (irc-logs text) @a[href: (list irc-logs-symlink "/")]{@text})
+(define irc-logs
+ (let ()
+ @plain[#:file "irc-logs/.htaccess" #:referrer values]{
+ RewriteEngine on
+ RewriteRule ^(.*)$ http://pre.racket-lang.org@;
+ /irc-logs/@||racket/@|"$1"| [P]
+ }
+ (lambda (text) @a[href: "irc-logs/"]{@text})))
(define (irc-quick)
@parlist[@strong{Discussion Channel}
From c4661de04926b08757efbd1d483fa6512f110f69 Mon Sep 17 00:00:00 2001
From: Eli Barzilay
Date: Fri, 4 Feb 2011 04:30:12 -0500
Subject: [PATCH 26/68] Bump version numbers of mzscheme and mred.
(These things should not be used anymore.)
---
collects/mred/info.rkt | 2 +-
collects/mzscheme/info.rkt | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/collects/mred/info.rkt b/collects/mred/info.rkt
index 9b6cbaad87..c522ee60d2 100644
--- a/collects/mred/info.rkt
+++ b/collects/mred/info.rkt
@@ -1,4 +1,4 @@
#lang setup/infotab
-(define version '(400))
+(define version '(510))
(define post-install-collection "installer.rkt")
diff --git a/collects/mzscheme/info.rkt b/collects/mzscheme/info.rkt
index 0ec5662c1f..dd99f67f26 100644
--- a/collects/mzscheme/info.rkt
+++ b/collects/mzscheme/info.rkt
@@ -1,6 +1,6 @@
#lang setup/infotab
-(define version '(400))
+(define version '(510))
(define post-install-collection "installer.rkt")
From ab588eb69ad01acdd24ee82f0d37471767c64c59 Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Thu, 3 Feb 2011 13:16:39 -0700
Subject: [PATCH 27/68] fix doc bug Closes PR 11690 Merge to 5.1
---
collects/scribblings/guide/pattern-macros.scrbl | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/collects/scribblings/guide/pattern-macros.scrbl b/collects/scribblings/guide/pattern-macros.scrbl
index 4a967768fc..877b7fc3df 100644
--- a/collects/scribblings/guide/pattern-macros.scrbl
+++ b/collects/scribblings/guide/pattern-macros.scrbl
@@ -3,6 +3,8 @@
scribble/eval
"guide-utils.ss")
+@(define swap-eval (make-base-eval))
+
@title[#:tag "pattern-macros"]{Pattern-Based Macros}
A @deftech{pattern-based macro} replaces any code that matches a
@@ -247,9 +249,9 @@ Given our macro definitions, the @racket[swap] or @racket[rotate]
identifiers must be used after an open parenthesis, otherwise a syntax
error is reported:
-@interaction-eval[(define-syntax swap (syntax-rules ()))]
+@interaction-eval[#:eval swap-eval (define-syntax swap (syntax-rules ()))]
-@interaction[(+ swap 3)]
+@interaction[#:eval swap-eval (+ swap 3)]
An @deftech{identifier macro} works in any expression. For example, we
can define @racket[clock] as an identifier macro that expands to
@@ -481,3 +483,6 @@ Racket with just three small pattern-based macros:
@racket[define-cbr], @racket[define-for-cbr], and
@racket[define-get/put-id].
+@; -----------------------------------------------------------------
+
+@close-eval[swap-eval]
From 913f6b54868d594e4d47b84618df353f418a1805 Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Fri, 4 Feb 2011 07:11:48 -0700
Subject: [PATCH 28/68] fix dc<%> Closes PR 11706 Merge to 5.1
---
collects/racket/draw/private/dc-intf.rkt | 68 +++++++++++++++++++++++-
1 file changed, 67 insertions(+), 1 deletion(-)
diff --git a/collects/racket/draw/private/dc-intf.rkt b/collects/racket/draw/private/dc-intf.rkt
index d0f9801192..c5f53ec415 100644
--- a/collects/racket/draw/private/dc-intf.rkt
+++ b/collects/racket/draw/private/dc-intf.rkt
@@ -6,4 +6,70 @@
(define dc<%>
(interface ()
- draw-text))
+ cache-font-metrics-key
+ clear
+ copy
+ draw-arc
+ draw-bitmap
+ draw-bitmap-section
+ draw-ellipse
+ draw-line
+ draw-lines
+ draw-path
+ draw-point
+ draw-polygon
+ draw-rectangle
+ draw-rounded-rectangle
+ draw-spline
+ draw-text
+ end-doc
+ end-page
+ erase
+ flush
+ get-alpha
+ get-background
+ get-brush
+ get-char-height
+ get-char-width
+ get-clipping-region
+ get-font
+ get-gl-context
+ get-initial-matrix
+ get-origin
+ get-pen
+ get-rotation
+ get-scale
+ get-size
+ get-smoothing
+ get-text-background
+ get-text-extent
+ get-text-foreground
+ get-text-mode
+ get-transformation
+ glyph-exists?
+ ok?
+ resume-flush
+ rotate
+ scale
+ set-alpha
+ set-background
+ set-brush
+ set-clipping-rect
+ set-clipping-region
+ set-font
+ set-initial-matrix
+ set-origin
+ set-pen
+ set-rotation
+ set-scale
+ set-smoothing
+ set-text-background
+ set-text-foreground
+ set-text-mode
+ set-transformation
+ start-doc
+ start-page
+ suspend-flush
+ transform
+ translate
+ try-color))
From 5d1b78384d390520edf970021bc0c144f78c259e Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Fri, 4 Feb 2011 07:25:02 -0700
Subject: [PATCH 29/68] cocoa: fix problems with `radio-box%' in no-selection
mode Closes PR 11708 Merge to 5.1
---
collects/mred/private/wx/cocoa/radio-box.rkt | 21 ++++++++++++++------
1 file changed, 15 insertions(+), 6 deletions(-)
diff --git a/collects/mred/private/wx/cocoa/radio-box.rkt b/collects/mred/private/wx/cocoa/radio-box.rkt
index 237ec581d1..558418df55 100644
--- a/collects/mred/private/wx/cocoa/radio-box.rkt
+++ b/collects/mred/private/wx/cocoa/radio-box.rkt
@@ -26,6 +26,9 @@
#:mixins (FocusResponder KeyMouseResponder CursorDisplayer)
[wxb]
(-a _void (clicked: [_id sender])
+ ;; In case we were in 0-item mode, switch to Radio mode to
+ ;; ensure that only one button is selected:
+ (tellv self setMode: #:type _int NSRadioModeMatrix)
(queue-window*-event wxb (lambda (wx) (send wx clicked)))))
(define-objc-class MyImageButtonCell NSButtonCell
@@ -127,15 +130,21 @@
(if (= i -1)
(begin
;; Need to change to NSListModeMatrix to disable all.
- ;; It seem that we don't have to change the mode back, for some reason.
(tellv (get-cocoa) setMode: #:type _int NSListModeMatrix)
(tellv (get-cocoa) deselectAllCells))
- (tellv (get-cocoa) selectCellAtRow: #:type _NSInteger (if horiz? 0 i)
- column: #:type _NSInteger (if horiz? i 0))))
+ (begin
+ (tellv (get-cocoa) setMode: #:type _int NSRadioModeMatrix)
+ (tellv (get-cocoa) selectCellAtRow: #:type _NSInteger (if horiz? 0 i)
+ column: #:type _NSInteger (if horiz? i 0)))))
(define/public (get-selection)
- (if horiz?
- (tell #:type _NSInteger (get-cocoa) selectedColumn)
- (tell #:type _NSInteger (get-cocoa) selectedRow)))
+ (let ([c (tell (get-cocoa) selectedCell)]
+ [pos (if horiz?
+ (tell #:type _NSInteger (get-cocoa) selectedColumn)
+ (tell #:type _NSInteger (get-cocoa) selectedRow))])
+ (if (and c
+ (positive? (tell #:type _NSInteger c state)))
+ pos
+ -1)))
(define/public (number) count)
(define/override (maybe-register-as-child parent on?)
From fe0525b7bb2d585d5eca1e62d0bfcee00b39d311 Mon Sep 17 00:00:00 2001
From: Casey Klein
Date: Fri, 4 Feb 2011 06:58:05 -0600
Subject: [PATCH 30/68] Reduces the memory used by the randomized tests
---
.../redex/examples/cont-mark-transform/randomized-tests.rkt | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/collects/redex/examples/cont-mark-transform/randomized-tests.rkt b/collects/redex/examples/cont-mark-transform/randomized-tests.rkt
index 8f14ce49f7..65017dc3df 100644
--- a/collects/redex/examples/cont-mark-transform/randomized-tests.rkt
+++ b/collects/redex/examples/cont-mark-transform/randomized-tests.rkt
@@ -106,7 +106,10 @@
(parameterize ([max-normalization-steps 1000])
(SL-eval (term (∅ / ,expr))))))
(define TL-result
- (TL-eval (term (∅ / (translate ,expr)))))
+ (dynamic-wind
+ (λ () (set-cache-size! 100))
+ (λ () (TL-eval (term (∅ / (translate ,expr)))))
+ (λ () (set-cache-size! 350))))
(or (equal? SL-result TL-result)
(compares-incomparable-keys? expr))))
From e1303dc4006951d7c9e1ebee31d0f5a76ab3c40e Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Fri, 4 Feb 2011 08:49:22 -0700
Subject: [PATCH 31/68] cocoa: change `radio-box%' implementation of no
selected buttons (not sure how I missed the `setAllowsEmptySelection' method
before, but maybe there was some reason to avoid it that I've forgotten
--- so *don't* merge to 5.1)
---
collects/mred/private/wx/cocoa/radio-box.rkt | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/collects/mred/private/wx/cocoa/radio-box.rkt b/collects/mred/private/wx/cocoa/radio-box.rkt
index 558418df55..d52ef15514 100644
--- a/collects/mred/private/wx/cocoa/radio-box.rkt
+++ b/collects/mred/private/wx/cocoa/radio-box.rkt
@@ -28,7 +28,7 @@
(-a _void (clicked: [_id sender])
;; In case we were in 0-item mode, switch to Radio mode to
;; ensure that only one button is selected:
- (tellv self setMode: #:type _int NSRadioModeMatrix)
+ (tellv self setAllowsEmptySelection: #:type _BOOL #f)
(queue-window*-event wxb (lambda (wx) (send wx clicked)))))
(define-objc-class MyImageButtonCell NSButtonCell
@@ -129,13 +129,12 @@
(define/public (set-selection i)
(if (= i -1)
(begin
- ;; Need to change to NSListModeMatrix to disable all.
- (tellv (get-cocoa) setMode: #:type _int NSListModeMatrix)
+ (tellv (get-cocoa) setAllowsEmptySelection: #:type _BOOL #t)
(tellv (get-cocoa) deselectAllCells))
(begin
- (tellv (get-cocoa) setMode: #:type _int NSRadioModeMatrix)
(tellv (get-cocoa) selectCellAtRow: #:type _NSInteger (if horiz? 0 i)
- column: #:type _NSInteger (if horiz? i 0)))))
+ column: #:type _NSInteger (if horiz? i 0))
+ (tellv (get-cocoa) setAllowsEmptySelection: #:type _BOOL #f))))
(define/public (get-selection)
(let ([c (tell (get-cocoa) selectedCell)]
[pos (if horiz?
From 8f404a46187da3c21dcf52185d0912abdf3ba85f Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Fri, 4 Feb 2011 09:19:19 -0700
Subject: [PATCH 32/68] win32: fix horizontal `radio-box%' Merge to 5.1
---
collects/mred/private/wx/win32/radio-box.rkt | 77 +++++++++++---------
1 file changed, 41 insertions(+), 36 deletions(-)
diff --git a/collects/mred/private/wx/win32/radio-box.rkt b/collects/mred/private/wx/win32/radio-box.rkt
index e395003a5e..329f5c8616 100644
--- a/collects/mred/private/wx/win32/radio-box.rkt
+++ b/collects/mred/private/wx/win32/radio-box.rkt
@@ -49,42 +49,47 @@
(define label-bitmaps null)
(define radio-hwnds
- (let loop ([y 0] [w 0] [labels labels])
- (if (null? labels)
- (begin
- (MoveWindow hwnd 0 0 w y #t)
- null)
- (let* ([label (car labels)]
- [bitmap? (label . is-a? . bitmap%)]
- [radio-hwnd
- (CreateWindowExW/control 0
- "PLTBUTTON"
- (if (string? label)
- label
- "")
- (bitwise-ior BS_RADIOBUTTON WS_CHILD WS_CLIPSIBLINGS
- (if bitmap?
- BS_BITMAP
- 0))
- 0 0 0 0
- hwnd
- #f
- hInstance
- #f)])
- (when bitmap?
- (let ([hbitmap (bitmap->hbitmap label)])
- (set! label-bitmaps (cons hbitmap label-bitmaps))
- (SendMessageW radio-hwnd BM_SETIMAGE IMAGE_BITMAP
- (cast hbitmap _HBITMAP _LPARAM))))
- (ShowWindow radio-hwnd SW_SHOW)
- (set-control-font font radio-hwnd)
- (let-values ([(w1 h)
- (auto-size font label 0 0 20 4
- (lambda (w h)
- (MoveWindow radio-hwnd 0 (+ y SEP) w h #t)
- (values w h)))])
- (cons radio-hwnd
- (loop (+ y SEP h) (max w1 w) (cdr labels))))))))
+ (let ([horiz? (memq 'horizontal style)])
+ (let loop ([y 0] [w 0] [labels labels])
+ (if (null? labels)
+ (begin
+ (MoveWindow hwnd 0 0 w y #t)
+ null)
+ (let* ([label (car labels)]
+ [bitmap? (label . is-a? . bitmap%)]
+ [radio-hwnd
+ (CreateWindowExW/control 0
+ "PLTBUTTON"
+ (if (string? label)
+ label
+ "")
+ (bitwise-ior BS_RADIOBUTTON WS_CHILD WS_CLIPSIBLINGS
+ (if bitmap?
+ BS_BITMAP
+ 0))
+ 0 0 0 0
+ hwnd
+ #f
+ hInstance
+ #f)])
+ (when bitmap?
+ (let ([hbitmap (bitmap->hbitmap label)])
+ (set! label-bitmaps (cons hbitmap label-bitmaps))
+ (SendMessageW radio-hwnd BM_SETIMAGE IMAGE_BITMAP
+ (cast hbitmap _HBITMAP _LPARAM))))
+ (ShowWindow radio-hwnd SW_SHOW)
+ (set-control-font font radio-hwnd)
+ (let-values ([(w1 h)
+ (auto-size font label 0 0 20 4
+ (lambda (w1 h1)
+ (if horiz?
+ (MoveWindow radio-hwnd (+ w SEP) 0 w1 h1 #t)
+ (MoveWindow radio-hwnd 0 (+ y SEP) w1 h1 #t))
+ (values w1 h1)))])
+ (cons radio-hwnd
+ (loop (if horiz? (max y h) (+ y SEP h))
+ (if horiz? (+ w SEP w1) (max w1 w))
+ (cdr labels)))))))))
(unless (= val -1)
(SendMessageW (list-ref radio-hwnds val) BM_SETCHECK 1 0))
From 74f8b0e2f13c47cbd13bf1b0a1275ee389fdbdf9 Mon Sep 17 00:00:00 2001
From: Robby Findler
Date: Fri, 4 Feb 2011 13:06:23 -0600
Subject: [PATCH 33/68] add a little more about quasiquote to the guide
Please merge to the 5.1 release branch
---
collects/scribblings/guide/match.scrbl | 16 +++++
collects/scribblings/guide/qq.scrbl | 97 ++++++++++++++++++++++++++
2 files changed, 113 insertions(+)
diff --git a/collects/scribblings/guide/match.scrbl b/collects/scribblings/guide/match.scrbl
index 2918045db4..7025ba9f1a 100644
--- a/collects/scribblings/guide/match.scrbl
+++ b/collects/scribblings/guide/match.scrbl
@@ -119,6 +119,22 @@ pattern variables can be bound to lists of lists of matches:
[(list (list '! x ...) ...) x])
]
+
+The @racket[quasiquote] form (see @secref["qq"] for more about it) can also be used to build patterns.
+While unquoted portions of a normal quasiquoted form mean regular racket evaluation, here unquoted
+portions mean go back to regular pattern matching.
+
+So, in the example below, the with expression is the pattern and it gets rewritten into the
+application expression, using quasiquote as a pattern in the first instance and quasiquote
+to build an expression in the second.
+
+@interaction[
+#:eval match-eval
+(match `{with {x 1} {+ x 1}}
+ [`{with {,id ,rhs} ,body}
+ `{{lambda {,id} ,body} ,rhs}])
+]
+
For information on many more pattern forms, see @racketmodname[racket/match].
Forms like @racket[match-let] and @racket[match-lambda] support
diff --git a/collects/scribblings/guide/qq.scrbl b/collects/scribblings/guide/qq.scrbl
index f9fa41dc49..30b674f2ff 100644
--- a/collects/scribblings/guide/qq.scrbl
+++ b/collects/scribblings/guide/qq.scrbl
@@ -24,6 +24,63 @@ evaluated to produce a value that takes the place of the
`(1 2 ,(+ 1 2), (- 5 1)))
]
+This form can be used to write functions that build lists according to
+certain patterns.
+
+@examples[
+(eval:alts (define (deep n)
+ (cond
+ [(zero? n) 0]
+ [else
+ (#,qq ((#,uq n) (#,uq (deep (- n 1)))))]))
+ (define (deep n)
+ (cond
+ [(zero? n) 0]
+ [else
+ (quasiquote ((unquote n) (unquote (deep (- n 1)))))])))
+(deep 8)
+]
+
+Or even to cheaply construct expressions programmatically. (Of course, 9 times out of 10,
+you should be using a @seclink["macros"]{macro} to do this
+(the 10th time being when you're working through
+a textbook like @hyperlink["http://www.cs.brown.edu/~sk/Publications/Books/ProgLangs/"]{PLAI}).)
+
+@examples[(define (build-exp n)
+ (add-lets n (make-sum n)))
+
+ (eval:alts
+ (define (add-lets n body)
+ (cond
+ [(zero? n) body]
+ [else
+ (#,qq
+ (let ([(#,uq (n->var n)) (#,uq n)])
+ (#,uq (add-lets (- n 1) body))))]))
+ (define (add-lets n body)
+ (cond
+ [(zero? n) body]
+ [else
+ (quasiquote
+ (let ([(unquote (n->var n)) (unquote n)])
+ (unquote (add-lets (- n 1) body))))])))
+
+ (eval:alts
+ (define (make-sum n)
+ (cond
+ [(= n 1) (n->var 1)]
+ [else
+ (#,qq (+ (#,uq (n->var n))
+ (#,uq (make-sum (- n 1)))))]))
+ (define (make-sum n)
+ (cond
+ [(= n 1) (n->var 1)]
+ [else
+ (quasiquote (+ (unquote (n->var n))
+ (unquote (make-sum (- n 1)))))])))
+ (define (n->var n) (string->symbol (format "x~a" n)))
+ (build-exp 3)]
+
The @racket[unquote-splicing] form is similar to @racket[unquote], but
its @racket[_expr] must produce a list, and the
@racket[unquote-splicing] form must appear in a context that produces
@@ -35,6 +92,46 @@ is spliced into the context of its use.
`(1 2 ,@(list (+ 1 2) (- 5 1)) 5))
]
+Using splicing we can revise the construction of our example expressions above
+to have just a single @racket[let] expression and a single @racket[+] expression.
+
+@examples[(eval:alts
+ (define (build-exp n)
+ (add-lets
+ n
+ (#,qq (+ (#,(racket unquote-splicing)
+ (build-list
+ n
+ (λ (x) (n->var (+ x 1)))))))))
+ (define (build-exp n)
+ (add-lets
+ n
+ (quasiquote (+ (unquote-splicing
+ (build-list
+ n
+ (λ (x) (n->var (+ x 1))))))))))
+ (eval:alts
+ (define (add-lets n body)
+ (#,qq
+ (let (#,uq
+ (build-list
+ n
+ (λ (n)
+ (#,qq
+ [(#,uq (n->var (+ n 1))) (#,uq (+ n 1))]))))
+ (#,uq body))))
+ (define (add-lets n body)
+ (quasiquote
+ (let (unquote
+ (build-list
+ n
+ (λ (n)
+ (quasiquote
+ [(unquote (n->var (+ n 1))) (unquote (+ n 1))]))))
+ (unquote body)))))
+ (define (n->var n) (string->symbol (format "x~a" n)))
+ (build-exp 3)]
+
If a @racket[quasiquote] form appears within an enclosing
@racket[quasiquote] form, then the inner @racket[quasiquote]
effectively cancels one layer of @racket[unquote] and
From b4ce4bbd2ce53dc6b1b1ed372514092ce6951ade Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Fri, 4 Feb 2011 12:23:03 -0700
Subject: [PATCH 34/68] add `file/resource'
---
collects/file/resource.rkt | 251 +++++++++++++++++++++++
collects/file/scribblings/file.scrbl | 1 +
collects/file/scribblings/resource.scrbl | 100 +++++++++
collects/tests/racket/mzlib-tests.rktl | 1 +
collects/tests/racket/resource.rktl | 50 +++++
5 files changed, 403 insertions(+)
create mode 100644 collects/file/resource.rkt
create mode 100644 collects/file/scribblings/resource.scrbl
create mode 100644 collects/tests/racket/resource.rktl
diff --git a/collects/file/resource.rkt b/collects/file/resource.rkt
new file mode 100644
index 0000000000..d668497a7c
--- /dev/null
+++ b/collects/file/resource.rkt
@@ -0,0 +1,251 @@
+#lang racket/base
+(require ffi/unsafe
+ ffi/unsafe/define)
+
+(provide get-resource
+ write-resource)
+
+(define _HKEY (_cpointer/null 'HKEY))
+
+(define (const-hkey v)
+ (cast (bitwise-ior v (arithmetic-shift -1 32)) _intptr _HKEY))
+
+(define HKEY_CLASSES_ROOT (const-hkey #x80000000))
+(define HKEY_CURRENT_USER (const-hkey #x80000001))
+(define HKEY_LOCAL_MACHINE (const-hkey #x80000002))
+(define HKEY_USERS (const-hkey #x80000003))
+(define HKEY_CURRENT_CONFIG (const-hkey #x80000005))
+
+(define REG_SZ 1)
+(define REG_BINARY 3)
+(define REG_DWORD 4)
+
+(define (section->hkey who section)
+ (cond
+ [(equal? section "HKEY_CLASSES_ROOT")
+ HKEY_CLASSES_ROOT]
+ [(equal? section "HKEY_CURRENT_CONFIG")
+ HKEY_CURRENT_CONFIG]
+ [(equal? section "HKEY_CURRENT_USER")
+ HKEY_CURRENT_USER]
+ [(equal? section "HKEY_LOCAL_MACHINE")
+ HKEY_LOCAL_MACHINE]
+ [(equal? section "HKEY_USERS")
+ HKEY_USERS]
+ [else
+ (raise-type-error who
+ (string-append
+ "\"HKEY_CLASSES_ROOT\", \"HKEY_CURRENT_CONFIG\", "
+ "\"HKEY_CURRENT_USER\", \"HKEY_LOCAL_MACHINE\", "
+ "or \"HKEY_USERS\"")
+ section)]))
+
+(define advapi-dll (and (eq? (system-type) 'windows)
+ (ffi-lib "Advapi32.dll")))
+
+(define-ffi-definer define-advapi advapi-dll
+ #:default-make-fail make-not-available)
+
+(define win64? (equal? "win32\\x86_64" (path->string (system-library-subpath #f))))
+(define win_abi (if win64? #f 'stdcall))
+
+(define _LONG _long)
+(define _DWORD _int32)
+(define _REGSAM _DWORD)
+
+(define KEY_QUERY_VALUE #x1)
+(define KEY_SET_VALUE #x2)
+
+(define ERROR_SUCCESS 0)
+
+(define-advapi RegOpenKeyExW (_fun #:abi win_abi
+ _HKEY _string/utf-16 _DWORD _REGSAM (hkey : (_ptr o _HKEY))
+ -> (r : _LONG)
+ -> (and (= r ERROR_SUCCESS) hkey)))
+(define-advapi RegCreateKeyExW (_fun #:abi win_abi
+ _HKEY _string/utf-16 (_DWORD = 0)
+ (_pointer = #f) ; class
+ _DWORD ; options
+ _REGSAM
+ _pointer ; security
+ (hkey : (_ptr o _HKEY))
+ (_ptr o _DWORD) ; disposition
+ -> (r : _LONG)
+ -> (and (= r ERROR_SUCCESS) hkey)))
+
+(define-advapi RegQueryValueExW (_fun #:abi win_abi
+ _HKEY _string/utf-16 (_pointer = #f)
+ (type : (_ptr o _DWORD))
+ _pointer (len : (_ptr io _DWORD))
+ -> (r : _LONG)
+ -> (if (= r ERROR_SUCCESS)
+ (values len type)
+ (values #f #f))))
+(define-advapi RegSetValueExW (_fun #:abi win_abi
+ _HKEY _string/utf-16 (_pointer = #f)
+ _DWORD _pointer _DWORD
+ -> (r : _LONG)
+ -> (= r ERROR_SUCCESS)))
+
+(define-advapi RegCloseKey (_fun #:abi win_abi _HKEY -> _LONG))
+
+(define (check-platform who)
+ (unless (eq? 'windows (system-type))
+ (raise
+ (make-exn:fail:unsupported
+ (format "~a: unsupported on this platform" who)
+ (current-continuation-marks)))))
+
+(define (extract-sub-hkey hkey entry op create-key?)
+ (cond
+ [(regexp-match #rx"^(.*)\\\\+([^\\]*)$" entry)
+ => (lambda (m)
+ (let ([sub-hkey (RegOpenKeyExW hkey (cadr m) 0 op)]
+ [sub-entry (caddr m)])
+ (if (and (not sub-hkey)
+ create-key?)
+ (values (RegCreateKeyExW hkey (cadr m) 0 op #f)
+ sub-entry)
+ (values sub-hkey sub-entry))))]
+ [else (values hkey entry)]))
+
+(define (get-resource section entry [value #f] [file #f]
+ #:type [rtype (or (and (box? value)
+ (or
+ (and (exact-integer? (unbox value))
+ 'integer)
+ (and (bytes? (unbox value))
+ 'bytes)))
+ 'string)])
+ (define hkey (section->hkey 'get-resource section))
+ (unless (string? entry)
+ (raise-type-error 'get-resource "string" entry))
+ (unless (or (not value)
+ (and (box? value)
+ (let ([value (unbox value)])
+ (or (string? value) (bytes? value) (exact-integer? value)))))
+ (raise-type-error 'get-resource "box of string, byte string, or exact integer"))
+ (unless (not file)
+ (raise-type-error 'get-resource "#f" file))
+ (unless (memq rtype '(string bytes integer))
+ (raise-type-error 'get-resource "'string, 'bytes, or 'integer" rtype))
+
+ (check-platform 'get-resource)
+
+ (define-values (sub-hkey sub-entry)
+ (extract-sub-hkey hkey entry KEY_QUERY_VALUE #f))
+
+ (and sub-hkey
+ (begin0
+ (let-values ([(len type)
+ ;; Get size, first
+ (RegQueryValueExW sub-hkey sub-entry #f 0)])
+ (and len
+ (let ([s (make-bytes len)])
+ (let-values ([(len2 type2)
+ ;; Get value, now that we have a bytes string of the right size
+ (RegQueryValueExW sub-hkey sub-entry s len)])
+ (and len2
+ (let ([r
+ ;; Unmarhsal according to requested type:
+ (let ([s (cond
+ [(= type REG_SZ)
+ (cast s _pointer _string/utf-16)]
+ [(= type REG_DWORD)
+ (number->string (ptr-ref s _DWORD))]
+ [else
+ s])]
+ [to-string (lambda (s)
+ (if (bytes? s)
+ (bytes->string/utf-8 s #\?)
+ s))])
+ (cond
+ [(eq? rtype 'string) (to-string s)]
+ [(eq? rtype 'integer)
+ (let ([n (string->number (to-string s))])
+ (or (and n (exact-integer? n) n)
+ 0))]
+ [else
+ (if (string? s)
+ (string->bytes/utf-8 s)
+ s)]))])
+ (if (box? value)
+ (begin
+ (set-box! value r)
+ #t)
+ r)))))))
+ (unless (eq? hkey sub-hkey)
+ (RegCloseKey sub-hkey)))))
+
+(define (write-resource section entry value [file #f]
+ #:type [type 'string]
+ #:create-key? [create-key? #f])
+ (define hkey (section->hkey 'write-resource section))
+ (unless (string? entry)
+ (raise-type-error 'write-resource "string" entry))
+ (unless (or (string? value) (bytes? value) (exact-integer? value))
+ (raise-type-error 'write-resource "string, byte string, or exact integer"))
+ (unless (not file)
+ (raise-type-error 'write-resource "#f" file))
+ (unless (memq type '(string bytes dword))
+ (raise-type-error 'write-resource "'string, 'bytes, or 'dword" type))
+
+ (check-platform 'write-resource)
+
+ (define-values (sub-hkey sub-entry)
+ (extract-sub-hkey hkey entry KEY_SET_VALUE create-key?))
+
+ (and sub-hkey
+ (begin0
+ (let ([v (case type
+ [(string)
+ (to-utf-16
+ (cond
+ [(exact-integer? value) (number->string value)]
+ [(string? value) value]
+ [else (bytes->string/utf-8 value #\?)]))]
+ [(bytes)
+ (cond
+ [(exact-integer? value)
+ (string->bytes/utf-8 (number->string value))]
+ [(string? value) (string->bytes/utf-8 value)]
+ [else value])]
+ [(dword)
+ (to-dword-ptr
+ (cond
+ [(exact-integer? value) value]
+ [(string? value) (string->number value)]
+ [(bytes? value)
+ (string->number (bytes->string/utf-8 value #\?))]))])]
+ [ty (case type
+ [(string) REG_SZ]
+ [(bytes) REG_BINARY]
+ [(dword) REG_DWORD])])
+ (RegSetValueExW sub-hkey sub-entry ty v (bytes-length v)))
+ (unless (eq? hkey sub-hkey)
+ (RegCloseKey sub-hkey)))))
+
+(define (to-utf-16 s)
+ (let ([v (malloc _gcpointer)])
+ (ptr-set! v _string/utf-16 s)
+ (let ([p (ptr-ref v _gcpointer)])
+ (let ([len (* 2 (+ 1 (utf-16-length s)))])
+ (ptr-ref v (_bytes o len))))))
+
+(define (utf-16-length s)
+ (for/fold ([len 0]) ([c (in-string s)])
+ (+ len
+ (if ((char->integer c) . > . #xFFFF)
+ 2
+ 1))))
+
+(define (to-dword-ptr v)
+ (let ([v (if (and (exact-integer? v)
+ (<= (- (expt 2 31))
+ v
+ (sub1 (expt 2 31))))
+ v
+ 0)])
+ (let ([p (malloc _DWORD)])
+ (ptr-set! p _DWORD v)
+ (cast p _pointer (_bytes o (ctype-sizeof _DWORD))))))
diff --git a/collects/file/scribblings/file.scrbl b/collects/file/scribblings/file.scrbl
index e9ccc91601..4ab38c6d8a 100644
--- a/collects/file/scribblings/file.scrbl
+++ b/collects/file/scribblings/file.scrbl
@@ -13,6 +13,7 @@
@include-section["md5.scrbl"]
@include-section["sha1.scrbl"]
@include-section["gif.scrbl"]
+@include-section["resource.scrbl"]
@(bibliography
(bib-entry #:key "Gervautz1990"
diff --git a/collects/file/scribblings/resource.scrbl b/collects/file/scribblings/resource.scrbl
new file mode 100644
index 0000000000..4fc5254a68
--- /dev/null
+++ b/collects/file/scribblings/resource.scrbl
@@ -0,0 +1,100 @@
+#lang scribble/doc
+@(require "common.ss"
+ (for-label file/resource))
+
+@title[#:tag "resource"]{Windows Registry}
+
+@defmodule[file/resource]
+
+@defproc[(get-resource [section (or/c "HKEY_CLASSES_ROOT"
+ "HKEY_CURRENT_CONFIG"
+ "HKEY_CURRENT_USER"
+ "HKEY_LOCAL_MACHINE"
+ "HKEY_USERS")]
+ [entry string?]
+ [value-box (or/f #f (box/c (or/c string? bytes? exact-integer?))) #f]
+ [file #f #f]
+ [#:type type (or/c 'string 'bytes 'integer) _derived-from-value-box])
+ (or/c #f string? bytes? exact-integer? #t)]{
+
+Gets a value from the Windows registry. Under platforms other than
+ Windows, an @racket[exn:fail:unsupported] exception is raised.
+
+The resource value is keyed on the combination of @racket[section] and
+ @racket[entry]. The result is @racket[#f] if no value is found for
+ the specified @racket[section] and @racket[entry]. If @racket[value-box]
+ is a box, then the result is @racket[#t] if a value is found, and the
+ box is filled with the value; when @racket[value-box] is @racket[#f], the result is the found
+ value.
+
+The @racket[type] argument determines how a value in the registry is
+ converted to a Racket value. If @racket[value-box] is a box, then the
+ default @racket[type] is derived from the initial box content,
+ otherwise the default @racket[type] is @racket['string].
+
+Registry values of any format can be extracted. Values using the
+ registry format @tt{REG_SZ} are treated as strings, and values with
+ the format @tt{REG_DWORD} are treated as 32-bit signed integers. All
+ other formats are treated as raw bytes. Data from the registry is
+ converted to the requested type @racket[type]:
+
+@itemlist[
+
+ @item{A @tt{REG_SZ} registry value is converted to an integer using
+ @racket[string->number] (using @racket[0] if the result is not
+ an exact integer), and it is converted to bytes using
+ @racket[string->bytes/utf-8].}
+
+ @item{A @tt{REG_DWORD} registry value is converted to a string or
+ byte string via @racket[number->string] and (for byte strings)
+ @racket[string->bytes/utf-8].}
+
+ @item{Any other kind of registry value is converted to a string or
+ integer using @racket[bytes->string/utf-8] and (for integers)
+ @racket[string->number].}
+
+]
+
+The @racket[file] argument is included for backward compatibility and
+ must be @racket[#f].
+
+To get the ``default'' value for an entry, use a trailing backslash. For
+example, the following expression gets a command line for starting a
+browser:
+
+@racketblock[
+ (get-resource "HKEY_CLASSES_ROOT"
+ "htmlfile\\shell\\open\\command\\")
+]}
+
+@defproc[(write-resource [section (or/c "HKEY_CLASSES_ROOT"
+ "HKEY_CURRENT_CONFIG"
+ "HKEY_CURRENT_USER"
+ "HKEY_LOCAL_MACHINE"
+ "HKEY_USERS")]
+ [entry string?]
+ [value (or/c string? bytes? exact-integer?)]
+ [file #f #f]
+ [#:type type (or/c 'string 'bytes 'integer) 'string]
+ [#:create-key? create-key? any/c #f])
+ boolean?]{
+
+Write a value to the Windows registry. Under platforms other than
+ Windows, an @racket[exn:fail:unsupported] exception is raised.
+
+The resource value is keyed on the combination of @racket[section] and
+ @racket[entry]. If @racket[create-key?] is false, the resource entry
+ must already exist, otherwise the write fails. The result is
+ @racket[#f] if the write fails or @racket[#t] if it succeeds.
+
+The @racket[type] argument determines the format of the value in the
+ registry: @racket['string] writes using the @tt{REG_SZ} format,
+ @racket['bytes] writes using the @tt{REG_BINARY} format, and
+ @racket['dword] writes using the @tt{REG_DWORD} format. Any kind of
+ @racket[value] can be converted for any kind of @racket[type] using
+ the inverse of the conversions for @racket[get-resource].
+
+The @racket[file] argument must be @racket[#f]. A path is allowed for
+ backward compatibility of arguments, but providing a path causes an
+ @racket[exn:fail:unsupported] exception to be raised.}
+
diff --git a/collects/tests/racket/mzlib-tests.rktl b/collects/tests/racket/mzlib-tests.rktl
index 81fc47b394..5305a069b0 100644
--- a/collects/tests/racket/mzlib-tests.rktl
+++ b/collects/tests/racket/mzlib-tests.rktl
@@ -27,5 +27,6 @@
(load-in-sandbox "shared.rktl")
(load-in-sandbox "kw.rktl")
(load-in-sandbox "macrolib.rktl")
+(load-in-sandbox "resource.rktl")
(report-errs)
diff --git a/collects/tests/racket/resource.rktl b/collects/tests/racket/resource.rktl
new file mode 100644
index 0000000000..9ab8b8c98f
--- /dev/null
+++ b/collects/tests/racket/resource.rktl
@@ -0,0 +1,50 @@
+
+;; This test modifies registry entries under Windows
+;; within HKEY_CURRENT_USER\Software\PLT
+
+(load-relative "loadtest.rktl")
+
+(Section 'resource)
+
+(require file/resource)
+
+(when (eq? 'windows (system-type))
+ (define key "HKEY_CURRENT_USER")
+ (define (entry s) (string-append "SOFTWARE\\PLT\\" s))
+
+ (test #t 'init (write-resource key (entry "Stuff") "Hello" #:create-key? #t))
+
+ ;; A string-valued resource:
+ (test #t write-resource key (entry "Stuff") "Hola")
+ (test "Hola" get-resource key (entry "Stuff"))
+ (test #"Hola" get-resource key (entry "Stuff") #:type 'bytes)
+ (test 0 get-resource key (entry "Stuff") #:type 'integer)
+ (let ([b (box "")])
+ (test #t get-resource key (entry "Stuff") b)
+ (test "Hola" unbox b))
+ (let ([b (box #"")])
+ (test #t get-resource key (entry "Stuff") b)
+ (test #"Hola" unbox b))
+ (let ([b (box 10)])
+ (test #t get-resource key (entry "Stuff") b)
+ (test 0 unbox b))
+
+ ;; An integer-valued resource
+ (test #t write-resource key (entry "Count") 17 #:type 'dword)
+ (test "17" get-resource key (entry "Count"))
+ (test #"17" get-resource key (entry "Count") #:type 'bytes)
+ (test 17 get-resource key (entry "Count") #:type 'integer)
+ (test #t write-resource key (entry "Count") -17 #:type 'dword)
+ (test -17 get-resource key (entry "Count") #:type 'integer)
+
+ ;; A bytes-valued resource:
+ (test #t write-resource key (entry "Data") #"i\377mage" #:type 'bytes)
+ (test "i?mage" get-resource key (entry "Data"))
+ (test #"i\377mage" get-resource key (entry "Data") #:type 'bytes)
+ (test 0 get-resource key (entry "Data") #:type 'integer)
+
+ (void))
+
+(report-errs)
+
+
From 337500552c8bbf3c3078236a483c889003b2a44c Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Fri, 4 Feb 2011 14:24:22 -0700
Subject: [PATCH 35/68] `file/resource': improve compatibility by generating
"failure" results instead of exn:fail:unsupported
---
collects/file/resource.rkt | 37 ++++++-----------
collects/file/scribblings/resource.scrbl | 40 +++++++-----------
collects/tests/racket/resource.rktl | 53 ++++++++++++++----------
3 files changed, 60 insertions(+), 70 deletions(-)
diff --git a/collects/file/resource.rkt b/collects/file/resource.rkt
index d668497a7c..3ff776541c 100644
--- a/collects/file/resource.rkt
+++ b/collects/file/resource.rkt
@@ -32,13 +32,9 @@
HKEY_LOCAL_MACHINE]
[(equal? section "HKEY_USERS")
HKEY_USERS]
+ [(string? section) #f]
[else
- (raise-type-error who
- (string-append
- "\"HKEY_CLASSES_ROOT\", \"HKEY_CURRENT_CONFIG\", "
- "\"HKEY_CURRENT_USER\", \"HKEY_LOCAL_MACHINE\", "
- "or \"HKEY_USERS\"")
- section)]))
+ (raise-type-error who "string" section)]))
(define advapi-dll (and (eq? (system-type) 'windows)
(ffi-lib "Advapi32.dll")))
@@ -89,15 +85,10 @@
(define-advapi RegCloseKey (_fun #:abi win_abi _HKEY -> _LONG))
-(define (check-platform who)
- (unless (eq? 'windows (system-type))
- (raise
- (make-exn:fail:unsupported
- (format "~a: unsupported on this platform" who)
- (current-continuation-marks)))))
-
-(define (extract-sub-hkey hkey entry op create-key?)
+(define (extract-sub-hkey file hkey entry op create-key?)
(cond
+ [(not (eq? 'windows (system-type))) (values #f #f)]
+ [file #f]
[(regexp-match #rx"^(.*)\\\\+([^\\]*)$" entry)
=> (lambda (m)
(let ([sub-hkey (RegOpenKeyExW hkey (cadr m) 0 op)]
@@ -125,15 +116,14 @@
(let ([value (unbox value)])
(or (string? value) (bytes? value) (exact-integer? value)))))
(raise-type-error 'get-resource "box of string, byte string, or exact integer"))
- (unless (not file)
- (raise-type-error 'get-resource "#f" file))
+ (unless (or (not file)
+ (path-string? file))
+ (raise-type-error 'get-resource "path string or #f" file))
(unless (memq rtype '(string bytes integer))
(raise-type-error 'get-resource "'string, 'bytes, or 'integer" rtype))
- (check-platform 'get-resource)
-
(define-values (sub-hkey sub-entry)
- (extract-sub-hkey hkey entry KEY_QUERY_VALUE #f))
+ (extract-sub-hkey file hkey entry KEY_QUERY_VALUE #f))
(and sub-hkey
(begin0
@@ -185,15 +175,14 @@
(raise-type-error 'write-resource "string" entry))
(unless (or (string? value) (bytes? value) (exact-integer? value))
(raise-type-error 'write-resource "string, byte string, or exact integer"))
- (unless (not file)
- (raise-type-error 'write-resource "#f" file))
+ (unless (or (not file)
+ (path-string? file))
+ (raise-type-error 'write-resource "path string or #f" file))
(unless (memq type '(string bytes dword))
(raise-type-error 'write-resource "'string, 'bytes, or 'dword" type))
- (check-platform 'write-resource)
-
(define-values (sub-hkey sub-entry)
- (extract-sub-hkey hkey entry KEY_SET_VALUE create-key?))
+ (extract-sub-hkey file hkey entry KEY_SET_VALUE create-key?))
(and sub-hkey
(begin0
diff --git a/collects/file/scribblings/resource.scrbl b/collects/file/scribblings/resource.scrbl
index 4fc5254a68..ff290dce1b 100644
--- a/collects/file/scribblings/resource.scrbl
+++ b/collects/file/scribblings/resource.scrbl
@@ -2,23 +2,27 @@
@(require "common.ss"
(for-label file/resource))
+@(define-syntax-rule (compat section indexed-racket)
+ @elem{For backward compatibilty, the
+ result is @racket[#f] for platforms other than Windows, when
+ @racket[file] is not @racket[#f], or when @racket[section] is not
+ @indexed-racket["HKEY_CLASSES_ROOT"],
+ @indexed-racket["HKEY_CURRENT_CONFIG"],
+ @indexed-racket["HKEY_CURRENT_USER"],
+ @indexed-racket["HKEY_LOCAL_MACHINE"], or @indexed-racket["HKEY_USERS"].})
+
@title[#:tag "resource"]{Windows Registry}
@defmodule[file/resource]
-@defproc[(get-resource [section (or/c "HKEY_CLASSES_ROOT"
- "HKEY_CURRENT_CONFIG"
- "HKEY_CURRENT_USER"
- "HKEY_LOCAL_MACHINE"
- "HKEY_USERS")]
+@defproc[(get-resource [section string?]
[entry string?]
[value-box (or/f #f (box/c (or/c string? bytes? exact-integer?))) #f]
- [file #f #f]
+ [file (or/c #f fail-path?) #f]
[#:type type (or/c 'string 'bytes 'integer) _derived-from-value-box])
(or/c #f string? bytes? exact-integer? #t)]{
-Gets a value from the Windows registry. Under platforms other than
- Windows, an @racket[exn:fail:unsupported] exception is raised.
+Gets a value from the Windows registry. @compat[section indexed-racket]
The resource value is keyed on the combination of @racket[section] and
@racket[entry]. The result is @racket[#f] if no value is found for
@@ -55,9 +59,6 @@ Registry values of any format can be extracted. Values using the
]
-The @racket[file] argument is included for backward compatibility and
- must be @racket[#f].
-
To get the ``default'' value for an entry, use a trailing backslash. For
example, the following expression gets a command line for starting a
browser:
@@ -67,20 +68,15 @@ browser:
"htmlfile\\shell\\open\\command\\")
]}
-@defproc[(write-resource [section (or/c "HKEY_CLASSES_ROOT"
- "HKEY_CURRENT_CONFIG"
- "HKEY_CURRENT_USER"
- "HKEY_LOCAL_MACHINE"
- "HKEY_USERS")]
+@defproc[(write-resource [section string?]
[entry string?]
[value (or/c string? bytes? exact-integer?)]
- [file #f #f]
+ [file (or/c path-string? #f) #f]
[#:type type (or/c 'string 'bytes 'integer) 'string]
[#:create-key? create-key? any/c #f])
boolean?]{
-Write a value to the Windows registry. Under platforms other than
- Windows, an @racket[exn:fail:unsupported] exception is raised.
+Write a value to the Windows registry. @compat[section racket]
The resource value is keyed on the combination of @racket[section] and
@racket[entry]. If @racket[create-key?] is false, the resource entry
@@ -92,9 +88,5 @@ The @racket[type] argument determines the format of the value in the
@racket['bytes] writes using the @tt{REG_BINARY} format, and
@racket['dword] writes using the @tt{REG_DWORD} format. Any kind of
@racket[value] can be converted for any kind of @racket[type] using
- the inverse of the conversions for @racket[get-resource].
-
-The @racket[file] argument must be @racket[#f]. A path is allowed for
- backward compatibility of arguments, but providing a path causes an
- @racket[exn:fail:unsupported] exception to be raised.}
+ the inverse of the conversions for @racket[get-resource].}
diff --git a/collects/tests/racket/resource.rktl b/collects/tests/racket/resource.rktl
index 9ab8b8c98f..7f6a77da8e 100644
--- a/collects/tests/racket/resource.rktl
+++ b/collects/tests/racket/resource.rktl
@@ -8,40 +8,49 @@
(require file/resource)
-(when (eq? 'windows (system-type))
+(let ()
(define key "HKEY_CURRENT_USER")
(define (entry s) (string-append "SOFTWARE\\PLT\\" s))
+ (define (rtest* kws kvs r . l)
+ (if (eq? 'windows (system-type))
+ (keyword-apply test kws kvs r l)
+ (keyword-apply test kws kvs #f l)))
+ (define rtest (make-keyword-procedure rtest*))
+ (define (xtest r alt-r . l)
+ (if (eq? 'windows (system-type))
+ (apply test r l)
+ (apply test alt-r l)))
- (test #t 'init (write-resource key (entry "Stuff") "Hello" #:create-key? #t))
+ (rtest #t 'init (write-resource key (entry "Stuff") "Hello" #:create-key? #t))
;; A string-valued resource:
- (test #t write-resource key (entry "Stuff") "Hola")
- (test "Hola" get-resource key (entry "Stuff"))
- (test #"Hola" get-resource key (entry "Stuff") #:type 'bytes)
- (test 0 get-resource key (entry "Stuff") #:type 'integer)
+ (rtest #t write-resource key (entry "Stuff") "Hola")
+ (rtest "Hola" get-resource key (entry "Stuff"))
+ (rtest #"Hola" get-resource key (entry "Stuff") #:type 'bytes)
+ (rtest 0 get-resource key (entry "Stuff") #:type 'integer)
(let ([b (box "")])
- (test #t get-resource key (entry "Stuff") b)
- (test "Hola" unbox b))
+ (rtest #t get-resource key (entry "Stuff") b)
+ (xtest "Hola" "" unbox b))
(let ([b (box #"")])
- (test #t get-resource key (entry "Stuff") b)
- (test #"Hola" unbox b))
+ (rtest #t get-resource key (entry "Stuff") b)
+ (xtest #"Hola" #"" unbox b))
(let ([b (box 10)])
- (test #t get-resource key (entry "Stuff") b)
- (test 0 unbox b))
+ (rtest #t get-resource key (entry "Stuff") b)
+ (xtest 0 10 unbox b))
;; An integer-valued resource
- (test #t write-resource key (entry "Count") 17 #:type 'dword)
- (test "17" get-resource key (entry "Count"))
- (test #"17" get-resource key (entry "Count") #:type 'bytes)
- (test 17 get-resource key (entry "Count") #:type 'integer)
- (test #t write-resource key (entry "Count") -17 #:type 'dword)
- (test -17 get-resource key (entry "Count") #:type 'integer)
+ (rtest #t write-resource key (entry "Count") 17 #:type 'dword)
+ (rtest "17" get-resource key (entry "Count"))
+ (rtest #"17" get-resource key (entry "Count") #:type 'bytes)
+ (rtest 17 get-resource key (entry "Count") #:type 'integer)
+ (rtest #t write-resource key (entry "Count") -17 #:type 'dword)
+ (rtest -17 get-resource key (entry "Count") #:type 'integer)
;; A bytes-valued resource:
- (test #t write-resource key (entry "Data") #"i\377mage" #:type 'bytes)
- (test "i?mage" get-resource key (entry "Data"))
- (test #"i\377mage" get-resource key (entry "Data") #:type 'bytes)
- (test 0 get-resource key (entry "Data") #:type 'integer)
+ (rtest #t write-resource key (entry "Data") #"i\377mage" #:type 'bytes)
+ (rtest "i?mage" get-resource key (entry "Data"))
+ (rtest #"i\377mage" get-resource key (entry "Data") #:type 'bytes)
+ (rtest 0 get-resource key (entry "Data") #:type 'integer)
(void))
From 755b3d2df24401dee60f419fdd79393cef7e5c99 Mon Sep 17 00:00:00 2001
From: Ryan Culpepper
Date: Thu, 3 Feb 2011 18:56:49 -0700
Subject: [PATCH 36/68] improve rackunit gui performance
---
collects/rackunit/gui.rkt | 4 ++-
collects/rackunit/private/gui/controller.rkt | 4 +--
collects/rackunit/private/gui/view.rkt | 32 ++++++++++++--------
3 files changed, 25 insertions(+), 15 deletions(-)
diff --git a/collects/rackunit/gui.rkt b/collects/rackunit/gui.rkt
index 4238316dd3..8baf65ae35 100644
--- a/collects/rackunit/gui.rkt
+++ b/collects/rackunit/gui.rkt
@@ -4,7 +4,9 @@
"private/gui/gui.rkt")
(define (test/gui . tests)
- (apply (make-gui-runner) tests))
+ (let ([runner (make-gui-runner)])
+ (sleep 0.1) ;; give the gui a chance to initialize
+ (apply runner tests)))
(define test/c (or/c rackunit-test-case? rackunit-test-suite?))
diff --git a/collects/rackunit/private/gui/controller.rkt b/collects/rackunit/private/gui/controller.rkt
index 4742523cc6..97e76bc123 100644
--- a/collects/rackunit/private/gui/controller.rkt
+++ b/collects/rackunit/private/gui/controller.rkt
@@ -52,8 +52,8 @@
;; on-model-status-change : model<%> -> void
(define/public (on-model-status-change model)
- ;; (check-ready) ;; allow completion of tests to change status
- (send view queue-for-update model)
+ (let ([view view]) ;; view field is async. mutable!
+ (when view (send view queue-for-update model)))
(let [(parent (send model get-parent))]
(when parent (send parent on-child-status-change model))))
diff --git a/collects/rackunit/private/gui/view.rkt b/collects/rackunit/private/gui/view.rkt
index 9a716b04f5..2089f1cd61 100644
--- a/collects/rackunit/private/gui/view.rkt
+++ b/collects/rackunit/private/gui/view.rkt
@@ -83,6 +83,10 @@ still be there, just not visible?
;; update-lock : semaphore
(define update-lock (make-semaphore 1))
+ ;; update-timer : timer%
+ (define update-timer
+ (new timer% (notify-callback (lambda () (process-updates)))))
+
(send editor lock #t)
(with-handlers ([exn:fail? void])
(send -hpane set-percentages VIEW-PANE-PERCENTS))
@@ -115,26 +119,30 @@ still be there, just not visible?
(let ([proc (lambda () (send tree-view create-view-link model parent))])
(semaphore-wait update-lock)
(set! add-queue (cons proc add-queue))
- (semaphore-post update-lock)
- (process-updates)))
+ (updates-pending!)
+ (semaphore-post update-lock)))
;; queue-for-update : model -> void
(define/public (queue-for-update model)
(semaphore-wait update-lock)
(set! update-queue (hash-set update-queue model #t))
- (semaphore-post update-lock)
- (process-updates))
+ (updates-pending!)
+ (semaphore-post update-lock))
+
+ ;; updates-pending! : -> void
+ (define/private (updates-pending!)
+ (send update-timer start 50 #t))
;; process-updates : -> void
+ ;; ** Must be called from eventspace thread.
(define/private (process-updates)
- (parameterize ((current-eventspace eventspace))
- (queue-callback
- (lambda ()
- (let-values ([(adds updates) (grab+clear-update-queue)])
- (for ([add (in-list adds)])
- (add))
- (for ([model (in-hash-keys updates)])
- (do-model-update model)))))))
+ (let-values ([(adds updates) (grab+clear-update-queue)])
+ (send (send tree-view get-editor) begin-edit-sequence #f)
+ (for ([add (in-list adds)])
+ (add))
+ (for ([model (in-hash-keys updates)])
+ (do-model-update model))
+ (send (send tree-view get-editor) end-edit-sequence)))
;; grab+clear-update-queue : -> (values list hash)
;; ** Must be called from eventspace thread.
From 2c1d49de6f4b10f8ea921a5c6fc03729c72878d4 Mon Sep 17 00:00:00 2001
From: Ryan Culpepper
Date: Fri, 4 Feb 2011 15:35:51 -0700
Subject: [PATCH 37/68] fixed macro stepper bug Merge to release branch
---
collects/macro-debugger/model/reductions.rkt | 17 ++++++++++++++---
1 file changed, 14 insertions(+), 3 deletions(-)
diff --git a/collects/macro-debugger/model/reductions.rkt b/collects/macro-debugger/model/reductions.rkt
index 925d3f2b1e..2eb58fbaa5 100644
--- a/collects/macro-debugger/model/reductions.rkt
+++ b/collects/macro-debugger/model/reductions.rkt
@@ -1,5 +1,6 @@
#lang racket/base
(require racket/match
+ (for-syntax racket/base)
"../util/eomap.rkt"
"stx-util.rkt"
"deriv-util.rkt"
@@ -34,9 +35,16 @@
;; Syntax
-(define-syntax-rule (match/count x . clauses)
+(define-syntax-rule (match/count x clause ...)
(begin (sequence-number (add1 (sequence-number)))
- (match x . clauses)))
+ (let ([v x])
+ (match v
+ clause ...
+ [_ (error 'match "failed to match ~e at line ~s" v (line-of x))]))))
+
+(define-syntax (line-of stx)
+ (syntax-case stx ()
+ [(line-of x) #`(quote #,(syntax-line #'x))]))
;; Derivations => Steps
@@ -472,7 +480,10 @@
;; Add remark step?
]]
[(struct local-remark (contents))
- (R [#:reductions (list (walk/talk 'remark contents))])]))
+ (R [#:reductions (list (walk/talk 'remark contents))])]
+
+ [#f
+ (R)]))
;; List : ListDerivation -> RST
(define (List ld)
From 845ca2d58668c40c2ce2ab314867974877b2da93 Mon Sep 17 00:00:00 2001
From: Matthew Flatt
Date: Fri, 4 Feb 2011 19:17:11 -0700
Subject: [PATCH 38/68] cocoa: yet another hack around weird cocoa behavior
Closes PR 11712 Merge to 5.1
---
collects/mred/private/wx/cocoa/slider.rkt | 7 +++++++
collects/mred/private/wx/cocoa/window.rkt | 7 ++++++-
2 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/collects/mred/private/wx/cocoa/slider.rkt b/collects/mred/private/wx/cocoa/slider.rkt
index c0e820e3c8..e735287d69 100644
--- a/collects/mred/private/wx/cocoa/slider.rkt
+++ b/collects/mred/private/wx/cocoa/slider.rkt
@@ -8,6 +8,7 @@
"const.rkt"
"utils.rkt"
"window.rkt"
+ "queue.rkt"
"../common/event.rkt"
"../common/queue.rkt"
"../common/freeze.rkt"
@@ -158,6 +159,12 @@
(define/public (update-message [val (get-value)])
(tellv message-cocoa setTitleWithMnemonic: #:type _NSString (format "~a" val)))
+ (inherit get-cocoa-window)
+ (define/override (post-mouse-down)
+ ;; For some reason, dragging a slider disabled mouse-moved
+ ;; events for the window, so turn them back on:
+ (tellv (get-cocoa-window) setAcceptsMouseMovedEvents: #:type _BOOL #t))
+
(define/override (maybe-register-as-child parent on?)
(register-as-child parent on?)))
diff --git a/collects/mred/private/wx/cocoa/window.rkt b/collects/mred/private/wx/cocoa/window.rkt
index 409b6ef5eb..906c034978 100644
--- a/collects/mred/private/wx/cocoa/window.rkt
+++ b/collects/mred/private/wx/cocoa/window.rkt
@@ -98,7 +98,10 @@
[wxb]
[-a _void (mouseDown: [_id event])
(unless (do-mouse-event wxb event 'left-down #t #f #f 'right-down)
- (super-tell #:type _void mouseDown: event))]
+ (super-tell #:type _void mouseDown: event)
+ (let ([wx (->wx wxb)])
+ (when wx
+ (send wx post-mouse-down))))]
[-a _void (mouseUp: [_id event])
(unless (do-mouse-event wxb event 'left-up #f #f #f 'right-up)
(super-tell #:type _void mouseUp: event))]
@@ -727,6 +730,8 @@
[caps-down #f])
#f))
+ (define/public (post-mouse-down) (void))
+
(define/public (on-char s) (void))
(define/public (on-event m) (void))
(define/public (queue-on-size) (void))
From 760a58b65df2b91010d2bcc2739ddab2a4489729 Mon Sep 17 00:00:00 2001
From: David Van Horn
Date: Fri, 4 Feb 2011 16:46:32 -0500
Subject: [PATCH 39/68] Fixes more spelling errors.
---
collects/2htdp/image.rkt | 2 +-
collects/2htdp/tests/test-image.rkt | 2 +-
collects/2htdp/uchat/chatter.rkt | 2 +-
collects/algol60/cfg-parser.rkt | 2 +-
.../private-combinator/errors.scm | 14 +++++++-------
collects/compiler/embed-unit.rkt | 2 +-
collects/drracket/private/module-language.rkt | 2 +-
collects/drracket/private/syncheck-debug.rkt | 2 +-
.../private/syncheck/contract-traversal.rkt | 2 +-
collects/drracket/private/unit.rkt | 2 +-
collects/dynext/dynext.scrbl | 2 +-
collects/embedded-gui/doc.txt | 2 +-
collects/embedded-gui/private/alignment.rkt | 14 +++++++-------
collects/ffi/examples/magick.rkt | 2 +-
collects/ffi/unsafe/objc.rkt | 2 +-
collects/file/tar.rkt | 2 +-
collects/framework/private/group.rkt | 2 +-
collects/framework/private/handler.rkt | 2 +-
collects/framework/private/text.rkt | 4 ++--
collects/frtime/gui/demo/instr.rkt | 2 +-
collects/games/blackjack/blackjack.rkt | 2 +-
collects/games/chat-noir/chat-noir-literate.rkt | 2 +-
collects/games/crazy8s/crazy8s.rkt | 2 +-
collects/games/gobblet/model.rkt | 2 +-
collects/games/gofish/gofish.rkt | 2 +-
collects/games/jewel/jewel.scm | 2 +-
collects/games/parcheesi/moves.rkt | 2 +-
collects/games/scribblings/paint-by-numbers.scrbl | 2 +-
collects/games/scribblings/pousse.scrbl | 2 +-
.../graphics/scribblings/traditional-turtles.scrbl | 2 +-
collects/guibuilder/top-level.rkt | 4 ++--
collects/handin-server/main.rkt | 2 +-
collects/help/bug-report.rkt | 2 +-
collects/htdp/arrow-gui.rkt | 2 +-
collects/htdp/arrow.rkt | 2 +-
collects/htdp/big-draw.rkt | 2 +-
collects/htdp/convert.rkt | 2 +-
collects/meta/dist-specs.rkt | 4 ++--
collects/meta/web/stubs/pre.rkt | 6 +++---
collects/mred/private/misc.rkt | 2 +-
collects/mred/private/seqcontract.rkt | 6 +++---
collects/mred/private/wx/cocoa/gauge.rkt | 2 +-
collects/mred/private/wxme/pasteboard.rkt | 4 ++--
collects/mred/private/wxme/text.rkt | 4 ++--
collects/mrlib/cache-image-snip.rkt | 2 +-
collects/mrlib/name-message.rkt | 2 +-
.../mrlib/private/aligned-pasteboard/alignment.rkt | 14 +++++++-------
.../private/aligned-pasteboard/pasteboard-lib.rkt | 2 +-
collects/mrlib/scribblings/tex-table.scrbl | 2 +-
collects/mzlib/sandbox.rkt | 2 +-
collects/mzscheme/examples/bitmatrix.c | 2 +-
collects/net/ftp-unit.rkt | 2 +-
collects/plai/scribblings/plai.scrbl | 2 +-
collects/plot/renderer-helpers.rkt | 2 +-
collects/preprocessor/doc.txt | 2 +-
collects/preprocessor/scribblings/mzpp.scrbl | 2 +-
collects/preprocessor/scribblings/mztext.scrbl | 2 +-
collects/profile/scribblings/analyzer.scrbl | 4 ++--
collects/racket/contract/regions.rkt | 2 +-
collects/racket/private/class-internal.rkt | 2 +-
collects/racket/private/kw.rkt | 2 +-
collects/racket/private/reqprov.rkt | 2 +-
collects/redex/private/matcher.rkt | 2 +-
collects/scribblings/framework/editor.scrbl | 4 ++--
collects/scribblings/framework/text.scrbl | 2 +-
collects/scribblings/guide/performance.scrbl | 2 +-
collects/scribblings/raco/exe-api.scrbl | 2 +-
collects/scribblings/raco/plt.scrbl | 2 +-
collects/scribblings/reference/memory.scrbl | 2 +-
collects/scribblings/reference/reader.scrbl | 4 ++--
collects/scribblings/scribble/srcdoc.scrbl | 2 +-
collects/setup/main.rkt | 2 +-
collects/srfi/27/random-bits.rkt | 2 +-
collects/srfi/32/sort.txt | 2 +-
collects/srfi/42/generators.scm | 2 +-
collects/srfi/43/vector-lib.rkt | 2 +-
collects/stepper/private/annotate.rkt | 2 +-
collects/swindle/clos.rkt | 2 +-
collects/swindle/tiny-clos.rkt | 2 +-
collects/teachpack/2htdp/scribblings/image.scrbl | 2 +-
collects/tests/framework/README | 4 ++--
.../tests/plai/gc/good-mutators/classic-error.rkt | 2 +-
collects/tests/r6rs/run/contrib.sps | 2 +-
collects/tests/racket/contract-mzlib-test.rktl | 2 +-
collects/tests/racket/contract-test.rktl | 2 +-
collects/tests/racket/struct.rktl | 2 +-
collects/tests/racket/uni-norm.rktl | 2 +-
collects/tests/run-automated-tests.rkt | 2 +-
.../optimizer/tests/unboxed-let-functions8.rkt | 2 +-
collects/tests/typed-scheme/succeed/hw01.scm | 2 +-
.../tests/typed-scheme/succeed/random-bits.rkt | 2 +-
collects/texpict/doc.txt | 2 +-
collects/typed-scheme/env/global-env.rkt | 2 +-
collects/typed-scheme/optimizer/unboxed-let.rkt | 2 +-
collects/typed-scheme/typecheck/tc-app.rkt | 2 +-
.../htdocs/servlets/examples/quiz.rkt | 2 +-
doc/release-notes/drracket/HISTORY.txt | 8 ++++----
doc/release-notes/gracket/HISTORY.txt | 2 +-
doc/release-notes/gracket/MrEd_100_Framework.txt | 4 ++--
doc/release-notes/racket/HISTORY.txt | 4 ++--
doc/srfi-std/srfi-1.html | 2 +-
doc/srfi-std/srfi-17.html | 2 +-
doc/srfi-std/srfi-19.html | 2 +-
doc/srfi-std/srfi-23.html | 4 ++--
doc/srfi-std/srfi-27.html | 4 ++--
doc/srfi-std/srfi-4.html | 2 +-
doc/srfi-std/srfi-43.html | 2 +-
doc/srfi-std/srfi-48.html | 4 ++--
doc/srfi-std/srfi-59.html | 2 +-
doc/srfi-std/srfi-60.html | 4 ++--
doc/srfi-std/srfi-67/srfi-67.html | 2 +-
doc/srfi-std/srfi-69.html | 2 +-
doc/srfi-std/srfi-78.html | 4 ++--
doc/srfi-std/srfi-9.html | 4 ++--
src/racket/gc2/README | 4 ++--
src/racket/sconfig.h | 2 +-
src/racket/sgc/autostat.inc | 2 +-
src/racket/sgc/sgc.c | 4 ++--
src/racket/src/eval.c | 2 +-
src/racket/src/fun.c | 6 +++---
src/racket/src/gmp/README | 4 ++--
src/racket/src/jit.c | 4 ++--
src/racket/src/mk-uchar.rkt | 2 +-
src/racket/src/module.c | 2 +-
src/racket/src/number.c | 2 +-
src/racket/src/port.c | 4 ++--
src/racket/src/print.c | 4 ++--
src/racket/src/schemex.h | 2 +-
src/racket/src/schustr.inc | 2 +-
src/racket/src/string.c | 2 +-
src/racket/src/stxobj.c | 2 +-
src/racket/src/syntax.c | 2 +-
src/racket/src/thread.c | 2 +-
src/racket/src/unwind/libunwind.c | 2 +-
src/racket/src/unwind/libunwind.h | 2 +-
135 files changed, 185 insertions(+), 185 deletions(-)
diff --git a/collects/2htdp/image.rkt b/collects/2htdp/image.rkt
index 9ac051eee3..d73e3be9b1 100644
--- a/collects/2htdp/image.rkt
+++ b/collects/2htdp/image.rkt
@@ -11,7 +11,7 @@ method returns #f, then you get a black circle out.
improvments/changes wrt to htdp/image:
- copying and pasting does not introduce jaggies
- - equal comparisions are more efficient
+ - equal comparisons are more efficient
- added rotation & scaling
- got rid of pinholes (see the new overlay, beside, and above functions)
- a bunch of new polygon functions
diff --git a/collects/2htdp/tests/test-image.rkt b/collects/2htdp/tests/test-image.rkt
index 1973616d66..70a70f2af8 100644
--- a/collects/2htdp/tests/test-image.rkt
+++ b/collects/2htdp/tests/test-image.rkt
@@ -2203,7 +2203,7 @@
(let loop ([obj obj])
(when (struct? obj)
(let ([stuff (vector->list (struct->vector obj))])
- (unless (member (car stuff) '(struct:flip struct:translate struct:scale)) ;; skip these becuase normalization eliminates them
+ (unless (member (car stuff) '(struct:flip struct:translate struct:scale)) ;; skip these because normalization eliminates them
(hash-set! counts (car stuff) (+ 1 (hash-ref counts (car stuff) 0))))
(for-each loop (cdr stuff)))))
(sort (hash-map counts list) string<=? #:key (λ (x) (symbol->string (car x))))))
diff --git a/collects/2htdp/uchat/chatter.rkt b/collects/2htdp/uchat/chatter.rkt
index f7e33cdc83..07019d966e 100644
--- a/collects/2htdp/uchat/chatter.rkt
+++ b/collects/2htdp/uchat/chatter.rkt
@@ -20,7 +20,7 @@
+------------------------------------------------------------------+
Convention: the names of participants may not contain ":".
- The first typed ":" separates the addressess from the message.
+ The first typed ":" separates the addresses from the message.
TODO:
-- the editing of too-tall send messages is a bit off screen.
diff --git a/collects/algol60/cfg-parser.rkt b/collects/algol60/cfg-parser.rkt
index 04a22975ef..b3e2573064 100644
--- a/collects/algol60/cfg-parser.rkt
+++ b/collects/algol60/cfg-parser.rkt
@@ -627,7 +627,7 @@
l))))
pats (caddr old-list))))
nt-ids patss)
- ;; Build a definiton for each non-term:
+ ;; Build a definition for each non-term:
(loop (cdr clauses)
cfg-start
(map (lambda (nt pats handles $ctxs)
diff --git a/collects/combinator-parser/private-combinator/errors.scm b/collects/combinator-parser/private-combinator/errors.scm
index 9c27d6a9d8..2133481439 100644
--- a/collects/combinator-parser/private-combinator/errors.scm
+++ b/collects/combinator-parser/private-combinator/errors.scm
@@ -95,7 +95,7 @@
name curr-id message-to-date))]
[(sub-seq choice)
(fail-type->message (sequence-fail-found fail-type)
- (add-to-message (msg (format "An error occured in ~a.\n" id-name))
+ (add-to-message (msg (format "An error occurred in ~a.\n" id-name))
name (sequence-fail-id fail-type) message-to-date))]
[(options)
(let ([sorted-opts (sort (options-fail-opts (sequence-fail-found fail-type))
@@ -138,7 +138,7 @@
[else msg])])
(collapse-message
(add-to-message
- (msg (format "An error occured in the ~a. Possible errors were: \n ~a"
+ (msg (format "An error occurred in the ~a. Possible errors were: \n ~a"
name
(alternate-error-list (map err-msg messages))))
name #f message-to-date)))]))]
@@ -172,7 +172,7 @@
(equal? top-names no-dup-names))
(collapse-message
(add-to-message
- (msg (format "An error occured in this ~a; expected ~a instead."
+ (msg (format "An error occurred in this ~a; expected ~a instead."
name (nice-list no-dup-names)))
name #f message-to-date))]
[(and (<= (choice-fail-options fail-type) max-choice-depth)
@@ -184,13 +184,13 @@
(collapse-message
(add-to-message (car messages) #f #f
(add-to-message
- (msg (format "An error occured in this ~a, expected ~a instead."
+ (msg (format "An error occurred in this ~a, expected ~a instead."
name (nice-list no-dup-names)))
name #f message-to-date)))]
[else
(collapse-message
(add-to-message
- (msg (format "An error occured in this ~a; expected ~a instead. Possible errors were:\n~a"
+ (msg (format "An error occurred in this ~a; expected ~a instead. Possible errors were:\n~a"
name (nice-list no-dup-names)
(alternate-error-list (map err-msg messages))))
name #f message-to-date))]))]
@@ -198,7 +198,7 @@
(> (length winners) 1))
(collapse-message
(add-to-message
- (msg (format "An error occured in this ~a. Possible options include ~a.\n"
+ (msg (format "An error occurred in this ~a. Possible options include ~a.\n"
name (nice-list
(first-n max-choice-depth no-dup-names))))
name #f message-to-date))]
@@ -206,7 +206,7 @@
(fail-type->message
(car winners)
(add-to-message
- (msg (format "An error occured in this ~a~a.~a\n"
+ (msg (format "An error occurred in this ~a~a.~a\n"
name
(if (equal? name top-name) "" (format ", it is possible you intended ~a ~a here"
(a/an top-name) top-name))
diff --git a/collects/compiler/embed-unit.rkt b/collects/compiler/embed-unit.rkt
index 6d7121b59c..4385ad07d3 100644
--- a/collects/compiler/embed-unit.rkt
+++ b/collects/compiler/embed-unit.rkt
@@ -623,7 +623,7 @@
[(name)
;; a notification; if the name matches one of our special names,
;; assume that it's from a namespace that has the declaration
- ;; [it would be better if the noritifer told us the source]
+ ;; [it would be better if the notifier told us the source]
(let-values ([(name) (if name (resolved-module-path-name name) #f)])
(let-values ([(a) (assq name mapping-table)])
(if a
diff --git a/collects/drracket/private/module-language.rkt b/collects/drracket/private/module-language.rkt
index 34916eb38f..2221e58344 100644
--- a/collects/drracket/private/module-language.rkt
+++ b/collects/drracket/private/module-language.rkt
@@ -121,7 +121,7 @@
;; newlines can break things (ie the language text won't
;; be in the right place in the interactions window, which
;; at least makes the test suites unhappy), so get rid of
- ;; them from the name. Otherwise, if there is some wierd formatting,
+ ;; them from the name. Otherwise, if there is some weird formatting,
;; so be it.
(regexp-replace* #rx"[\r\n]+"
(substring str (cdr (car pos)) (string-length str))
diff --git a/collects/drracket/private/syncheck-debug.rkt b/collects/drracket/private/syncheck-debug.rkt
index 186ac31d36..9ff7a14dd9 100644
--- a/collects/drracket/private/syncheck-debug.rkt
+++ b/collects/drracket/private/syncheck-debug.rkt
@@ -124,7 +124,7 @@
(send f show #t))]))
;; build-ht : stx -> hash-table
- ;; the resulting hash-table maps from the each sub-object's to it's syntax.
+ ;; the resulting hash-table maps from the each sub-object's to its syntax.
(define (syntax-object->datum/ht stx)
(let ([ht (make-hash-table)])
(values (let loop ([stx stx])
diff --git a/collects/drracket/private/syncheck/contract-traversal.rkt b/collects/drracket/private/syncheck/contract-traversal.rkt
index 79c35fa89d..4c7e473826 100644
--- a/collects/drracket/private/syncheck/contract-traversal.rkt
+++ b/collects/drracket/private/syncheck/contract-traversal.rkt
@@ -200,7 +200,7 @@
(loop (car val))
(loop (cdr val))])))
-;; returns #t if the result is known to be a predicate that shoudl correspond to a
+;; returns #t if the result is known to be a predicate that should correspond to a
;; complete obligation for the contract. If it is some unknown variable, this variable
;; may refer to some other contract with nested obligations, so we have to return #f here.
;; approximate this by just asking 'did this identifier come from the core?' (which is known
diff --git a/collects/drracket/private/unit.rkt b/collects/drracket/private/unit.rkt
index 8d75db3ddd..45cfe83ddf 100644
--- a/collects/drracket/private/unit.rkt
+++ b/collects/drracket/private/unit.rkt
@@ -451,7 +451,7 @@ module browser threading seems wrong.
(values get-program-editor-mixin
add-to-program-editor-mixin)))
- ;; this sends a message to it's frame when it gets the focus
+ ;; this sends a message to its frame when it gets the focus
(define make-searchable-canvas%
(λ (%)
(class %
diff --git a/collects/dynext/dynext.scrbl b/collects/dynext/dynext.scrbl
index c8f6c67663..210d22ccd2 100644
--- a/collects/dynext/dynext.scrbl
+++ b/collects/dynext/dynext.scrbl
@@ -294,7 +294,7 @@ A parameter that indicates the target for linking, where
@defproc[(use-standard-linker (name (one-of/c 'cc 'gcc 'msvc 'borland 'cw)))
void?]{
-Sets the parameters decribed in @secref["link-params"] for a
+Sets the parameters described in @secref["link-params"] for a
particular known linker.}
diff --git a/collects/embedded-gui/doc.txt b/collects/embedded-gui/doc.txt
index 09ff60afa1..2f0affea80 100644
--- a/collects/embedded-gui/doc.txt
+++ b/collects/embedded-gui/doc.txt
@@ -292,7 +292,7 @@ interface and gives it key bindings to tab ahead and back.
The _set-tabbing_ function sets the tabbing order of
tabbable-text<%>s by setting each text's set-ahead and
-set-back thunks to point to it's neighbor in the argument
+set-back thunks to point to its neighbor in the argument
list.
> (set-tabbing a-text ...)
diff --git a/collects/embedded-gui/private/alignment.rkt b/collects/embedded-gui/private/alignment.rkt
index 593b1fc64b..3a89451e91 100644
--- a/collects/embedded-gui/private/alignment.rkt
+++ b/collects/embedded-gui/private/alignment.rkt
@@ -1,19 +1,19 @@
#|
-This code computes the sizes for the rectangles in the space using the on dimention
-off dimention method of referencing sizes. This means for example instead of saying
-width we say off dimention for vertical alignment. Inorder to consume and return
+This code computes the sizes for the rectangles in the space using the on dimension
+off dimension method of referencing sizes. This means for example instead of saying
+width we say off dimension for vertical alignment. Inorder to consume and return
the values in terms of width and height manipulation had to be done. I chose to create
a struct abs-rect (abstract rectangle) and have code map horizontal and vertical rect
stucts on to them. This code is a bit long but more readable than the other two options
I came up with.
1) define all functions to be letrec bound functions inside align. align then take
- accessors for the rect struct. The caller of align swaps the order of ondimention
- and off dimention accessors for vertical or horizontal code. This method does not
+ accessors for the rect struct. The caller of align swaps the order of ondimension
+ and off dimension accessors for vertical or horizontal code. This method does not
allow the use of the readable, short, consis pattern matching code. As some of the
matching code is easily removed this may be a good option but a large letrec
is harder to write tests for.
2) define a pattern matcher syntax that will match the struct rect but swap the fields
- based on wich on is the on or off dimention. This would have been shorter but much
+ based on which on is the on or off dimension. This would have been shorter but much
more confusing.
The current implementation requires align to map over the rects and allocate new stucts
for each one on both passing into and returning from stretch-to-fit; This is not a bottle
@@ -138,7 +138,7 @@ neck and it is the most readable solution.
(loop rest-rects (+ onpos onsize))))]))))
#;(natural-number? . -> . (-> (union 1 0)))
- ;; makes a thunk that returns 1 for it's first n applications, zero otherwise
+ ;; makes a thunk that returns 1 for its first n applications, zero otherwise
(define (waner n)
(lambda ()
(if (zero? n)
diff --git a/collects/ffi/examples/magick.rkt b/collects/ffi/examples/magick.rkt
index 13bb216cdf..a974d5ce43 100644
--- a/collects/ffi/examples/magick.rkt
+++ b/collects/ffi/examples/magick.rkt
@@ -60,7 +60,7 @@
[(DrawingWand? w) DrawGetException ]
[else (error 'raise-wand-exception "got an unknown value: ~e" w)])
w)
- (error 'wand-exception "an undefined error occured with ~e" w))
+ (error 'wand-exception "an undefined error occurred with ~e" w))
(define-fun-syntax _status
(syntax-id-rules (_status)
diff --git a/collects/ffi/unsafe/objc.rkt b/collects/ffi/unsafe/objc.rkt
index e9019cbea3..345270b9d8 100644
--- a/collects/ffi/unsafe/objc.rkt
+++ b/collects/ffi/unsafe/objc.rkt
@@ -269,7 +269,7 @@
((ctype-sizeof v) . <= . 16))]))
;; Make `msgSends' access atomic, so that a thread cannot be suspended
-;; or killed during access, whcih would block other threads.
+;; or killed during access, which would block other threads.
(define-syntax-rule (as-atomic e)
(begin (start-atomic) (begin0 e (end-atomic))))
diff --git a/collects/file/tar.rkt b/collects/file/tar.rkt
index 9de2b265ee..4170ec8f45 100644
--- a/collects/file/tar.rkt
+++ b/collects/file/tar.rkt
@@ -22,7 +22,7 @@
[len (bytes-length bts)])
(if (< len tar-name-length)
(values bts #f)
- (let loop ([n 1]) ; seach for a split point
+ (let loop ([n 1]) ; search for a split point
(cond [(<= (sub1 len) n)
(error 'tar "path too long for USTAR: ~a" path)]
[(and (eq? sep-char (bytes-ref bts n))
diff --git a/collects/framework/private/group.rkt b/collects/framework/private/group.rkt
index 81811652dd..97bb30575f 100644
--- a/collects/framework/private/group.rkt
+++ b/collects/framework/private/group.rkt
@@ -256,7 +256,7 @@
(define/public (locate-file name)
(let* ([normalized
- ;; allow for the possiblity of filenames that are urls
+ ;; allow for the possibility of filenames that are urls
(with-handlers ([(λ (x) #t)
(λ (x) name)])
(normal-case-path
diff --git a/collects/framework/private/handler.rkt b/collects/framework/private/handler.rkt
index 3890f7eb81..74aeb94d03 100644
--- a/collects/framework/private/handler.rkt
+++ b/collects/framework/private/handler.rkt
@@ -209,7 +209,7 @@
(let ([current-items
(map (λ (x) (and (is-a? x labelled-menu-item<%>) (send x get-label)))
(send menu get-items))]
- ;; the new-items variable shoudl match up to what install-recent-items actually does when it creates the menu
+ ;; the new-items variable should match up to what install-recent-items actually does when it creates the menu
[new-items
(append
(for/list ([recent-list-item recently-opened-files])
diff --git a/collects/framework/private/text.rkt b/collects/framework/private/text.rkt
index bb9e6c9450..db9e3001b2 100644
--- a/collects/framework/private/text.rkt
+++ b/collects/framework/private/text.rkt
@@ -2160,7 +2160,7 @@
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;
- ;; output port syncronization code
+ ;; output port synchronization code
;;
;; flush-chan : (channel (evt void))
@@ -3121,7 +3121,7 @@ designates the character that triggers autocompletion
(show-options word start-pos end-pos completion-cursor)))))
;; Number -> String
- ;; The word that ends at the current positon of the editor
+ ;; The word that ends at the current position of the editor
(define/public (get-word-at current-pos)
(let ([start-pos (box current-pos)])
(find-wordbreak start-pos #f 'caret)
diff --git a/collects/frtime/gui/demo/instr.rkt b/collects/frtime/gui/demo/instr.rkt
index ff87501297..76bf3c9720 100644
--- a/collects/frtime/gui/demo/instr.rkt
+++ b/collects/frtime/gui/demo/instr.rkt
@@ -38,7 +38,7 @@
; apply the mixin
; fr-value-text-field%s will set their value to the value of
-; the event occurances supplied in the initialization argument
+; the event occurrences supplied in the initialization argument
; value-set-e
(define fr-value-text-field% (set-value-lifter text-field%))
diff --git a/collects/games/blackjack/blackjack.rkt b/collects/games/blackjack/blackjack.rkt
index 0629522e3c..702cb4be58 100644
--- a/collects/games/blackjack/blackjack.rkt
+++ b/collects/games/blackjack/blackjack.rkt
@@ -259,7 +259,7 @@
(done "Bust" cont)
(yield cont)))]
;; Callback for the hit button; the button's callback is
- ;; changed for diferent modes: normal, split part 1, or split
+ ;; changed for different modes: normal, split part 1, or split
;; part 2
[make-hit-callback
(lambda (get-p set-p! player-region bust)
diff --git a/collects/games/chat-noir/chat-noir-literate.rkt b/collects/games/chat-noir/chat-noir-literate.rkt
index e72016f0c4..3139f20edf 100644
--- a/collects/games/chat-noir/chat-noir-literate.rkt
+++ b/collects/games/chat-noir/chat-noir-literate.rkt
@@ -257,7 +257,7 @@ to @scheme[#f] and the state of the ``h'' key to
The @scheme[empty-world] function
-generalizes the exmaple by computing the
+generalizes the example by computing the
cats initial position as the center spot on the board.
@chunk[
diff --git a/collects/games/crazy8s/crazy8s.rkt b/collects/games/crazy8s/crazy8s.rkt
index f34c3c6f6b..35db3be78c 100644
--- a/collects/games/crazy8s/crazy8s.rkt
+++ b/collects/games/crazy8s/crazy8s.rkt
@@ -523,7 +523,7 @@
(player-hand-r player)))
players)
- ;; Opponents's cards and deck initally can't be moved
+ ;; Opponents's cards and deck initially can't be moved
(for-each (lambda (card) (send card user-can-move #f))
(append
(apply append
diff --git a/collects/games/gobblet/model.rkt b/collects/games/gobblet/model.rkt
index 8868bc9fd9..cb6c44257d 100644
--- a/collects/games/gobblet/model.rkt
+++ b/collects/games/gobblet/model.rkt
@@ -445,7 +445,7 @@
(let ([v (if who
(compact-board board who)
board)])
- ;; Find cannonical mapping.
+ ;; Find canonical mapping.
(hash-table-get
memory v
(lambda ()
diff --git a/collects/games/gofish/gofish.rkt b/collects/games/gofish/gofish.rkt
index b22d99a98f..fbe2c94fc0 100644
--- a/collects/games/gofish/gofish.rkt
+++ b/collects/games/gofish/gofish.rkt
@@ -126,7 +126,7 @@
(check-hand you (car cards))
(send t set-status YOUR-TURN-MESSAGE))))
-;; More card setup: Opponents's cards and deck initally can't be moved
+;; More card setup: Opponents's cards and deck initially can't be moved
(for-each (lambda (card) (send card user-can-move #f))
(append (player-hand player-1) (player-hand player-2) deck))
diff --git a/collects/games/jewel/jewel.scm b/collects/games/jewel/jewel.scm
index 58d630670f..ca6dd0d019 100644
--- a/collects/games/jewel/jewel.scm
+++ b/collects/games/jewel/jewel.scm
@@ -1431,7 +1431,7 @@
)
- ;; This shouldnt do anything, but it fixes drawing in
+ ;; This shouldn't do anything, but it fixes drawing in
;; Snow Leopard. Bug in the game or in Snow Leopard?
(glEnable GL_LIGHT2)
(glDisable GL_LIGHT2)
diff --git a/collects/games/parcheesi/moves.rkt b/collects/games/parcheesi/moves.rkt
index 990d002ee1..a70e088dac 100644
--- a/collects/games/parcheesi/moves.rkt
+++ b/collects/games/parcheesi/moves.rkt
@@ -396,7 +396,7 @@
[(safety? end)
(bad-move "cannot move onto a safety if someone else is already there")]
- ;; succesful bop
+ ;; successful bop
[else
(values
(move-piece2 board
diff --git a/collects/games/scribblings/paint-by-numbers.scrbl b/collects/games/scribblings/paint-by-numbers.scrbl
index 3e30e79e71..95fcae1404 100644
--- a/collects/games/scribblings/paint-by-numbers.scrbl
+++ b/collects/games/scribblings/paint-by-numbers.scrbl
@@ -39,7 +39,7 @@ permission to re-distribute their puzzles. Visit them online at:
@centerline{@selflink[;"http://www02.so-net.ne.jp/~kajitani/index.html"
"http://nonogram.freehostia.com/pbn/index.html"]}
-The specific contributers who have permitted their puzzles to be
+The specific contributors who have permitted their puzzles to be
redistributed are:
@verbatim[#:indent 2]{
diff --git a/collects/games/scribblings/pousse.scrbl b/collects/games/scribblings/pousse.scrbl
index 56643ac7ab..6bfa4cc5f1 100644
--- a/collects/games/scribblings/pousse.scrbl
+++ b/collects/games/scribblings/pousse.scrbl
@@ -33,7 +33,7 @@ place.
When a marker is inserted, there may be a marker on the square where
the insertion takes place. In this case, all markers on the insertion
-row or column from the insertion square upto the first empty square
+row or column from the insertion square up to the first empty square
are moved one square further to make room for the inserted marker.
Note that the last marker of the row or column will be pushed off the
board (and must be removed from play) if there are no empty squares on
diff --git a/collects/graphics/scribblings/traditional-turtles.scrbl b/collects/graphics/scribblings/traditional-turtles.scrbl
index b1bcfde7ce..f1b18620c3 100644
--- a/collects/graphics/scribblings/traditional-turtles.scrbl
+++ b/collects/graphics/scribblings/traditional-turtles.scrbl
@@ -99,7 +99,7 @@ For example
]
moves a turtle forward 100 pixel while drawing a line, and then moves
-the turtle be immediately back to it's original position. Similarly,
+the turtle be immediately back to its original position. Similarly,
@schemeblock[
(tprompt (split (turn/radians (/ pi 2))))
diff --git a/collects/guibuilder/top-level.rkt b/collects/guibuilder/top-level.rkt
index 0bb59fcdc6..3841fa8687 100644
--- a/collects/guibuilder/top-level.rkt
+++ b/collects/guibuilder/top-level.rkt
@@ -12,13 +12,13 @@
"panel.ss")
;; INVARIANT: If a snip is selected, then no ancestor or
- ;; decendent of the snip can be selected. Otherwise, the
+ ;; descendant of the snip can be selected. Otherwise, the
;; dragging rules get complicated (perhaps impossible).
;; INVARIANT: a child must be ordered before its parent in the
;; pasteboard. Not only does this affect drawing, but it also
;; affects how select-all and rubber-banding work due to the
- ;; ancestor/decendent-selection-exclusion rule.
+ ;; ancestor/descendant-selection-exclusion rule.
(define START-FRAME-WIDTH 100)
(define START-FRAME-HEIGHT 100)
diff --git a/collects/handin-server/main.rkt b/collects/handin-server/main.rkt
index 0684776865..80bc696051 100644
--- a/collects/handin-server/main.rkt
+++ b/collects/handin-server/main.rkt
@@ -326,7 +326,7 @@
(put-preferences
(list (string->symbol username)) (list data)
(lambda (f)
- (error* "user database busy; please try again, and alert the adminstrator if problems persist"))
+ (error* "user database busy; please try again, and alert the administrator if problems persist"))
"users.rktd"))
orig-custodian))
diff --git a/collects/help/bug-report.rkt b/collects/help/bug-report.rkt
index 2e1bf5af9c..575466d278 100644
--- a/collects/help/bug-report.rkt
+++ b/collects/help/bug-report.rkt
@@ -178,7 +178,7 @@
;; important that you cannot go back from this view,
;; or else that might trigger saving the bug report in the preferences
- ;; (but when you're here the bug report should be succesfully submitted)
+ ;; (but when you're here the bug report should be successfully submitted)
(define (switch-to-finished-view finished-text)
(send finished-ec set-editor finished-text)
(unsave-bug-report (saved-report-id init-bug-report))
diff --git a/collects/htdp/arrow-gui.rkt b/collects/htdp/arrow-gui.rkt
index 4d24b04462..9cc6acad57 100644
--- a/collects/htdp/arrow-gui.rkt
+++ b/collects/htdp/arrow-gui.rkt
@@ -36,7 +36,7 @@
;; make-button-table :
;; panel% layout -> (listof (listof (union panel% button%)))
;; to translate a layout table into a button table
-;; each button is controled by (control a-bitmap)
+;; each button is controlled by (control a-bitmap)
(define (make-button-table panel layout)
(local ((define (make-row a-row)
(local ((define row-panel (make-object horizontal-panel% panel))
diff --git a/collects/htdp/arrow.rkt b/collects/htdp/arrow.rkt
index 92e454b9eb..56ffcae8d5 100644
--- a/collects/htdp/arrow.rkt
+++ b/collects/htdp/arrow.rkt
@@ -61,7 +61,7 @@
;; ->
;; (listof (listof (union panel% button%)))
;; to translate a layout table into a button table
-;; each button is controled by (control a-bitmap)
+;; each button is controlled by (control a-bitmap)
(define (make-button-table panel control layout)
(define (make-row a-row)
(define row-panel (make-object horizontal-panel% panel))
diff --git a/collects/htdp/big-draw.rkt b/collects/htdp/big-draw.rkt
index 2f98be4706..9bd6f3b021 100644
--- a/collects/htdp/big-draw.rkt
+++ b/collects/htdp/big-draw.rkt
@@ -231,7 +231,7 @@
;; see ../htdch/draw/support.scm (copy) for explanation and design rationale
(hash-set! h 'copy (lambda () (set! @vp vp*) (set! @pm pm*) [(clear-viewport pm*)]))
;; ---
- ;; --- the following can't happend during a draw sequence ---
+ ;; --- the following can't happen during a draw sequence ---
(set! %wait-for-mouse-click (lambda () (mouse-click-posn (get-mouse-click vp*))))
(set! %get-key-event
(lambda ()
diff --git a/collects/htdp/convert.rkt b/collects/htdp/convert.rkt
index ba538fe1d0..57fe05b29f 100644
--- a/collects/htdp/convert.rkt
+++ b/collects/htdp/convert.rkt
@@ -226,7 +226,7 @@
;; make-reader-for-f : (number -> number) -> ( -> void)
;; make-reader-for-f creates a function that reads numbers from a file
-;; converts them accoring to f, and prints the results
+;; converts them according to f, and prints the results
;; effect: if any of the S-expressions in the file aren't numbers or
;; if any of f's results aren't numbers,
;; the function signals an error
diff --git a/collects/meta/dist-specs.rkt b/collects/meta/dist-specs.rkt
index 221ec26c3c..fd3452b377 100644
--- a/collects/meta/dist-specs.rkt
+++ b/collects/meta/dist-specs.rkt
@@ -50,7 +50,7 @@
;; clauses. Instead of a single , you can use a list of tags. The
;; tags are expanded using definitions made with :=tag, and the result is
;; added to current tag list -- this expansion is a little different from
-;; the normal one in that the result contains all of the defintion it went
+;; the normal one in that the result contains all of the definition it went
;; through (so if x expands to y which expands to z, expanding x will
;; result in x, y, and z).
;; Finally, it is possible to define `macro' constructs by using a lambda spec:
@@ -164,7 +164,7 @@ gui-filter := (- (+ (collects: "**/gui/") (srcfile: "gui.rkt"))
(srcfile: "racket/gui/dynamic.rkt"))
tools-filter := (+ (collects: "**/tools/") (srcfile: "tools.rkt"))
-;; these are in the doc directory, but are comitted in git and should be
+;; these are in the doc directory, but are committed in git and should be
;; considered like sources
std-docs := (doc: "doc-license.txt" "*-std/")
diff --git a/collects/meta/web/stubs/pre.rkt b/collects/meta/web/stubs/pre.rkt
index eb99004fd4..1ba199c89b 100644
--- a/collects/meta/web/stubs/pre.rkt
+++ b/collects/meta/web/stubs/pre.rkt
@@ -214,7 +214,7 @@
mentioned above, for other platforms or something other than retrieving a
full build.
@~
- This script will retreive and install a new build only when one is ready.
+ This script will retrieve and install a new build only when one is ready.
It is suitable for running periodically via a crontab entry. For
example, save it in @tt{~/bin/update-full-racket}, run @tt{crontab -e} to
edit your @tt{crontab} entries, and add a line that looks like this:
@@ -235,8 +235,8 @@
@~ Use variable definitions to make customization easy.
@~ Usages of @tt{$URL} and others are quoted in case they will ever
contain spaces.
- @~ If we fail to retreive a file, we quit the script.
- @~ Use a temporary directory to retreive the tree, and then move it
+ @~ If we fail to retrieve a file, we quit the script.
+ @~ Use a temporary directory to retrieve the tree, and then move it
to its real place (so if it fails we don't end up with no
@tt{racket}) through renaming (if we delete @tt{racket} and then
rename the new one, we might fail halfway into the deletion).
diff --git a/collects/mred/private/misc.rkt b/collects/mred/private/misc.rkt
index 0df2060609..c66afbf001 100644
--- a/collects/mred/private/misc.rkt
+++ b/collects/mred/private/misc.rkt
@@ -48,7 +48,7 @@
;; the alarm is immediately ready. This makes `sleep/yield'
;; more like `sleep':
(wx:yield)
- ;; Now, realy sleep:
+ ;; Now, really sleep:
(wx:yield evt))
(void))
diff --git a/collects/mred/private/seqcontract.rkt b/collects/mred/private/seqcontract.rkt
index 34fad33162..0d22e5d5df 100644
--- a/collects/mred/private/seqcontract.rkt
+++ b/collects/mred/private/seqcontract.rkt
@@ -410,13 +410,13 @@ Matthew
set-before ;SetBefore
set-after ;SetAfter
;ReallyCanEdit -- only when op != wxEDIT_COPY
- ;Refresh has wierd code checking writeLocked -- what does < 0 mean?
+ ;Refresh has weird code checking writeLocked -- what does < 0 mean?
do-paste ; DoPaste
paste ; Paste
insert-port ; InsertPort
insert-file ; InsertFile
read-from-file ; ReadFromFile
- ; BeginEditSequence ;; -- wierd flag check
- ; EndEditSequence ;; -- wierd flag check, like BeginEditSequence
+ ; BeginEditSequence ;; -- weird flag check
+ ; EndEditSequence ;; -- weird flag check, like BeginEditSequence
|#
diff --git a/collects/mred/private/wx/cocoa/gauge.rkt b/collects/mred/private/wx/cocoa/gauge.rkt
index caab798559..4d349cc2d7 100644
--- a/collects/mred/private/wx/cocoa/gauge.rkt
+++ b/collects/mred/private/wx/cocoa/gauge.rkt
@@ -32,7 +32,7 @@
(super-new [parent parent]
[cocoa (let ([cocoa (as-objc-allocation
- ;; Beware that a guage may be finally deallocated in
+ ;; Beware that a gauge may be finally deallocated in
;; a separate OS-level thread
(tell (tell MyProgressIndicator alloc) init))])
(tellv cocoa setIndeterminate: #:type _BOOL #f)
diff --git a/collects/mred/private/wxme/pasteboard.rkt b/collects/mred/private/wxme/pasteboard.rkt
index f52f7c0270..31e5de61e5 100644
--- a/collects/mred/private/wxme/pasteboard.rkt
+++ b/collects/mred/private/wxme/pasteboard.rkt
@@ -1729,10 +1729,10 @@
(set-box! h total-height))
(send s-admin get-view x y w h #t))
(let ([w (if (w . > . 1000.0)
- 500.0 ; don't belive it
+ 500.0 ; don't believe it
w)]
[h (if (h . > . 1000.0)
- 500.0 ; don't belive it
+ 500.0 ; don't believe it
h)])
(values (/ w 2)
(/ h 2)))))
diff --git a/collects/mred/private/wxme/text.rkt b/collects/mred/private/wxme/text.rkt
index d29faf081e..6a75b34e35 100644
--- a/collects/mred/private/wxme/text.rkt
+++ b/collects/mred/private/wxme/text.rkt
@@ -2849,7 +2849,7 @@
(set! write-locked? #t)
(set! flow-locked? #t)
- ;; linear seach for snip
+ ;; linear search for snip
(let ([topy (mline-get-location line)])
(let loop ([snip (mline-snip line)]
[X X]
@@ -3159,7 +3159,7 @@
(values (mline-last-snip line) (+ horiz (- (mline-w line) (mline-last-w line)))
start #f)]
[else
- ;; linear seach for snip
+ ;; linear search for snip
(let loop ([snip (mline-snip line)]
[start start]
[horiz horiz]
diff --git a/collects/mrlib/cache-image-snip.rkt b/collects/mrlib/cache-image-snip.rkt
index 1f26d09620..88f4b2cefe 100644
--- a/collects/mrlib/cache-image-snip.rkt
+++ b/collects/mrlib/cache-image-snip.rkt
@@ -21,7 +21,7 @@
The true meaning of an image is a vector of rationals,
between 0 & 255, representing color and alpha channel
- information. The vector's contents are analagous to
+ information. The vector's contents are analogous to
the last argument to the get-argb-pixels method. That is,
there are (* 4 w h) entries in the vector for an image
of width w and height h, and the entries represent the
diff --git a/collects/mrlib/name-message.rkt b/collects/mrlib/name-message.rkt
index bbb0d956cb..38d94f0bfe 100644
--- a/collects/mrlib/name-message.rkt
+++ b/collects/mrlib/name-message.rkt
@@ -255,7 +255,7 @@
(+ border-inset
circle-spacer
button-label-inset
- (if (eq? (system-type) 'windows) 1 0) ;; becuase "(define ...)" has the wrong size under windows
+ (if (eq? (system-type) 'windows) 1 0) ;; because "(define ...)" has the wrong size under windows
(max 0 (inexact->exact (ceiling tw)))
button-label-inset
triangle-width
diff --git a/collects/mrlib/private/aligned-pasteboard/alignment.rkt b/collects/mrlib/private/aligned-pasteboard/alignment.rkt
index 2741e5277e..3aa0f44bb4 100644
--- a/collects/mrlib/private/aligned-pasteboard/alignment.rkt
+++ b/collects/mrlib/private/aligned-pasteboard/alignment.rkt
@@ -1,19 +1,19 @@
#|
-This code computes the sizees for the rectangles in the space using the on dimention
-off dimention method of referencing sizes. This means for example instead of saying
-width we say off dimention for vertical alignment. Inorder to consume and return
+This code computes the sizees for the rectangles in the space using the on dimension
+off dimension method of referencing sizes. This means for example instead of saying
+width we say off dimension for vertical alignment. Inorder to consume and return
the values in terms of width and height manipulation had to be done. I chose to create
a struct abs-rect (abstract rectangle) and have code map horizontal and vertical rect
stucts on to them. This code is a bit long but more readable than the other two options
I came up with.
1) define all functions to be letrec bound functions inside align. align then take
- accessors for the rect struct. The caller of align swaps the order of ondimention
- and off dimention accessors for vertical or horizontal code. This method does not
+ accessors for the rect struct. The caller of align swaps the order of ondimension
+ and off dimension accessors for vertical or horizontal code. This method does not
allow the use of the readable, short, consis pattern matching code. As some of the
matching code is easily removed this may be a good option but a large letrec
is harder to write tests for.
2) define a pattern matcher syntax that will match the struct rect but swap the fields
- based on wich on is the on or off dimention. This would have been shorter but much
+ based on wich on is the on or off dimension. This would have been shorter but much
more confusing.
The current implementation requires align to map over the rects and allocate new stucts
for each one on both passing into and returning from stretch-to-fit; This is not a bottle
@@ -141,7 +141,7 @@ neck and it is the most readable solution.
(loop rest-rects (+ onpos onsize))))]))))
;; waner (natural-number? . -> . (-> (union 1 0)))
- ;; makes a thunk that returns 1 for it's first n applications, zero otherwise
+ ;; makes a thunk that returns 1 for its first n applications, zero otherwise
(define (waner n)
(lambda ()
(if (zero? n)
diff --git a/collects/mrlib/private/aligned-pasteboard/pasteboard-lib.rkt b/collects/mrlib/private/aligned-pasteboard/pasteboard-lib.rkt
index 50d1ddfcb9..9d6a004253 100644
--- a/collects/mrlib/private/aligned-pasteboard/pasteboard-lib.rkt
+++ b/collects/mrlib/private/aligned-pasteboard/pasteboard-lib.rkt
@@ -27,7 +27,7 @@
[else pasteboard])))
;; gets the canvas or snip that the pasteboard is displayed in
- ;; status: what if there is more than one canvas? should this be allowed? probablly not.
+ ;; status: what if there is more than one canvas? should this be allowed? probably not.
(define (pasteboard-parent pasteboard)
(let ([admin (send pasteboard get-admin)])
(cond
diff --git a/collects/mrlib/scribblings/tex-table.scrbl b/collects/mrlib/scribblings/tex-table.scrbl
index 88a5614db6..477fc9f6c1 100644
--- a/collects/mrlib/scribblings/tex-table.scrbl
+++ b/collects/mrlib/scribblings/tex-table.scrbl
@@ -14,7 +14,7 @@
(= (string-length x)
1)))))]{
- This is an assocation list mapping the shortcut strings that
+ This is an association list mapping the shortcut strings that
DrRacket uses with its @tt{control-\} (or @tt{command-\}) strings to
their corresponding unicode characters. For example, it contains
this mapping:
diff --git a/collects/mzlib/sandbox.rkt b/collects/mzlib/sandbox.rkt
index 3ab4e60d50..569f394863 100644
--- a/collects/mzlib/sandbox.rkt
+++ b/collects/mzlib/sandbox.rkt
@@ -36,7 +36,7 @@
;; Compatbility:
;; * recognize 'r5rs, etc, and wrap them as a list.
;; * 'begin form of reqs
-;; * more agressively extract requires from lang and reqs
+;; * more aggressively extract requires from lang and reqs
(define *make-evaluator
(case-lambda
[(lang reqs . progs)
diff --git a/collects/mzscheme/examples/bitmatrix.c b/collects/mzscheme/examples/bitmatrix.c
index e231a27cc1..ff906c8462 100644
--- a/collects/mzscheme/examples/bitmatrix.c
+++ b/collects/mzscheme/examples/bitmatrix.c
@@ -46,7 +46,7 @@ END_XFORM_SKIP;
#endif
/* We'll get some Scheme primitives so we can calculate with numbers
- taht are potentially bignums: */
+ that are potentially bignums: */
static Scheme_Object *mult, *add, *sub, *modulo, *neg;
/* The type tag for bit matrixes, initialized with scheme_make_type */
diff --git a/collects/net/ftp-unit.rkt b/collects/net/ftp-unit.rkt
index 009d4709fc..f0b43c0b41 100644
--- a/collects/net/ftp-unit.rkt
+++ b/collects/net/ftp-unit.rkt
@@ -30,7 +30,7 @@
;; Checks a standard-format response, checking for the given
;; expected 3-digit result code if expected is not #f.
;;
-;; While checking, the function sends reponse lines to
+;; While checking, the function sends response lines to
;; diagnostic-accum. This function -accum functions can return a
;; value that accumulates over multiple calls to the function, and
;; accum-start is used as the initial value. Use `void' and
diff --git a/collects/plai/scribblings/plai.scrbl b/collects/plai/scribblings/plai.scrbl
index dcddd1240a..dbe35b9c3a 100644
--- a/collects/plai/scribblings/plai.scrbl
+++ b/collects/plai/scribblings/plai.scrbl
@@ -157,7 +157,7 @@ The syntax of @scheme[_pred?] is considered @scheme[_expected-value] for the pur
@defform/subs[(test/exn result-expr error-message)()]{
This test succeeds if the expression evaluates to a call to @scheme[error]. Moreover, the error message contained in the
-exception must contain the string @scheme[_error-message]. Note that @scheme[test/exn] only suceeds if the exception was
+exception must contain the string @scheme[_error-message]. Note that @scheme[test/exn] only succeeds if the exception was
explicitly raised by the user.
For example, the following test succeeds:
diff --git a/collects/plot/renderer-helpers.rkt b/collects/plot/renderer-helpers.rkt
index d224484710..50d8ab6d19 100644
--- a/collects/plot/renderer-helpers.rkt
+++ b/collects/plot/renderer-helpers.rkt
@@ -1,7 +1,7 @@
(module renderer-helpers mzscheme
; Contains the helpers for the plot-renderers package
- ; usefull for building your own renderers
+ ; useful for building your own renderers
(require mzlib/list mzlib/math plot/math)
diff --git a/collects/preprocessor/doc.txt b/collects/preprocessor/doc.txt
index 035dcb82e6..10bb84a0e9 100644
--- a/collects/preprocessor/doc.txt
+++ b/collects/preprocessor/doc.txt
@@ -366,7 +366,7 @@ mztext processing: the standard command dispatcher
`mztext' can use arbitrary magic sequences, but for convenience, there
is a default built-in dispatcher that connects Scheme code with the
preprocessed text -- by default, it is triggered by "@". When file
-processing encounters this marker, control is transfered to the command
+processing encounters this marker, control is transferred to the command
dispatcher. In its turn, the command dispatcher reads a Scheme
expression (using `read'), evaluates it, and decides what to do next.
In case of a simple Scheme value, it is converted to a string and pushed
diff --git a/collects/preprocessor/scribblings/mzpp.scrbl b/collects/preprocessor/scribblings/mzpp.scrbl
index 1d5eb20437..d06e15d423 100644
--- a/collects/preprocessor/scribblings/mzpp.scrbl
+++ b/collects/preprocessor/scribblings/mzpp.scrbl
@@ -115,7 +115,7 @@ because doing this:
Some preprocessing directives happen at the "raw level"---the stage
where text is transformed into Scheme expressions. These directives
-cannot be changed from withing transformed text because they change the
+cannot be changed from within transformed text because they change the
way this transformation happens. Some of these transformation
@itemize[
diff --git a/collects/preprocessor/scribblings/mztext.scrbl b/collects/preprocessor/scribblings/mztext.scrbl
index be60631243..a18790db43 100644
--- a/collects/preprocessor/scribblings/mztext.scrbl
+++ b/collects/preprocessor/scribblings/mztext.scrbl
@@ -41,7 +41,7 @@ explanation of the @DFlag{run} flag.
@exec{mztext} can use arbitrary magic sequences, but for convenience,
there is a default built-in dispatcher that connects Scheme code with
the preprocessed text---by default, it is triggered by @litchar["@"].
-When file processing encounters this marker, control is transfered to
+When file processing encounters this marker, control is transferred to
the command dispatcher. In its turn, the command dispatcher reads a
Scheme expression (using @scheme[read]), evaluates it, and decides
what to do next. In case of a simple Scheme value, it is converted to
diff --git a/collects/profile/scribblings/analyzer.scrbl b/collects/profile/scribblings/analyzer.scrbl
index da5201b4a3..2b8fbd7c00 100644
--- a/collects/profile/scribblings/analyzer.scrbl
+++ b/collects/profile/scribblings/analyzer.scrbl
@@ -51,7 +51,7 @@ Represents the analyzed profile result.
@item{@scheme[thread-times] holds an association list mapping thread
identifiers to cpu time for the corresponding threads. As samples
are collected, each thread that is observed is assigned a small
- integer identifier. These identifers are listed for each function
+ integer identifier. These identifiers are listed for each function
call, and the total time spent in each thread is in this field.}
@item{@scheme[nodes] is a list of nodes representing all observed
@@ -65,7 +65,7 @@ Represents the analyzed profile result.
constructed for every graph. This node is used as the caller for
all top-level function nodes and as the callee for all leaf nodes.
It can therefore be used to start a scan of the call graph. In
- addition, the times associated with it's "callers and callees"
+ addition, the times associated with its "callers and callees"
actually represent the time these functions spent being the root of
the computation or its leaf. (This can be different from a node's
``self'' time, since it is divided by the number of instances a
diff --git a/collects/racket/contract/regions.rkt b/collects/racket/contract/regions.rkt
index d4890ffa39..048f258490 100644
--- a/collects/racket/contract/regions.rkt
+++ b/collects/racket/contract/regions.rkt
@@ -336,7 +336,7 @@
(quote-srcloc #,av-id)))))]
;; a list of variables, one for each super field
[(super-field ...) (generate-temporaries super-refs)]
- ;; the contract for a super field is any/c becuase the
+ ;; the contract for a super field is any/c because the
;; super constructor will have its own contract
[(super-contract ...) (for/list ([i (in-list super-refs)])
(datum->syntax stx 'any/c))]
diff --git a/collects/racket/private/class-internal.rkt b/collects/racket/private/class-internal.rkt
index 532bab8cd0..c616b55f27 100644
--- a/collects/racket/private/class-internal.rkt
+++ b/collects/racket/private/class-internal.rkt
@@ -421,7 +421,7 @@
(or class-name
"")))
#f))
- ;; -- tranform loop starts here --
+ ;; -- transform loop starts here --
(let loop ([stx orig-stx][can-expand? #t][name name][locals null])
(syntax-case stx (#%plain-lambda lambda λ case-lambda letrec-values let-values)
[(lam vars body1 body ...)
diff --git a/collects/racket/private/kw.rkt b/collects/racket/private/kw.rkt
index 3c85148ab9..125446365b 100644
--- a/collects/racket/private/kw.rkt
+++ b/collects/racket/private/kw.rkt
@@ -784,7 +784,7 @@
[(keyword? (cadr l))
(raise-syntax-error
'application
- "keyword in expression possition (immediately after another keyword)"
+ "keyword in expression position (immediately after another keyword)"
stx
(cadr l))]
[else
diff --git a/collects/racket/private/reqprov.rkt b/collects/racket/private/reqprov.rkt
index c664046cf5..99cc2f7abd 100644
--- a/collects/racket/private/reqprov.rkt
+++ b/collects/racket/private/reqprov.rkt
@@ -32,7 +32,7 @@
(define-for-syntax (xlate-path stx)
(if (pair? (syntax-e stx))
(let ([kw
- ;; symbolic-identifier=? identifers are not necessarily free-identifier=?
+ ;; symbolic-identifier=? identifiers are not necessarily free-identifier=?
(syntax-case stx (lib planet file quote)
[(quote . _) 'quote]
[(lib . _) 'lib]
diff --git a/collects/redex/private/matcher.rkt b/collects/redex/private/matcher.rkt
index 02bb91554a..5ad7d96ccd 100644
--- a/collects/redex/private/matcher.rkt
+++ b/collects/redex/private/matcher.rkt
@@ -1013,7 +1013,7 @@ before the pattern compiler is invoked.
; return the found element
(cdr entry)]
[else
- ;; didnt hit yet, continue searchign
+ ;; didn't hit yet, continue searching
(loop previous1 current (cdr current) (+ i 1))]))]))])])))))
;; hash version, but with a vector that tells when to evict cache entries
diff --git a/collects/scribblings/framework/editor.scrbl b/collects/scribblings/framework/editor.scrbl
index b683634f0a..2de107b3bb 100644
--- a/collects/scribblings/framework/editor.scrbl
+++ b/collects/scribblings/framework/editor.scrbl
@@ -379,7 +379,7 @@
@definterface[editor:backup-autosave<%> (editor:basic<%>)]{
Classes matching this interface support backup files and autosaving.
@defmethod*[(((backup?) boolean?))]{
- Indicates weather this
+ Indicates whether this
@scheme[editor<%>]
should be backed up.
@@ -392,7 +392,7 @@
}
@defmethod*[(((autosave?) boolean?))]{
- Indicates weather this
+ Indicates whether this
@scheme[editor<%>]
should be autosaved.
diff --git a/collects/scribblings/framework/text.scrbl b/collects/scribblings/framework/text.scrbl
index 09188b9b3c..5f11748b0d 100644
--- a/collects/scribblings/framework/text.scrbl
+++ b/collects/scribblings/framework/text.scrbl
@@ -135,7 +135,7 @@
}
@defmethod[(get-edition-number) exact-nonnegative-integer?]{
- Returns a number that increments everytime something in
+ Returns a number that increments every time something in
the editor changes.
The number is updated in @xmethod[text% after-insert] and
diff --git a/collects/scribblings/guide/performance.scrbl b/collects/scribblings/guide/performance.scrbl
index e1db549753..d85fa533fa 100644
--- a/collects/scribblings/guide/performance.scrbl
+++ b/collects/scribblings/guide/performance.scrbl
@@ -76,7 +76,7 @@ definition applies only to expressions evaluated later.
Within a module, inlining and constant-propagation optimizations take
additional advantage of the fact that definitions within a module
-cannot be mutated when no @racket[set!] is visable at compile
+cannot be mutated when no @racket[set!] is visible at compile
time. Such optimizations are unavailable in the top-level
environment. Although this optimization within modules is important
for performance, it hinders some forms of interactive development and
diff --git a/collects/scribblings/raco/exe-api.scrbl b/collects/scribblings/raco/exe-api.scrbl
index 25323d77cf..9f9c888fb2 100644
--- a/collects/scribblings/raco/exe-api.scrbl
+++ b/collects/scribblings/raco/exe-api.scrbl
@@ -23,7 +23,7 @@
The @racketmodname[compiler/embed] library provides a function to
embed Racket code into a copy of Racket or GRacket, thus creating a
stand-alone Racket executable. To package the executable into a
-distribution that is indpendent of your Racket installation, use
+distribution that is independent of your Racket installation, use
@racket[assemble-distribution] from
@racketmodname[compiler/distribute].}
diff --git a/collects/scribblings/raco/plt.scrbl b/collects/scribblings/raco/plt.scrbl
index cbc191e1ed..b69b1d7307 100644
--- a/collects/scribblings/raco/plt.scrbl
+++ b/collects/scribblings/raco/plt.scrbl
@@ -103,7 +103,7 @@ of each collection's @filepath{info.rkt} file (see @secref["info.rkt"]):
version sequence specified in the corresponding @racket[vers].
A collection's version is indicated by a @racket[version] field in
- it's @filepath{info.ss} file, and the default version is the empty list.
+ its @filepath{info.ss} file, and the default version is the empty list.
The version sequence generalized major and minor version numbers. For
example, version @racket['(2 5 4 7)] of a collection can be used when
any of @racket['()], @racket['(2)], @racket['(2 5)], @racket['(2 5
diff --git a/collects/scribblings/reference/memory.scrbl b/collects/scribblings/reference/memory.scrbl
index c6cc0d8333..9c4f60750a 100644
--- a/collects/scribblings/reference/memory.scrbl
+++ b/collects/scribblings/reference/memory.scrbl
@@ -184,7 +184,7 @@ this procedure is never called.}
Returns an estimate of the number of bytes of memory occupied by
reachable data from @racket[cust]. This estimate is calculated by the
-last garbage colection, and can be 0 if none occured (or if none occured
+last garbage colection, and can be 0 if none occurred (or if none occurred
since the given custodian was created). The @racket[current-memory-use]
function does @italic{not} perform a collection by itself; doing one
before the call will generally decrease the result (or increase it from
diff --git a/collects/scribblings/reference/reader.scrbl b/collects/scribblings/reference/reader.scrbl
index 87a132fba0..b488369ecf 100644
--- a/collects/scribblings/reference/reader.scrbl
+++ b/collects/scribblings/reference/reader.scrbl
@@ -71,7 +71,7 @@ characters play special roles:
terminating @litchar{|} is part of the subsequence.}
@item{@as-index{@litchar{\}} outside of a @litchar{|} pair causes
- the folowing character to be included verbatim in a delimited
+ the following character to be included verbatim in a delimited
sequence.}
]
@@ -232,7 +232,7 @@ IEEE floating point is supported (see @secref["numbers"]), the marks
with any other mark, double-precision IEEE floating point is used.
In addition, single- and double-precision specials are distinct;
specials with the @litchar{.0} suffix, like @racket[-nan.0] are
-double-precision, wheras specials with the @litchar{.f} suffix are
+double-precision, whereas specials with the @litchar{.f} suffix are
single-precision.
@BNF[(list @nunterm{number} @BNF-alt[@nunterm{exact}
diff --git a/collects/scribblings/scribble/srcdoc.scrbl b/collects/scribblings/scribble/srcdoc.scrbl
index a5048c36fc..5968c39d0c 100644
--- a/collects/scribblings/scribble/srcdoc.scrbl
+++ b/collects/scribblings/scribble/srcdoc.scrbl
@@ -9,7 +9,7 @@
The @racketmodname[scribble/srcdoc] and
@racketmodname[scribble/extract] libraries support writing
-documentation withing the documentation code along with an export
+documentation within the documentation code along with an export
contract, similar to using @as-index{JavaDoc}. With this approach, a
single contract specification is used both for the run-time contract
and the documentation of an exported binding.
diff --git a/collects/setup/main.rkt b/collects/setup/main.rkt
index f4cceee2f0..d3012cee9c 100644
--- a/collects/setup/main.rkt
+++ b/collects/setup/main.rkt
@@ -25,7 +25,7 @@
(define-values (short-name long-names raco?)
;; Load the name module without using .zos, and in its own namespace to
- ;; avoid poluting the cm-managed namespace later
+ ;; avoid polluting the cm-managed namespace later
(parameterize ([use-compiled-file-paths null]
[current-namespace (make-kernel-namespace)])
((dynamic-require 'setup/private/command-name 'get-names))))
diff --git a/collects/srfi/27/random-bits.rkt b/collects/srfi/27/random-bits.rkt
index a627646386..a723a729b0 100644
--- a/collects/srfi/27/random-bits.rkt
+++ b/collects/srfi/27/random-bits.rkt
@@ -235,7 +235,7 @@
; [[y00 y01 y02],
; [y10 y11 y12],
; [y20 y21 y22]] mod m2]
-; as a vector of length 18 of the integers as writen above:
+; as a vector of length 18 of the integers as written above:
; #(x00 x01 x02 x10 x11 x12 x20 x21 x22
; y00 y01 y02 y10 y11 y12 y20 y21 y22)
;
diff --git a/collects/srfi/32/sort.txt b/collects/srfi/32/sort.txt
index fc932dfa73..825bdb355b 100644
--- a/collects/srfi/32/sort.txt
+++ b/collects/srfi/32/sort.txt
@@ -629,7 +629,7 @@ i.e., what they do to the data (sort, stable sort, merge, and so forth).
** Algorithm-specific sorting packages
======================================
These packages provide more specific sorting functionality, that is,
-specific committment to particular algorithms that have particular
+specific commitment to particular algorithms that have particular
pragmatic consequences (such as memory locality, asymptotic running time)
beyond their semantic behaviour (sorting, stable sorting, merging, etc.).
Programmers that need a particular algorithm can use one of these packages.
diff --git a/collects/srfi/42/generators.scm b/collects/srfi/42/generators.scm
index c82dccb392..c101454a22 100644
--- a/collects/srfi/42/generators.scm
+++ b/collects/srfi/42/generators.scm
@@ -435,7 +435,7 @@
[((ob ...) (oc ...) (lb ...) ne1 (((ib-var ...) ib-rhs) ...) (ic ...) ne2 (ls ...))
(with-syntax ([(ib-tmp ...) (generate-temporaries #'(ib-var ... ...))]
[(false ...) (map (lambda (x) #'f) (syntax->list #'(ib-var ... ...)))])
- ; this trickery is neccessary to make ib-vars visible in test
+ ; this trickery is necessary to make ib-vars visible in test
(make-loop #'((ob ... ((ib-tmp) #f) ...)
(oc ...)
(lb ...)
diff --git a/collects/srfi/43/vector-lib.rkt b/collects/srfi/43/vector-lib.rkt
index 35c7887a61..7be4dec163 100644
--- a/collects/srfi/43/vector-lib.rkt
+++ b/collects/srfi/43/vector-lib.rkt
@@ -229,7 +229,7 @@
;;; Vectors A and B are equal iff their lengths are the same and for
;;; each respective elements E_a and E_b (element=? E_a E_b) returns
;;; a true value. ELT=? is always applied to two arguments. Element
- ;;; comparison must be consistent wtih EQ?; that is, if (eq? E_a E_b)
+ ;;; comparison must be consistent with EQ?; that is, if (eq? E_a E_b)
;;; results in a true value, then (ELEMENT=? E_a E_b) must result in a
;;; true value. This may be exploited to avoid multiple unnecessary
;;; element comparisons. (This implementation does, but does not deal
diff --git a/collects/stepper/private/annotate.rkt b/collects/stepper/private/annotate.rkt
index bb8b8bd1a1..9faadd9994 100644
--- a/collects/stepper/private/annotate.rkt
+++ b/collects/stepper/private/annotate.rkt
@@ -613,7 +613,7 @@
; e3))))
;
; note that this elaboration looks exactly like the one for letrec, and that's
- ; okay, becuase expand guarantees that reordering them will not cause capture.
+ ; okay, because expand guarantees that reordering them will not cause capture.
; this is because a bound variable answers is considered bound by a binding only when
; the pair answers true to bound-identifier=?, which is determined during (the first)
; expand.
diff --git a/collects/swindle/clos.rkt b/collects/swindle/clos.rkt
index 0704862e67..4d23210321 100644
--- a/collects/swindle/clos.rkt
+++ b/collects/swindle/clos.rkt
@@ -463,7 +463,7 @@
;;> Restrict this slot value to objects of the given `type'.
;;> * :lock { #t | #f | value }
;;> If specified and non-`#f', then this slot is locked. `#t' locks it
-;;> permanently, but a diffrent value works as a key: they allow setting
+;;> permanently, but a different value works as a key: they allow setting
;;> the slot by using cons of the key and the value to set.
;;> * :allocation { :class | :instance }
;;> Specify that this slot is a normal one (`:instance', the default),
diff --git a/collects/swindle/tiny-clos.rkt b/collects/swindle/tiny-clos.rkt
index 2ce99980b9..1cb7f9b4b3 100644
--- a/collects/swindle/tiny-clos.rkt
+++ b/collects/swindle/tiny-clos.rkt
@@ -835,7 +835,7 @@
;;; instance-proc of methods, which is activated when you apply the object (in
;;; the original, methods could not be applied). This is defined using this
;;; name and arguments because it is later used directly by the generic
-;;; function (cannot use the generic in the inital make since methods need to
+;;; function (cannot use the generic in the initial make since methods need to
;;; be created when the generics are constructed).
(define (method:compute-apply-method call-next-method method)
(let* ([specializers (%method-specializers method)]
diff --git a/collects/teachpack/2htdp/scribblings/image.scrbl b/collects/teachpack/2htdp/scribblings/image.scrbl
index 6d5682a70a..8f5faf98c6 100644
--- a/collects/teachpack/2htdp/scribblings/image.scrbl
+++ b/collects/teachpack/2htdp/scribblings/image.scrbl
@@ -1379,7 +1379,7 @@ Using @racket["pinhole"] or @racket['pinhole] is only allowed when all of the im
@section{Equality Testing of Images}
Two images are @racket[equal?] if they draw exactly the same way at their current size
-(not neccessarily at all sizes) and, if there are pinholes, the pinholes are
+(not necessarily at all sizes) and, if there are pinholes, the pinholes are
in the same place.
@section[#:tag "pinholes"]{Pinholes}
diff --git a/collects/tests/framework/README b/collects/tests/framework/README
index 81ad4ef746..a9dae2dd65 100644
--- a/collects/tests/framework/README
+++ b/collects/tests/framework/README
@@ -1,7 +1,7 @@
(#|
Framework Test Suite Overview
-Each test will rely on the sucessfully completion of all of the ones
+Each test will rely on the successfully completion of all of the ones
before it. In addition, all test suites rely on the sucessful
completion of the engine test suites and the mzscheme test suites.
@@ -29,7 +29,7 @@ signal failures when there aren't any.
- load: |# load.rkt #|
| This tests that the advertised ways of loading the framework at
- | it's components all work.
+ | its components all work.
- exit: |# exit.rkt #|
diff --git a/collects/tests/plai/gc/good-mutators/classic-error.rkt b/collects/tests/plai/gc/good-mutators/classic-error.rkt
index 468d697e4b..d1197725e7 100644
--- a/collects/tests/plai/gc/good-mutators/classic-error.rkt
+++ b/collects/tests/plai/gc/good-mutators/classic-error.rkt
@@ -4,7 +4,7 @@
'trash
'junk
-; after GC, alpha beta are copied but the cons refernces them in the old semispace
+; after GC, alpha beta are copied but the cons references them in the old semispace
(define my-pair (cons 'alpha 'beta))
; we have room for our-pair, but 'refuse forces a semi-space swap that exposes
; the memory corruption (if one exists)
diff --git a/collects/tests/r6rs/run/contrib.sps b/collects/tests/r6rs/run/contrib.sps
index bb4b257064..585d9de683 100644
--- a/collects/tests/r6rs/run/contrib.sps
+++ b/collects/tests/r6rs/run/contrib.sps
@@ -2,6 +2,6 @@
(import (tests r6rs contrib)
(tests r6rs test)
(rnrs io simple))
-(display "Running contibuted tests\n")
+(display "Running contributed tests\n")
(run-contrib-tests)
(report-test-results)
diff --git a/collects/tests/racket/contract-mzlib-test.rktl b/collects/tests/racket/contract-mzlib-test.rktl
index cfa98696cc..2de1e869c2 100644
--- a/collects/tests/racket/contract-mzlib-test.rktl
+++ b/collects/tests/racket/contract-mzlib-test.rktl
@@ -4618,7 +4618,7 @@ so that propagation occurs.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;
;; provide/contract tests
- ;; (at the end, becuase they are slow w/out .zo files)
+ ;; (at the end, because they are slow w/out .zo files)
;;
(test/spec-passed
diff --git a/collects/tests/racket/contract-test.rktl b/collects/tests/racket/contract-test.rktl
index cdf55e547f..d4dbef0ea0 100644
--- a/collects/tests/racket/contract-test.rktl
+++ b/collects/tests/racket/contract-test.rktl
@@ -10453,7 +10453,7 @@ so that propagation occurs.
;
;;
- ;; (at the end, becuase they are slow w/out .zo files)
+ ;; (at the end, because they are slow w/out .zo files)
;;
(test/spec-passed
diff --git a/collects/tests/racket/struct.rktl b/collects/tests/racket/struct.rktl
index 06ea1e0f48..fd65ec7a31 100644
--- a/collects/tests/racket/struct.rktl
+++ b/collects/tests/racket/struct.rktl
@@ -720,7 +720,7 @@
(test-values '(() (#:kw)) (lambda () (procedure-keywords (make-a 1 2)))))
;; ------------------------------------------------------------
-;; Check that struct definiton sequences work:
+;; Check that struct definition sequences work:
(let ()
(define-struct a (x y))
diff --git a/collects/tests/racket/uni-norm.rktl b/collects/tests/racket/uni-norm.rktl
index 643ad5b8f8..34ef000f1f 100644
--- a/collects/tests/racket/uni-norm.rktl
+++ b/collects/tests/racket/uni-norm.rktl
@@ -38,7 +38,7 @@
(with-input-from-file (get-test-file)
(lambda ()
(unless (regexp-match #rx"^# NormalizationTest-" (read-line))
- (error "Bad test-file contents (couldn't retreive tests?)"))
+ (error "Bad test-file contents (couldn't retrieve tests?)"))
(let loop ([a null])
(let ([l (read-line)])
(if (eof-object? l)
diff --git a/collects/tests/run-automated-tests.rkt b/collects/tests/run-automated-tests.rkt
index 6fb9427d53..0f5eb93ee9 100755
--- a/collects/tests/run-automated-tests.rkt
+++ b/collects/tests/run-automated-tests.rkt
@@ -5,7 +5,7 @@
;; - Each test is run in its own namespace, but there is very little
;; additional sandboxing. (There is a timeout of 10 minutes.)
;; - Specifically, the I/O ports are not diverted -- so please keep
-;; output to a minimum, preferrably nothing if there are no errors.
+;; output to a minimum, preferably nothing if there are no errors.
;; - Tests are only running in racket (*not* gracket), but note that
;; they will run with both the default 3m and the CGC executable, and
;; with the JIT enabled and disabled.
diff --git a/collects/tests/typed-scheme/optimizer/tests/unboxed-let-functions8.rkt b/collects/tests/typed-scheme/optimizer/tests/unboxed-let-functions8.rkt
index 84f71ce8e8..8943e2720a 100644
--- a/collects/tests/typed-scheme/optimizer/tests/unboxed-let-functions8.rkt
+++ b/collects/tests/typed-scheme/optimizer/tests/unboxed-let-functions8.rkt
@@ -13,5 +13,5 @@ unboxed-let-functions8.rkt line 15 col 64 - (#%app + x (quote 2.0+4.0i)) - unbox
(letrec: ((f : (Float-Complex -> Float-Complex) (lambda (x) (+ x 2.0+4.0i)))
- (g : (Float-Complex -> Float-Complex) f)) ; f escapes! can't unbox it's args
+ (g : (Float-Complex -> Float-Complex) f)) ; f escapes! can't unbox its args
(f 1.0+2.0i))
diff --git a/collects/tests/typed-scheme/succeed/hw01.scm b/collects/tests/typed-scheme/succeed/hw01.scm
index 9406bb7ee9..00885194fc 100644
--- a/collects/tests/typed-scheme/succeed/hw01.scm
+++ b/collects/tests/typed-scheme/succeed/hw01.scm
@@ -89,7 +89,7 @@
;; 5
;; list-length: (list-of any) -> integer
-;; Computes the lenght of a list
+;; Computes the length of a list
(define: (list-length [loa : (Listof top)]) : number
(if (null? loa)
0
diff --git a/collects/tests/typed-scheme/succeed/random-bits.rkt b/collects/tests/typed-scheme/succeed/random-bits.rkt
index 7ec73d531d..71f8daac92 100644
--- a/collects/tests/typed-scheme/succeed/random-bits.rkt
+++ b/collects/tests/typed-scheme/succeed/random-bits.rkt
@@ -319,7 +319,7 @@
; [[y00 y01 y02],
; [y10 y11 y12],
; [y20 y21 y22]] mod m2]
-; as a vector of length 18 of the integers as writen above:
+; as a vector of length 18 of the integers as written above:
; #(x00 x01 x02 x10 x11 x12 x20 x21 x22
; y00 y01 y02 y10 y11 y12 y20 y21 y22)
;
diff --git a/collects/texpict/doc.txt b/collects/texpict/doc.txt
index 8d90e46fcf..d88b0b11a9 100644
--- a/collects/texpict/doc.txt
+++ b/collects/texpict/doc.txt
@@ -108,7 +108,7 @@ LaTeX output
The LaTeX texpict function set is loaded by the _texpict_ library.
The library is available in unit form via _texpict-unit.ss_, which
-provides a `texpict@' unit with no imports and taht exports
+provides a `texpict@' unit with no imports and that exports
`texpict-common^' and `texpict-extra^'. The _texpict-sig.ss_ library
provides both signatures.
diff --git a/collects/typed-scheme/env/global-env.rkt b/collects/typed-scheme/env/global-env.rkt
index b22f47c294..586a3ab3f4 100644
--- a/collects/typed-scheme/env/global-env.rkt
+++ b/collects/typed-scheme/env/global-env.rkt
@@ -67,7 +67,7 @@
(define (finish-register-type id)
(unless (maybe-finish-register-type id)
- (tc-error/expr #:stx id "Duplicate defintion for ~a" (syntax-e id)))
+ (tc-error/expr #:stx id "Duplicate definition for ~a" (syntax-e id)))
(void))
(define (check-all-registered-types)
diff --git a/collects/typed-scheme/optimizer/unboxed-let.rkt b/collects/typed-scheme/optimizer/unboxed-let.rkt
index 57e4f111b2..a3f7fa6d49 100644
--- a/collects/typed-scheme/optimizer/unboxed-let.rkt
+++ b/collects/typed-scheme/optimizer/unboxed-let.rkt
@@ -75,7 +75,7 @@
(not (null? (syntax-e (car p))))
(let ((fun-name (car (syntax-e (car p)))))
(and
- ;; if the function escapes, we can't change it's interface
+ ;; if the function escapes, we can't change its interface
(not (is-var-mutated? fun-name))
(not (escapes? fun-name #'(begin rhs ... ...) #f))
(not (escapes? fun-name #'(begin body ...) let-loop?))
diff --git a/collects/typed-scheme/typecheck/tc-app.rkt b/collects/typed-scheme/typecheck/tc-app.rkt
index 15df18a18e..f96c228283 100644
--- a/collects/typed-scheme/typecheck/tc-app.rkt
+++ b/collects/typed-scheme/typecheck/tc-app.rkt
@@ -399,7 +399,7 @@
(cond [(not ival)
(tc-error/expr #:stx #'e
#:return (or expected (ret -Void))
- "expected statically known index for heterogenous vector, but got ~a" (match e-t [(tc-result1: t) t]))]
+ "expected statically known index for heterogeneous vector, but got ~a" (match e-t [(tc-result1: t) t]))]
[(and (integer? ival) (exact? ival) (<= 0 ival (sub1 (length es))))
(tc-expr/check #'val (ret (list-ref es ival)))
(if expected
diff --git a/collects/web-server/default-web-root/htdocs/servlets/examples/quiz.rkt b/collects/web-server/default-web-root/htdocs/servlets/examples/quiz.rkt
index 743937d9db..eab610009e 100644
--- a/collects/web-server/default-web-root/htdocs/servlets/examples/quiz.rkt
+++ b/collects/web-server/default-web-root/htdocs/servlets/examples/quiz.rkt
@@ -174,7 +174,7 @@
(extract-binding/single key bindings)))
;; run-quiz: -> void
-;; run quizes until the student gets tired
+;; run quizzes until the student gets tired
(define (run-quiz)
(let ([*questions-per-quiz*
(if (> *questions-per-quiz* (length all-questions))
diff --git a/doc/release-notes/drracket/HISTORY.txt b/doc/release-notes/drracket/HISTORY.txt
index 701c34ce1a..bb58f8d18f 100644
--- a/doc/release-notes/drracket/HISTORY.txt
+++ b/doc/release-notes/drracket/HISTORY.txt
@@ -609,7 +609,7 @@
language.
- Help Desk's status messages are now in the frame and
- it's break button is also in the frame (no more modal
+ its break button is also in the frame (no more modal
dialog)
- Check Syntax now does a better job of navigating amoung
@@ -956,7 +956,7 @@ General
-------
- typing characters in to the definitions and interactions window
- should be more responsive now (it was noticably slow on slower
+ should be more responsive now (it was noticeably slow on slower
machines)
- files added to projects are now stored as relative files,
@@ -1156,7 +1156,7 @@ Tools and Framework
- framework:
- added canonicalize-keybinding-string
- added aug-keymap%, aug-keymap<%>
- - editor:basic now sets it's keymap to an
+ - editor:basic now sets its keymap to an
aug-keymap<%> during initialization.
- the framework's info frame mixins no longer require frame:editor<%>
@@ -1168,7 +1168,7 @@ Tools and Framework
- ensure-interactions-shown is now ensure-rep-shown
- do-many-buffer-evals is now do-many-text-evals
- - clever-file-format now symetrically changes the file's format to
+ - clever-file-format now symmetrically changes the file's format to
'standard. It used to rever the file format to 'text when there
were no more images in it. Now, it also changes back to non-'text
when images (and other non-string-snips) are added back.
diff --git a/doc/release-notes/gracket/HISTORY.txt b/doc/release-notes/gracket/HISTORY.txt
index 8085ccf1fe..2bffa4057a 100644
--- a/doc/release-notes/gracket/HISTORY.txt
+++ b/doc/release-notes/gracket/HISTORY.txt
@@ -373,7 +373,7 @@ Version 206p1, February 2004
Fixed printing scale for Windows NT/2000/XP
-Version 206, Janurary 2004
+Version 206, January 2004
Drawing:
Changed get-argb-pixels and set-argb-pixels to row-major order:
diff --git a/doc/release-notes/gracket/MrEd_100_Framework.txt b/doc/release-notes/gracket/MrEd_100_Framework.txt
index 2c062d7c13..e3d26796c4 100644
--- a/doc/release-notes/gracket/MrEd_100_Framework.txt
+++ b/doc/release-notes/gracket/MrEd_100_Framework.txt
@@ -115,7 +115,7 @@ The moved functions and classes are:
mred:graph-pasteboard%
mred:node-snip%
-The remaining existant classes:
+The remaining existent classes:
frame:empty% = (frame:make-empty% frame%)
frame:standard-menus% = (frame:make-standard-menus% frame:empty%)
@@ -294,4 +294,4 @@ NOTE: some used but non-existant interfaces from mred engine:
snip:make-basic-style% : snip<%> -> snip<%>
- scheme:make-text% : text:basic<%> -> scheme:text<%>
\ No newline at end of file
+ scheme:make-text% : text:basic<%> -> scheme:text<%>
diff --git a/doc/release-notes/racket/HISTORY.txt b/doc/release-notes/racket/HISTORY.txt
index 05ecb5f2e2..86f261a02d 100644
--- a/doc/release-notes/racket/HISTORY.txt
+++ b/doc/release-notes/racket/HISTORY.txt
@@ -1460,7 +1460,7 @@ stdout/stderr are not auto-flushed for read-char or peek-char on stdin
Added port-display-handler and port-write-handler
Version 45, November 12, 1996
-Multiple return values are agressively supported
+Multiple return values are aggressively supported
IMPORTANT: let-values is now analogous to let; the old
let-values is now let*-values
let-values, letrec-values, define-values, and begin0 are primitive
@@ -1626,7 +1626,7 @@ Version 0.33: December 21, 1995
rationals and complex numbers supported
make-class and make-class* syntax changed (one set of parens
added). The old syntax is still supported for now, but you
- should convert. The old syntax will eventualy go away (and
+ should convert. The old syntax will eventually go away (and
Zodiac will never be compatible with it).
class variables and cvar no longer allowed
ivar always takes an object; if class included, must be first
diff --git a/doc/srfi-std/srfi-1.html b/doc/srfi-std/srfi-1.html
index df91deb529..773c03b624 100644
--- a/doc/srfi-std/srfi-1.html
+++ b/doc/srfi-std/srfi-1.html
@@ -2366,7 +2366,7 @@ that satisfies the predicate.
In other words:
-span
finds the intial span of elements
+span
finds the initial span of elements
satisfying pred,
and break
breaks the list at the first element satisfying
pred.
diff --git a/doc/srfi-std/srfi-17.html b/doc/srfi-std/srfi-17.html
index 0bc010c751..dc06d9d8d6 100644
--- a/doc/srfi-std/srfi-17.html
+++ b/doc/srfi-std/srfi-17.html
@@ -77,7 +77,7 @@ mutable variables are first-class "cells", and accessing the
contents of a cell requires an explicit operator. This is also not
compatible with Scheme. Instead we need to stick to the model
where using a variable in most contexts means using its value,
-but refering to a variable in certain lvalue contexts (lhs of
+but referring to a variable in certain lvalue contexts (lhs of
assignment) refers to its actual location. Sticking to this model
for general "lvalue expressions" in set!
means
that "evaluation" must be done differently from normal
diff --git a/doc/srfi-std/srfi-19.html b/doc/srfi-std/srfi-19.html
index e48dc26021..3d9a4df1a0 100644
--- a/doc/srfi-std/srfi-19.html
+++ b/doc/srfi-std/srfi-19.html
@@ -455,7 +455,7 @@ specification of locales is beyond this SRFI.
date->string
date [format-string] -> string
- Converts a date to a string, using the format string. The format string is copied as is; except
-escape characters (indicated by the tilde) are replaced with specfic conversions. Table 1 lists the required conversion specifiers;
+escape characters (indicated by the tilde) are replaced with specific conversions. Table 1 lists the required conversion specifiers;
implementations are free to extend this list.
string->date
input-string template-string -> date
- Converts an input string to a date, using the template string. The input string must match the template
diff --git a/doc/srfi-std/srfi-23.html b/doc/srfi-std/srfi-23.html
index 174eda493c..8ac31ca2af 100644
--- a/doc/srfi-std/srfi-23.html
+++ b/doc/srfi-std/srfi-23.html
@@ -49,7 +49,7 @@ implementations to signal an error in many more circumstances.
However, there is no direct way for the Scheme application programmer to report
-an error that occured in his or her own application.
+an error that occurred in his or her own application.
This means that Scheme procedures created by applications or libraries are
in this respect not on equal footing with procedures provided by the
Scheme system.
@@ -112,7 +112,7 @@ are given.
An implementation might report more information than just
<reason> and <arg1>... . For instance, it might report the procedure name in which
-the error occured or even print a stack trace.
+the error occurred or even print a stack trace.
However, this will require additional support in the Scheme implementation.
diff --git a/doc/srfi-std/srfi-27.html b/doc/srfi-std/srfi-27.html
index 480f5e1326..14a88ff7d9 100644
--- a/doc/srfi-std/srfi-27.html
+++ b/doc/srfi-std/srfi-27.html
@@ -63,7 +63,7 @@ is essential, in the sense that it is difficult for an adversary to
exploit or introduce imperfections into the distribution of random bits.
Moreover, the linear complexity of the stream of random bits is more
important than its statistical properties.
-In these applications, an entropy source (producing truely random
+In these applications, an entropy source (producing truly random
bits at a low rate) is used to randomize a pseudo random number
generator to increase the rate of available bits.
@@ -417,7 +417,7 @@ Pierre L'Ecuyer's
generator which is combination of two recursive generators
of degree three, both of which fit into 54-bit arithmetics.
The MRG32k3a generator also passes DIEHARD and in addition,
-has desireable spectral properties and a period in the
+has desirable spectral properties and a period in the
order of 2^191.
As a matter of fact, multiple recursive generators (MRGs) are
theoretically much better understood than special constructions
diff --git a/doc/srfi-std/srfi-4.html b/doc/srfi-std/srfi-4.html
index 5dab25b2ff..f48174fd17 100644
--- a/doc/srfi-std/srfi-4.html
+++ b/doc/srfi-std/srfi-4.html
@@ -232,7 +232,7 @@ implementation as a sequence of 8, 16, 32 or 64 bit elements, using
two's complement representation for the signed exact integers, and
single and double precision IEEE-754 floating point representation for
the inexact reals. Although this is a practical implementation on
-many modern byte adressed machines, a different implementation is
+many modern byte addressed machines, a different implementation is
possible for machines which don't support these concrete numeric types
(the CRAY-T90 for example does not have a 32 bit floating point
representation and the 64 bit floating point representation does not
diff --git a/doc/srfi-std/srfi-43.html b/doc/srfi-std/srfi-43.html
index 55e02c1876..7ca1cd3536 100644
--- a/doc/srfi-std/srfi-43.html
+++ b/doc/srfi-std/srfi-43.html
@@ -178,7 +178,7 @@ You can access the discussion via vector-append,
vector-map, et cetera), but
often these procedures have different names, take arguments in
diff --git a/doc/srfi-std/srfi-48.html b/doc/srfi-std/srfi-48.html
index 0989497790..e73f4aadc1 100644
--- a/doc/srfi-std/srfi-48.html
+++ b/doc/srfi-std/srfi-48.html
@@ -51,7 +51,7 @@ In particular, the reference implementation given here does not accept numeric a
(aside from ~F).
Hence it does not support SRFI-29.
-It is highly desireable that baseline library code be small, attempt to
+It is highly desirable that baseline library code be small, attempt to
eliminiate heap allocation and bound stack usage.
This is especially important in embedded systems.
This can be accomplished by writing directly to a port,
@@ -188,7 +188,7 @@ implementation of Scheme and CommonLisp is maintained.
~K |
Indirection |
- the same as ~? for backward compatability with some existing implementations |
+ the same as ~? for backward compatibility with some existing implementations |
yes |
diff --git a/doc/srfi-std/srfi-59.html b/doc/srfi-std/srfi-59.html
index d278922edd..84b0680ff5 100644
--- a/doc/srfi-std/srfi-59.html
+++ b/doc/srfi-std/srfi-59.html
@@ -221,7 +221,7 @@ and
;;@ (implementation-vicinity) should be defined to be the pathname of
-;;; the directory where any auxillary files to your Scheme
+;;; the directory where any auxiliary files to your Scheme
;;; implementation reside.
(define (implementation-vicinity)
(case (software-type)
diff --git a/doc/srfi-std/srfi-60.html b/doc/srfi-std/srfi-60.html
index f7516c397d..09e098ac0e 100644
--- a/doc/srfi-std/srfi-60.html
+++ b/doc/srfi-std/srfi-60.html
@@ -52,7 +52,7 @@ important domain of computer science. It is used for:
- Fast-Fourier transforms;
-
- packing and unpacking numbers in persistant data structures;
+
- packing and unpacking numbers in persistent data structures;
- space-filling curves with applications to dimension reduction and
sparse multi-dimensional database indexes; and
@@ -349,7 +349,7 @@ Example:
- Function: integer-length n
-
-Returns the number of bits neccessary to represent n.
+Returns the number of bits necessary to represent n.
diff --git a/doc/srfi-std/srfi-67/srfi-67.html b/doc/srfi-std/srfi-67/srfi-67.html
index f8fd0cb482..a41875d7a2 100644
--- a/doc/srfi-std/srfi-67/srfi-67.html
+++ b/doc/srfi-std/srfi-67/srfi-67.html
@@ -1393,7 +1393,7 @@ Also, we believe it to be more useful to applications if
default-compare is based on type and structure.
Unfortunately, this imposes limits on what can be compared
-using default-compare because it is very desireable to
+using default-compare because it is very desirable to
have a portable reference implementation.
In particular, portable ways of dealing with circular structures
are overly costly.
diff --git a/doc/srfi-std/srfi-69.html b/doc/srfi-std/srfi-69.html
index 91ad15374c..6e4c3bbf96 100644
--- a/doc/srfi-std/srfi-69.html
+++ b/doc/srfi-std/srfi-69.html
@@ -350,7 +350,7 @@ destructively.
Hashing means the act of taking some value and producing a number from
the value. A hash function is a function that does this. Every
equivalence predicate e has a set of acceptable hash functions for
-that predicate; a hash funtion hash is acceptable iff (e obj1
+that predicate; a hash function hash is acceptable iff (e obj1
obj2) → (= (hash obj1) (hash obj2)).
A hash function h is good for a equivalence predicate e if it
diff --git a/doc/srfi-std/srfi-78.html b/doc/srfi-std/srfi-78.html
index 8edbb93f08..4267157268 100644
--- a/doc/srfi-std/srfi-78.html
+++ b/doc/srfi-std/srfi-78.html
@@ -137,7 +137,7 @@ Design considerations for this SRFI include the following:
switch off the execution of checks. It has turned out useful
to be able to run only some subset checks for the features
currently under development. This can be done by changing
- the reporting mode between differnt sections.
+ the reporting mode between different sections.
- The global state (correct/failed count) is not made available
to the user program. This reduces the dependencies between
different checks because it is not possible to use the state.
@@ -309,4 +309,4 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
Author: srfi-78@sebastian-egner.net
Editors: srfi-editors@srfi.schemers.org