Merge branch 'master' of git.racket-lang.org:plt
This commit is contained in:
commit
10377c35f2
|
@ -9,32 +9,42 @@
|
|||
(printf "a positive number")
|
||||
rate0)
|
||||
|
||||
;; String String Syntax[id] -> Syntax
|
||||
(define (pre-post-name pre post name)
|
||||
;; Syntax String String Syntax[id] -> Syntax
|
||||
(define (pre-post-name stx pre post name)
|
||||
(datum->syntax
|
||||
name (string->symbol (string-append pre (symbol->string (syntax-e name)) post))))
|
||||
|
||||
(provide (all-defined-out)))
|
||||
|
||||
(module clauses scheme
|
||||
(provide (all-defined-out))
|
||||
|
||||
(require syntax/parse (for-syntax scheme 'auxs unstable/syntax)
|
||||
(define-syntax-rule
|
||||
(define-kwd name)
|
||||
(begin
|
||||
(provide name)
|
||||
(define-syntax (name . x)
|
||||
(raise-syntax-error 'name "used out of context" x))))
|
||||
|
||||
(define-kwd on-tick)
|
||||
|
||||
(define-kwd on-mouse))
|
||||
|
||||
(module clauses scheme
|
||||
|
||||
(require syntax/parse 'auxs
|
||||
(for-syntax scheme 'auxs unstable/syntax)
|
||||
(for-template scheme/base 'auxs))
|
||||
|
||||
(provide define-clause)
|
||||
|
||||
(define-syntax (define-clause stx)
|
||||
(syntax-case stx ()
|
||||
[(_ name (proc p-ctc) (rate r-ctc) ...)
|
||||
(with-syntax ([name-clause (pre-post-name "" "-clause" #'name)]
|
||||
(with-syntax ([name-clause (pre-post-name stx "" "-clause" #'name)]
|
||||
[(rate0 ...) (generate-temporaries #'(rate ...))])
|
||||
(with-syntax ([((thing ...) ...) #'((#:with rate #'(r-ctc rate0)) ...)])
|
||||
#`
|
||||
(begin
|
||||
(provide name name-clause)
|
||||
|
||||
(define-syntax (name . x)
|
||||
(raise-syntax-error 'name "used out of context" x))
|
||||
|
||||
(define-syntax-class name-clause
|
||||
#:description (format "~a" 'name)
|
||||
#:literals (name)
|
||||
|
@ -43,75 +53,33 @@
|
|||
#:with (rate0 ...) (map (lambda (x) #'0) '(rate0 ...))
|
||||
#:with proc #'(world->world proc0)
|
||||
thing ... ...)
|
||||
(pattern (on-tick proc0:expr (~var rate0 expr) ...)
|
||||
(pattern (name proc0:expr (~var rate0 expr) ...)
|
||||
#:with proc #'(world->world> proc0)
|
||||
thing ... ...))
|
||||
)))]))
|
||||
|
||||
(define-clause on-mouse (proc world-nat-nat-mouse->world))
|
||||
(define-clause on-tick (proc world->world) (rate (lambda (x) 1/28)))
|
||||
|
||||
;; --- on-tick ---
|
||||
#|
|
||||
(define-syntax (on-tick . x)
|
||||
(raise-syntax-error 'on-tick "used out of context" x))
|
||||
|
||||
(define-syntax-class on-tick-clause
|
||||
#:description "on tick"
|
||||
#:literals (on-tick)
|
||||
#:attributes (proc rate)
|
||||
(pattern (on-tick proc0:expr)
|
||||
#:with proc #'(world->world proc0)
|
||||
#:with rate #'1/28)
|
||||
(pattern (on-tick proc0:expr rate0:expr)
|
||||
#:with proc #'(world->world> proc0)
|
||||
#:with rate #'(positive-number> rate0)))
|
||||
|
||||
(provide on-tick on-tick-clause)
|
||||
|#
|
||||
;; --- on-draw ---
|
||||
(define-syntax (on-draw . x)
|
||||
(raise-syntax-error 'on-draw "used out of context" x))
|
||||
|
||||
(define-syntax-class on-draw-clause
|
||||
#:description "on draw"
|
||||
#:literals (on-draw)
|
||||
#:attributes (proc width height)
|
||||
(pattern (on-draw proc0:expr)
|
||||
#:with proc #'(wrap worldxkey->world proc0)
|
||||
#:with width #'#f
|
||||
#:with height #'#f)
|
||||
(pattern (on-draw proc0:expr width0:expr height0:expr)
|
||||
#:with proc #'(worldxkey->world> proc0)
|
||||
#:with width #'(natural-number> width0)
|
||||
#:with height #'(natural-number> height0)))
|
||||
|
||||
(provide on-draw on-draw-clause))
|
||||
(define-clause on-tick (proc world->world))
|
||||
)
|
||||
|
||||
(module utest scheme
|
||||
(require (for-syntax syntax/parse 'clauses))
|
||||
(require 'clauses (for-syntax 'clauses syntax/parse) (for-template 'clauses))
|
||||
|
||||
(define-syntax (big-bang stx)
|
||||
(syntax-parse stx
|
||||
[(big-bang world0:expr
|
||||
(~or (~optional otc:on-tick-clause)
|
||||
; (~optional omc:on-mouse-clause)
|
||||
(~optional odc:on-draw-clause))
|
||||
(~or (~optional otk:on-tick-clause)
|
||||
(~optional omc:on-mouse-clause))
|
||||
...)
|
||||
#`(printf "~s\n"
|
||||
'(bb world0
|
||||
#,(if (attribute otc)
|
||||
#'otc.rate
|
||||
#'1/28)
|
||||
#,(if (attribute odc)
|
||||
#'odc.proc
|
||||
#''not-draw)))]))
|
||||
#,(if (attribute omc) "mouse" "no mouse")
|
||||
#,(if (attribute otk) "tick" "no tick")))]))
|
||||
|
||||
(big-bang 0)
|
||||
(big-bang 1 (on-tick add1))
|
||||
(big-bang 2 (on-tick add1 1/2))
|
||||
(big-bang 3 (on-draw add1 1/2 1/3))
|
||||
; (big-bang 4 (on-mouse add1 1 2))
|
||||
(big-bang 0)
|
||||
(big-bang 1 (on-tick +) (on-mouse -))
|
||||
(big-bang 2 (on-tick +))
|
||||
(big-bang 3 (on-mouse +))
|
||||
)
|
||||
|
||||
(require 'utest)
|
|
@ -30,7 +30,7 @@
|
|||
[("--vv") "Very verbose mode"
|
||||
(verbose #t)
|
||||
(very-verbose #t)]
|
||||
#:args file file))
|
||||
#:args (file . another-file) (cons file another-file)))
|
||||
|
||||
(if (disable-deps)
|
||||
;; Just compile one file:
|
||||
|
|
|
@ -92,7 +92,7 @@
|
|||
|
||||
(define (decompile-module mod-form stack)
|
||||
(match mod-form
|
||||
[(struct mod (name self-modidx prefix provides requires body syntax-body unexported
|
||||
[(struct mod (name srcname self-modidx prefix provides requires body syntax-body unexported
|
||||
max-let-depth dummy lang-info internal-context))
|
||||
(let-values ([(globs defns) (decompile-prefix prefix)]
|
||||
[(stack) (append '(#%modvars) stack)]
|
||||
|
|
|
@ -90,9 +90,10 @@
|
|||
|
||||
(define (traverse-module mod-form visit)
|
||||
(match mod-form
|
||||
[(struct mod (name self-modidx prefix provides requires body syntax-body unexported
|
||||
[(struct mod (name srcname self-modidx prefix provides requires body syntax-body unexported
|
||||
max-let-depth dummy lang-info internal-context))
|
||||
(traverse-data name visit)
|
||||
(traverse-data srcname visit)
|
||||
(traverse-data self-modidx visit)
|
||||
(traverse-prefix prefix visit)
|
||||
(for-each (lambda (f) (map (lambda (v) (traverse-data v visit)) (cdr f))) requires)
|
||||
|
@ -431,7 +432,7 @@
|
|||
|
||||
(define (out-module mod-form out)
|
||||
(match mod-form
|
||||
[(struct mod (name self-modidx prefix provides requires body syntax-body unexported
|
||||
[(struct mod (name srcname self-modidx prefix provides requires body syntax-body unexported
|
||||
max-let-depth dummy lang-info internal-context))
|
||||
(out-syntax MODULE_EXPD
|
||||
(let* ([lookup-req (lambda (phase)
|
||||
|
@ -504,6 +505,7 @@
|
|||
[l (list* #f #f l)] ; obsolete `functional?' info
|
||||
[l (cons lang-info l)] ; lang-info
|
||||
[l (cons self-modidx l)]
|
||||
[l (cons srcname l)]
|
||||
[l (cons name l)])
|
||||
(make-module-decl l))
|
||||
out)]))
|
||||
|
|
|
@ -205,7 +205,7 @@
|
|||
|
||||
(define (read-module v)
|
||||
(match v
|
||||
[`(,name ,self-modidx ,lang-info ,functional? ,et-functional?
|
||||
[`(,name ,srcname ,self-modidx ,lang-info ,functional? ,et-functional?
|
||||
,rename ,max-let-depth ,dummy
|
||||
,prefix
|
||||
,indirect-et-provides ,num-indirect-et-provides
|
||||
|
@ -218,7 +218,7 @@
|
|||
[`(,syntax-body ,body
|
||||
,requires ,syntax-requires ,template-requires ,label-requires
|
||||
,more-requires-count . ,more-requires)
|
||||
(make-mod name self-modidx
|
||||
(make-mod name srcname self-modidx
|
||||
prefix (let loop ([l phase-data])
|
||||
(if (null? l)
|
||||
null
|
||||
|
|
|
@ -90,6 +90,7 @@
|
|||
[max-let-depth exact-nonnegative-integer?]))
|
||||
|
||||
(define-form-struct (mod form) ([name symbol?]
|
||||
[srcname symbol?]
|
||||
[self-modidx module-path-index?]
|
||||
[prefix prefix?]
|
||||
[provides (listof (list/c (or/c exact-integer? #f)
|
||||
|
|
2
collects/drracket/drracket.creator
Normal file
2
collects/drracket/drracket.creator
Normal file
|
@ -0,0 +1,2 @@
|
|||
DrSc
|
||||
(This code is registered with Apple.)
|
67
collects/drracket/drracket.rkt
Normal file
67
collects/drracket/drracket.rkt
Normal file
|
@ -0,0 +1,67 @@
|
|||
#lang racket/base
|
||||
(require scheme/gui/base "private/key.rkt")
|
||||
|
||||
(define debugging? (getenv "PLTDRDEBUG"))
|
||||
(define profiling? (getenv "PLTDRPROFILE"))
|
||||
|
||||
(define install-cm? (and (not debugging?)
|
||||
(getenv "PLTDRCM")))
|
||||
|
||||
(define cm-trace? (or (equal? (getenv "PLTDRCM") "trace")
|
||||
(equal? (getenv "PLTDRDEBUG") "trace")))
|
||||
|
||||
|
||||
;; the flush is only here to ensure that the output is
|
||||
;; appears when running in cygwin under windows.
|
||||
(define (flprintf fmt . args)
|
||||
(apply printf fmt args)
|
||||
(flush-output))
|
||||
|
||||
(when debugging?
|
||||
(flprintf "PLTDRDEBUG: installing CM to load/create errortrace zos\n")
|
||||
(let-values ([(zo-compile
|
||||
make-compilation-manager-load/use-compiled-handler
|
||||
manager-trace-handler)
|
||||
(parameterize ([current-namespace (make-base-empty-namespace)]
|
||||
[use-compiled-file-paths '()])
|
||||
(values
|
||||
(dynamic-require 'errortrace/zo-compile 'zo-compile)
|
||||
(dynamic-require 'compiler/cm 'make-compilation-manager-load/use-compiled-handler)
|
||||
(dynamic-require 'compiler/cm 'manager-trace-handler)))])
|
||||
(current-compile zo-compile)
|
||||
(use-compiled-file-paths (list (build-path "compiled" "errortrace")))
|
||||
(current-load/use-compiled (make-compilation-manager-load/use-compiled-handler))
|
||||
(error-display-handler (dynamic-require 'errortrace/errortrace-lib
|
||||
'errortrace-error-display-handler))
|
||||
(when cm-trace?
|
||||
(flprintf "PLTDRDEBUG: enabling CM tracing\n")
|
||||
(manager-trace-handler
|
||||
(λ (x) (display "1: ") (display x) (newline) (flush-output))))))
|
||||
|
||||
(when install-cm?
|
||||
(flprintf "PLTDRCM: installing compilation manager\n")
|
||||
(let-values ([(make-compilation-manager-load/use-compiled-handler
|
||||
manager-trace-handler)
|
||||
(parameterize ([current-namespace (make-base-empty-namespace)])
|
||||
(values
|
||||
(dynamic-require 'compiler/cm 'make-compilation-manager-load/use-compiled-handler)
|
||||
(dynamic-require 'compiler/cm 'manager-trace-handler)))])
|
||||
(current-load/use-compiled (make-compilation-manager-load/use-compiled-handler))
|
||||
(when cm-trace?
|
||||
(flprintf "PLTDRCM: enabling CM tracing\n")
|
||||
(manager-trace-handler
|
||||
(λ (x) (display "1: ") (display x) (newline) (flush-output))))))
|
||||
|
||||
(when profiling?
|
||||
(flprintf "PLTDRPROFILE: installing profiler\n")
|
||||
;; NOTE that this might not always work.
|
||||
;; it creates a new custodian and installs it, but the
|
||||
;; original eventspace was created on the original custodian
|
||||
;; and this code does not create a new eventspace.
|
||||
(let ([orig-cust (current-custodian)]
|
||||
[orig-eventspace (current-eventspace)]
|
||||
[new-cust (make-custodian)])
|
||||
(current-custodian new-cust)
|
||||
((dynamic-require 'drracket/private/profile-drs 'start-profile) orig-cust)))
|
||||
|
||||
(dynamic-require 'drracket/private/drracket-normal #f)
|
10
collects/drracket/info.rkt
Normal file
10
collects/drracket/info.rkt
Normal file
|
@ -0,0 +1,10 @@
|
|||
#lang setup/infotab
|
||||
|
||||
;(define tools '("sprof.rkt"))
|
||||
;(define tool-names '("Sampling Profiler"))
|
||||
|
||||
(define drracket-tools '("syncheck.rkt"))
|
||||
(define drracket-tool-names '("Check Syntax"))
|
||||
|
||||
(define gracket-launcher-names '("DrRacket"))
|
||||
(define gracket-launcher-libraries '("drracket.rkt"))
|
|
@ -14,8 +14,8 @@
|
|||
(define (install-variation variant)
|
||||
(parameterize ([current-launcher-variant variant])
|
||||
(make-mred-launcher
|
||||
(list "-ZmvqL" "drscheme.rkt" "drscheme")
|
||||
(list "-ZmvqL" "drracket.rkt" "drracket")
|
||||
(mred-program-launcher-path "DrScheme")
|
||||
(cons
|
||||
`(exe-name . "DrScheme")
|
||||
(build-aux-from-path (build-path (collection-path "drscheme") "drscheme"))))))
|
||||
`(exe-name . "DrRacket")
|
||||
(build-aux-from-path (build-path (collection-path "drracket") "drracket"))))))
|
2
collects/drracket/main.rkt
Normal file
2
collects/drracket/main.rkt
Normal file
|
@ -0,0 +1,2 @@
|
|||
#lang racket/base
|
||||
(require "drracket.rkt")
|
|
@ -100,8 +100,8 @@
|
|||
(cond
|
||||
[(or prince-kuhio-day? kamehameha-day?)
|
||||
(set-splash-progress-bar? #f)
|
||||
(let ([size ((dynamic-require 'drscheme/private/palaka 'palaka-pattern-size) 4)])
|
||||
(vector (dynamic-require 'drscheme/private/honu-logo 'draw-honu)
|
||||
(let ([size ((dynamic-require 'drracket/private/palaka 'palaka-pattern-size) 4)])
|
||||
(vector (dynamic-require 'drracket/private/honu-logo 'draw-honu)
|
||||
size
|
||||
size))]
|
||||
[texas-independence-day?
|
||||
|
@ -134,10 +134,10 @@
|
|||
(label "Break All Threads")
|
||||
(callback
|
||||
(λ (x y)
|
||||
((dynamic-require 'drscheme/private/key 'break-threads))))
|
||||
((dynamic-require 'drracket/private/key 'break-threads))))
|
||||
(parent f))])
|
||||
(send f show #t)))))
|
||||
|
||||
(dynamic-require 'drscheme/tool-lib #f)
|
||||
(dynamic-require 'drracket/tool-lib #f)
|
||||
(shutdown-splash)
|
||||
(close-splash)
|
|
@ -1437,9 +1437,22 @@
|
|||
(define/override (get-transformer-module) #f)
|
||||
|
||||
(define/override (default-settings)
|
||||
(make-simple-settings+assume #f 'write 'mixed-fraction-e #f #t 'debug #t))
|
||||
(make-simple-settings+assume #f 'trad-write 'mixed-fraction-e #f #t 'debug #t))
|
||||
|
||||
(super-new)))
|
||||
|
||||
(define (pretty-big-mixin %)
|
||||
(class %
|
||||
(define/override (default-settings)
|
||||
(let ([s (super default-settings)])
|
||||
(make-simple-settings+assume (drracket:language:simple-settings-case-sensitive s)
|
||||
'trad-write
|
||||
(drracket:language:simple-settings-fraction-style s)
|
||||
(drracket:language:simple-settings-show-sharing s)
|
||||
(drracket:language:simple-settings-insert-newlines s)
|
||||
(drracket:language:simple-settings-annotations s)
|
||||
(simple-settings+assume-no-redef? s))))
|
||||
(super-new)))
|
||||
|
||||
(define get-all-scheme-manual-keywords
|
||||
(let ([words #f])
|
||||
|
@ -1514,7 +1527,7 @@
|
|||
(list -200 3)
|
||||
#t
|
||||
(string-constant pretty-big-scheme-one-line-summary)
|
||||
(λ (%) (macro-stepper-mixin (assume-mixin (add-errortrace-key-mixin %))))))
|
||||
(λ (%) (pretty-big-mixin (macro-stepper-mixin (assume-mixin (add-errortrace-key-mixin %)))))))
|
||||
(add-language
|
||||
(make-simple '(lib "r5rs/lang.rkt")
|
||||
"plt:r5rs"
|
|
@ -85,7 +85,7 @@
|
|||
(define id (reconstitute #,ctc provide?))
|
||||
#,@(if (syntax-e #'provide?)
|
||||
(list
|
||||
#`(require/doc drscheme/private/recon)
|
||||
#`(require/doc drracket/private/recon)
|
||||
#`(provide/doc
|
||||
(thing-doc id
|
||||
contract?
|
|
@ -161,7 +161,7 @@
|
|||
(= (vector-length printable)
|
||||
(procedure-arity make-simple-settings))
|
||||
(boolean? (vector-ref printable 0))
|
||||
(memq (vector-ref printable 1) '(constructor quasiquote write))
|
||||
(memq (vector-ref printable 1) '(constructor quasiquote write trad-write print))
|
||||
(memq (vector-ref printable 2)
|
||||
'(mixed-fraction
|
||||
mixed-fraction-e
|
||||
|
@ -172,7 +172,7 @@
|
|||
(memq (vector-ref printable 5) '(none debug debug/profile test-coverage))
|
||||
(apply make-simple-settings (vector->list printable))))
|
||||
(define/public (default-settings)
|
||||
(make-simple-settings #t 'write 'mixed-fraction-e #f #t 'debug))
|
||||
(make-simple-settings #t 'print 'mixed-fraction-e #f #t 'debug))
|
||||
(define/public (default-settings? x)
|
||||
(equal? (simple-settings->vector x)
|
||||
(simple-settings->vector (default-settings))))
|
||||
|
@ -198,7 +198,7 @@
|
|||
insert-newlines
|
||||
annotations))
|
||||
;; case-sensitive : boolean
|
||||
;; printing-style : (union 'write 'constructor 'quasiquote)
|
||||
;; printing-style : (union 'print 'write 'trad-write 'constructor 'quasiquote)
|
||||
;; fraction-style : (union 'mixed-fraction 'mixed-fraction-e 'repeating-decimal 'repeating-decimal-e)
|
||||
;; show-sharing : boolean
|
||||
;; insert-newlines : boolean
|
||||
|
@ -267,18 +267,19 @@
|
|||
(string-constant output-style-label)
|
||||
(list (string-constant constructor-printing-style)
|
||||
(string-constant quasiquote-printing-style)
|
||||
(string-constant write-printing-style)
|
||||
(string-constant print-printing-style))
|
||||
output-panel
|
||||
(λ (rb evt)
|
||||
(let ([on? (not (= (send rb get-selection) 3))])
|
||||
(send fraction-style enable on?)
|
||||
(send show-sharing enable on?)
|
||||
(send insert-newlines enable on?)))
|
||||
(λ (rb evt) (enable-fraction-style))
|
||||
'(horizontal vertical-label))]
|
||||
[fraction-style
|
||||
(make-object check-box% (string-constant decimal-notation-for-rationals)
|
||||
output-panel
|
||||
void)]
|
||||
[enable-fraction-style
|
||||
(lambda ()
|
||||
(let ([on? (member (send output-style get-selection) '(0 1))])
|
||||
(send fraction-style enable on?)))]
|
||||
[show-sharing (make-object check-box%
|
||||
(string-constant sharing-printing-label)
|
||||
output-panel
|
||||
|
@ -299,7 +300,8 @@
|
|||
(case (send output-style get-selection)
|
||||
[(0) 'constructor]
|
||||
[(1) 'quasiquote]
|
||||
[(2) 'write])
|
||||
[(2) 'trad-write]
|
||||
[(3) 'print])
|
||||
(if (send fraction-style get-value)
|
||||
'repeating-decimal-e
|
||||
'mixed-fraction-e)
|
||||
|
@ -320,7 +322,9 @@
|
|||
(case (simple-settings-printing-style settings)
|
||||
[(constructor) 0]
|
||||
[(quasiquote) 1]
|
||||
[(write) 2]))
|
||||
[(write trad-write) 2]
|
||||
[(print) 3]))
|
||||
(enable-fraction-style)
|
||||
(send fraction-style set-value (eq? (simple-settings-fraction-style settings)
|
||||
'repeating-decimal-e))
|
||||
(send show-sharing set-value (simple-settings-show-sharing settings))
|
||||
|
@ -333,21 +337,28 @@
|
|||
|
||||
;; simple-module-based-language-render-value/format : TST settings port (union #f (snip% -> void)) (union 'infinity number) -> void
|
||||
(define (simple-module-based-language-render-value/format value settings port width)
|
||||
(let ([converted-value (simple-module-based-language-convert-value value settings)])
|
||||
(setup-printing-parameters
|
||||
(λ ()
|
||||
(cond
|
||||
[(simple-settings-insert-newlines settings)
|
||||
(if (number? width)
|
||||
(parameterize ([pretty-print-columns width])
|
||||
(pretty-print converted-value port))
|
||||
(pretty-print converted-value port))]
|
||||
[else
|
||||
(parameterize ([pretty-print-columns 'infinity])
|
||||
(pretty-print converted-value port))
|
||||
(newline port)]))
|
||||
settings
|
||||
width)))
|
||||
(let-values ([(converted-value write?)
|
||||
(call-with-values
|
||||
(lambda ()
|
||||
(simple-module-based-language-convert-value value settings))
|
||||
(case-lambda
|
||||
[(converted-value) (values converted-value #t)]
|
||||
[(converted-value write?) (values converted-value write?)]))])
|
||||
(let ([pretty-out (if write? pretty-write pretty-print)])
|
||||
(setup-printing-parameters
|
||||
(λ ()
|
||||
(cond
|
||||
[(simple-settings-insert-newlines settings)
|
||||
(if (number? width)
|
||||
(parameterize ([pretty-print-columns width])
|
||||
(pretty-out converted-value port))
|
||||
(pretty-out converted-value port))]
|
||||
[else
|
||||
(parameterize ([pretty-print-columns 'infinity])
|
||||
(pretty-out converted-value port))
|
||||
(newline port)]))
|
||||
settings
|
||||
width))))
|
||||
|
||||
(define default-pretty-print-current-style-table (pretty-print-current-style-table))
|
||||
|
||||
|
@ -415,11 +426,11 @@
|
|||
(write-special (render-syntax/snip value) port)]
|
||||
[else (write-special (value->snip value) port)]))]
|
||||
[print-graph
|
||||
;; only turn on print-graph when using `write' printing
|
||||
;; style because the sharing is being taken care of
|
||||
;; only turn on print-graph when using `write' or `print' printing
|
||||
;; style, because the sharing is being taken care of
|
||||
;; by the print-convert sexp construction when using
|
||||
;; other printing styles.
|
||||
(and (eq? (simple-settings-printing-style settings) 'write)
|
||||
(and (memq (simple-settings-printing-style settings) '(write print))
|
||||
(simple-settings-show-sharing settings))])
|
||||
(thunk))))
|
||||
|
||||
|
@ -429,7 +440,8 @@
|
|||
;; simple-module-based-language-convert-value : TST settings -> TST
|
||||
(define (simple-module-based-language-convert-value value settings)
|
||||
(case (simple-settings-printing-style settings)
|
||||
[(write) value]
|
||||
[(print) (values value #f)]
|
||||
[(write trad-write) value]
|
||||
[(constructor)
|
||||
(parameterize ([constructor-style-printing #t]
|
||||
[show-sharing (simple-settings-show-sharing settings)]
|
||||
|
@ -477,11 +489,16 @@
|
|||
|
||||
(global-port-print-handler
|
||||
(λ (value port)
|
||||
(let ([converted-value (simple-module-based-language-convert-value value setting)])
|
||||
(let-values ([(converted-value write?)
|
||||
(call-with-values
|
||||
(lambda () (simple-module-based-language-convert-value value setting))
|
||||
(case-lambda
|
||||
[(converted-value) (values converted-value #t)]
|
||||
[(converted-value write?) (values converted-value write?)]))])
|
||||
(setup-printing-parameters
|
||||
(λ ()
|
||||
(parameterize ([pretty-print-columns 'infinity])
|
||||
(pretty-print converted-value port)))
|
||||
((if write? pretty-write pretty-print) converted-value port)))
|
||||
setting
|
||||
'infinity))))
|
||||
(current-inspector (make-inspector))
|
||||
|
@ -507,20 +524,18 @@
|
|||
|
||||
(define (render-value value port)
|
||||
(parameterize ([pretty-print-columns 'infinity])
|
||||
(pretty-print (convert-value value) port)))
|
||||
|
||||
(define (convert-value value)
|
||||
,(case (simple-settings-printing-style setting)
|
||||
[(write) `value]
|
||||
[(constructor)
|
||||
`(parameterize ([constructor-style-printing #t]
|
||||
[show-sharing ,(simple-settings-show-sharing setting)])
|
||||
(print-convert value))]
|
||||
[(quasiquote)
|
||||
`(parameterize ([constructor-style-printing #f]
|
||||
[show-sharing ,(simple-settings-show-sharing setting)])
|
||||
(print-convert value))]))
|
||||
|
||||
,(case (simple-settings-printing-style setting)
|
||||
[(print) `(pretty-print value port)]
|
||||
[(write trad-write) `(pretty-write value port)]
|
||||
[(constructor)
|
||||
`(parameterize ([constructor-style-printing #t]
|
||||
[show-sharing ,(simple-settings-show-sharing setting)])
|
||||
(pretty-write (print-convert value) port))]
|
||||
[(quasiquote)
|
||||
`(parameterize ([constructor-style-printing #f]
|
||||
[show-sharing ,(simple-settings-show-sharing setting)])
|
||||
(pretty-write (print-convert value) port))])))
|
||||
|
||||
,(if (memq (simple-settings-annotations setting) '(debug debug/profile test-coverage))
|
||||
`(require errortrace)
|
||||
`(void))
|
||||
|
@ -1121,7 +1136,7 @@
|
|||
((if gui? make-mred-launcher make-mzscheme-launcher)
|
||||
(list
|
||||
(path->string
|
||||
(build-path (collection-path "drscheme" "private")
|
||||
(build-path (collection-path "drracket" "private")
|
||||
(if gui?
|
||||
"launcher-mred-bootstrap.rkt"
|
||||
"launcher-mz-bootstrap.rkt")))
|
|
@ -141,7 +141,7 @@
|
|||
(if (vector? info-result)
|
||||
'hash-lang-racket
|
||||
(get-lang-name pos))
|
||||
'drscheme/private/module-language-tools)
|
||||
'drracket/private/module-language-tools)
|
||||
((if (vector? info-result)
|
||||
(vector-ref info-result 0)
|
||||
info-result)
|
|
@ -106,7 +106,7 @@
|
|||
(define/override (default-settings)
|
||||
(let ([super-defaults (super default-settings)])
|
||||
(make-module-language-settings
|
||||
#t 'write 'mixed-fraction-e #f #t 'debug;; simple settings defaults
|
||||
#t 'print 'mixed-fraction-e #f #t 'debug;; simple settings defaults
|
||||
|
||||
'(default)
|
||||
#()
|
||||
|
@ -163,7 +163,15 @@
|
|||
(andmap string? (vector->list command-line-args))
|
||||
(string? auto-text)
|
||||
(boolean? compilation-on?)
|
||||
(let ([super (super unmarshall-settings (car marshalled))])
|
||||
(let ([super (super unmarshall-settings
|
||||
(let ([p (car marshalled)])
|
||||
;; Convert 'write to 'print:
|
||||
(if (eq? (vector-ref p 1) 'write)
|
||||
(list->vector
|
||||
(list* (vector-ref p 0)
|
||||
'print
|
||||
(cddr (vector->list p))))
|
||||
p)))])
|
||||
(and super
|
||||
(apply make-module-language-settings
|
||||
(append
|
||||
|
@ -204,11 +212,11 @@
|
|||
(case annotations
|
||||
[(none)
|
||||
(use-compiled-file-paths
|
||||
(cons (build-path "compiled" "drscheme")
|
||||
(cons (build-path "compiled" "drracket")
|
||||
(use-compiled-file-paths)))]
|
||||
[(debug)
|
||||
(use-compiled-file-paths
|
||||
(cons (build-path "compiled" "drscheme" "errortrace")
|
||||
(cons (build-path "compiled" "drracket" "errortrace")
|
||||
(use-compiled-file-paths)))]))
|
||||
|
||||
(current-load/use-compiled (make-compilation-manager-load/use-compiled-handler))
|
|
@ -5,5 +5,5 @@
|
|||
|
||||
(provide snip-class)
|
||||
(define snip-class (make-object number-snip:snip-class%))
|
||||
(send snip-class set-classname (format "~s" `(lib "number-snip.ss" "drscheme" "private")))
|
||||
(send snip-class set-classname (format "~s" `(lib "number-snip.ss" "drracket" "private")))
|
||||
(send (get-the-snip-class-list) add snip-class)
|
|
@ -19,7 +19,8 @@ This file sets up the right lexical environment to invoke the tools that want to
|
|||
mrlib/switchable-button
|
||||
string-constants)
|
||||
|
||||
(require (for-syntax racket/base racket/match))
|
||||
(require (for-syntax racket/base racket/match
|
||||
compiler/cm-accomplice))
|
||||
|
||||
(import [prefix drscheme:frame: drracket:frame^]
|
||||
[prefix drscheme:unit: drracket:unit^]
|
||||
|
@ -41,12 +42,15 @@ This file sets up the right lexical environment to invoke the tools that want to
|
|||
(syntax-case stx ()
|
||||
[(_ body tool-name)
|
||||
(let ()
|
||||
(define tool-lib-src (build-path (collection-path "drracket") "tool-lib.rkt"))
|
||||
(define full-sexp
|
||||
(call-with-input-file (build-path (collection-path "drscheme") "tool-lib.rkt")
|
||||
(call-with-input-file tool-lib-src
|
||||
(λ (port)
|
||||
(parameterize ([read-accept-reader #t])
|
||||
(read port)))))
|
||||
|
||||
(register-external-file tool-lib-src)
|
||||
|
||||
(let loop ([sexp full-sexp])
|
||||
(match sexp
|
||||
[`((#%module-begin ,body ...))
|
|
@ -13,7 +13,8 @@
|
|||
mrlib/switchable-button
|
||||
string-constants)
|
||||
|
||||
(require (for-syntax racket/base racket/match))
|
||||
(require (for-syntax racket/base racket/match
|
||||
compiler/cm-accomplice))
|
||||
|
||||
(import [prefix drracket:frame: drracket:frame^]
|
||||
[prefix drracket:unit: drracket:unit^]
|
||||
|
@ -322,11 +323,15 @@ string-constants)
|
|||
(syntax-case stx ()
|
||||
[(_ body tool-name)
|
||||
(let ()
|
||||
(define tool-lib-src (build-path (collection-path "drracket") "tool-lib.rkt"))
|
||||
|
||||
(define full-sexp
|
||||
(call-with-input-file (build-path (collection-path "drscheme") "tool-lib.rkt")
|
||||
(call-with-input-file tool-lib-src
|
||||
(λ (port)
|
||||
(parameterize ([read-accept-reader #t])
|
||||
(read port)))))
|
||||
|
||||
(register-external-file tool-lib-src)
|
||||
|
||||
(let loop ([sexp full-sexp])
|
||||
(match sexp
|
|
@ -23,11 +23,11 @@ If the namespace does not, they are colored the unbound color.
|
|||
scheme/class
|
||||
scheme/list
|
||||
scheme/promise
|
||||
drscheme/tool
|
||||
drracket/tool
|
||||
syntax/toplevel
|
||||
syntax/boundmap
|
||||
mrlib/switchable-button
|
||||
(prefix-in drracket:arrow: drscheme/arrow)
|
||||
(prefix-in drracket:arrow: drracket/arrow)
|
||||
(prefix-in fw: framework/framework)
|
||||
mred
|
||||
framework
|
1585
collects/drracket/tool-lib.rkt
Normal file
1585
collects/drracket/tool-lib.rkt
Normal file
File diff suppressed because it is too large
Load Diff
6
collects/drracket/tool.rkt
Normal file
6
collects/drracket/tool.rkt
Normal file
|
@ -0,0 +1,6 @@
|
|||
#lang racket/base
|
||||
(require "private/drsig.ss")
|
||||
(provide drracket:tool^
|
||||
drracket:tool-exports^
|
||||
drscheme:tool^
|
||||
(rename-out [drracket:tool-exports^ drscheme:tool-exports^]))
|
|
@ -1,67 +1,2 @@
|
|||
#lang racket/base
|
||||
(require scheme/gui/base "private/key.rkt")
|
||||
|
||||
(define debugging? (getenv "PLTDRDEBUG"))
|
||||
(define profiling? (getenv "PLTDRPROFILE"))
|
||||
|
||||
(define install-cm? (and (not debugging?)
|
||||
(getenv "PLTDRCM")))
|
||||
|
||||
(define cm-trace? (or (equal? (getenv "PLTDRCM") "trace")
|
||||
(equal? (getenv "PLTDRDEBUG") "trace")))
|
||||
|
||||
|
||||
;; the flush is only here to ensure that the output is
|
||||
;; appears when running in cygwin under windows.
|
||||
(define (flprintf fmt . args)
|
||||
(apply printf fmt args)
|
||||
(flush-output))
|
||||
|
||||
(when debugging?
|
||||
(flprintf "PLTDRDEBUG: installing CM to load/create errortrace zos\n")
|
||||
(let-values ([(zo-compile
|
||||
make-compilation-manager-load/use-compiled-handler
|
||||
manager-trace-handler)
|
||||
(parameterize ([current-namespace (make-base-empty-namespace)]
|
||||
[use-compiled-file-paths '()])
|
||||
(values
|
||||
(dynamic-require 'errortrace/zo-compile 'zo-compile)
|
||||
(dynamic-require 'compiler/cm 'make-compilation-manager-load/use-compiled-handler)
|
||||
(dynamic-require 'compiler/cm 'manager-trace-handler)))])
|
||||
(current-compile zo-compile)
|
||||
(use-compiled-file-paths (list (build-path "compiled" "errortrace")))
|
||||
(current-load/use-compiled (make-compilation-manager-load/use-compiled-handler))
|
||||
(error-display-handler (dynamic-require 'errortrace/errortrace-lib
|
||||
'errortrace-error-display-handler))
|
||||
(when cm-trace?
|
||||
(flprintf "PLTDRDEBUG: enabling CM tracing\n")
|
||||
(manager-trace-handler
|
||||
(λ (x) (display "1: ") (display x) (newline) (flush-output))))))
|
||||
|
||||
(when install-cm?
|
||||
(flprintf "PLTDRCM: installing compilation manager\n")
|
||||
(let-values ([(make-compilation-manager-load/use-compiled-handler
|
||||
manager-trace-handler)
|
||||
(parameterize ([current-namespace (make-base-empty-namespace)])
|
||||
(values
|
||||
(dynamic-require 'compiler/cm 'make-compilation-manager-load/use-compiled-handler)
|
||||
(dynamic-require 'compiler/cm 'manager-trace-handler)))])
|
||||
(current-load/use-compiled (make-compilation-manager-load/use-compiled-handler))
|
||||
(when cm-trace?
|
||||
(flprintf "PLTDRCM: enabling CM tracing\n")
|
||||
(manager-trace-handler
|
||||
(λ (x) (display "1: ") (display x) (newline) (flush-output))))))
|
||||
|
||||
(when profiling?
|
||||
(flprintf "PLTDRPROFILE: installing profiler\n")
|
||||
;; NOTE that this might not always work.
|
||||
;; it creates a new custodian and installs it, but the
|
||||
;; original eventspace was created on the original custodian
|
||||
;; and this code does not create a new eventspace.
|
||||
(let ([orig-cust (current-custodian)]
|
||||
[orig-eventspace (current-eventspace)]
|
||||
[new-cust (make-custodian)])
|
||||
(current-custodian new-cust)
|
||||
((dynamic-require 'drscheme/private/profile-drs 'start-profile) orig-cust)))
|
||||
|
||||
(dynamic-require 'drscheme/private/drscheme-normal #f)
|
||||
(require drracket/drracket)
|
||||
|
|
|
@ -1,13 +1,4 @@
|
|||
#lang setup/infotab
|
||||
|
||||
;(define tools '("sprof.rkt"))
|
||||
;(define tool-names '("Sampling Profiler"))
|
||||
|
||||
(define drracket-tools '("syncheck.rkt"))
|
||||
(define drracket-tool-names '("Check Syntax"))
|
||||
|
||||
(define gracket-launcher-names '("DrRacket"))
|
||||
(define gracket-launcher-libraries '("drscheme.rkt"))
|
||||
|
||||
(define mred-launcher-names '("DrScheme"))
|
||||
(define mred-launcher-libraries '("drscheme.rkt"))
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1,6 +1,3 @@
|
|||
#lang racket/base
|
||||
(require "private/drsig.ss")
|
||||
(provide drracket:tool^
|
||||
drracket:tool-exports^
|
||||
drscheme:tool^
|
||||
(rename-out [drracket:tool-exports^ drscheme:tool-exports^]))
|
||||
(require drracket/tool)
|
||||
(provide (all-from-out drracket/tool))
|
||||
|
|
|
@ -46,6 +46,14 @@ wraps the load of the module.)
|
|||
(drscheme:language:simple-module-based-language->module-based-language-mixin
|
||||
language-base%))
|
||||
(define/override (use-namespace-require/copy?) #t)
|
||||
(define/override (default-settings)
|
||||
(let ([s (super default-settings)])
|
||||
(drscheme:language:make-simple-settings (drscheme:language:simple-settings-case-sensitive s)
|
||||
'trad-write
|
||||
(drscheme:language:simple-settings-fraction-style s)
|
||||
(drscheme:language:simple-settings-show-sharing s)
|
||||
(drscheme:language:simple-settings-insert-newlines s)
|
||||
(drscheme:language:simple-settings-annotations s))))
|
||||
(define/override (on-execute settings run-in-user-thread)
|
||||
(super on-execute settings run-in-user-thread)
|
||||
(print-mpair-curly-braces #f)
|
||||
|
|
|
@ -1,2 +1,3 @@
|
|||
#lang s-exp syntax/module-reader
|
||||
eopl
|
||||
#:language-info '#(scheme/language-info get-info #f)
|
||||
|
|
|
@ -247,7 +247,7 @@
|
|||
(-> void?)
|
||||
()
|
||||
@{Adds a preferences panel for configuring options related to
|
||||
Scheme.})
|
||||
Racket.})
|
||||
|
||||
(proc-doc/names
|
||||
preferences:add-to-warnings-checkbox-panel
|
||||
|
@ -261,7 +261,7 @@
|
|||
(((is-a?/c vertical-panel%) . -> . void?) . -> . void?)
|
||||
(proc)
|
||||
@{Saves @scheme[proc] until the preferences panel is created, when it
|
||||
is called with the Scheme preferences panel to add new children to
|
||||
is called with the Racket preferences panel to add new children to
|
||||
the panel.})
|
||||
|
||||
(proc-doc/names
|
||||
|
@ -1343,14 +1343,14 @@
|
|||
scheme:get-keymap
|
||||
(-> (is-a?/c keymap%))
|
||||
()
|
||||
@{Returns a keymap with binding suitable for Scheme.})
|
||||
@{Returns a keymap with binding suitable for Racket.})
|
||||
|
||||
(proc-doc/names
|
||||
scheme:add-coloring-preferences-panel
|
||||
(-> any)
|
||||
()
|
||||
@{
|
||||
Installs the ``Scheme'' preferences panel in the ``Syntax Coloring''
|
||||
Installs the ``Racket'' preferences panel in the ``Syntax Coloring''
|
||||
section.})
|
||||
|
||||
(proc-doc/names
|
||||
|
@ -1359,7 +1359,7 @@
|
|||
()
|
||||
@{Returns
|
||||
a table mapping from symbols
|
||||
(naming the categories that the online colorer uses for Scheme mode coloring) to their colors.
|
||||
(naming the categories that the online colorer uses for Racket mode coloring) to their colors.
|
||||
|
||||
These symbols are suitable for input to
|
||||
@scheme[scheme:short-sym->pref-name] and
|
||||
|
@ -1373,7 +1373,7 @@
|
|||
()
|
||||
@{Returns
|
||||
a table mapping from symbols
|
||||
(naming the categories that the online colorer uses for Scheme mode coloring) to their colors when
|
||||
(naming the categories that the online colorer uses for Racket mode coloring) to their colors when
|
||||
the user chooses the white-on-black mode in the preferences dialog.
|
||||
|
||||
See also @scheme[scheme:get-color-prefs-table].})
|
||||
|
@ -1399,7 +1399,7 @@
|
|||
(-> (is-a?/c editor-wordbreak-map%))
|
||||
()
|
||||
@{This method returns a @scheme[editor-wordbreak-map%] that is suitable
|
||||
for Scheme.})
|
||||
for Racket.})
|
||||
|
||||
(proc-doc/names
|
||||
scheme:init-wordbreak-map
|
||||
|
@ -1411,7 +1411,7 @@
|
|||
scheme:setup-keymap
|
||||
((is-a?/c keymap%) . -> . void?)
|
||||
(keymap)
|
||||
@{Initializes @scheme[keymap] with Scheme-mode keybindings.})
|
||||
@{Initializes @scheme[keymap] with Racket-mode keybindings.})
|
||||
|
||||
(proc-doc/names
|
||||
editor:set-default-font-color
|
||||
|
|
|
@ -1186,7 +1186,7 @@
|
|||
(values lexeme type paren start end backup-delta mode)))))
|
||||
|
||||
(define/override (put-file text sup directory default-name)
|
||||
(parameterize ([finder:default-extension "ss"]
|
||||
(parameterize ([finder:default-extension "rkt"]
|
||||
[finder:default-filters '(["Racket Sources" "*.rkt;*.ss;*.scm"]
|
||||
["Any" "*.*"])])
|
||||
;; don't call the surrogate's super, since it sets the default extension
|
||||
|
|
|
@ -196,17 +196,24 @@
|
|||
(set-printing-parameters
|
||||
settings
|
||||
(λ ()
|
||||
(let ([converted-value (drscheme:language:simple-module-based-language-convert-value value settings)])
|
||||
(cond
|
||||
[(drscheme:language:simple-settings-insert-newlines settings)
|
||||
(if (number? width)
|
||||
(parameterize ([pretty-print-columns width])
|
||||
(pretty-write converted-value port))
|
||||
(pretty-write converted-value port))]
|
||||
[else
|
||||
(parameterize ([pretty-print-columns 'infinity])
|
||||
(pretty-write converted-value port))
|
||||
(newline port)])))))
|
||||
(let-values ([(converted-value write?)
|
||||
(call-with-values
|
||||
(lambda ()
|
||||
(drscheme:language:simple-module-based-language-convert-value value settings))
|
||||
(case-lambda
|
||||
[(converted-value) (values converted-value #t)]
|
||||
[(converted-value write?) (values converted-value write?)]))])
|
||||
(let ([pretty-out (if write? pretty-write pretty-print)])
|
||||
(cond
|
||||
[(drscheme:language:simple-settings-insert-newlines settings)
|
||||
(if (number? width)
|
||||
(parameterize ([pretty-print-columns width])
|
||||
(pretty-out converted-value port))
|
||||
(pretty-out converted-value port))]
|
||||
[else
|
||||
(parameterize ([pretty-print-columns 'infinity])
|
||||
(pretty-out converted-value port))
|
||||
(newline port)]))))))
|
||||
settings
|
||||
width))
|
||||
|
||||
|
@ -309,13 +316,11 @@
|
|||
(case (drscheme:language:simple-settings-printing-style settings)
|
||||
[(constructor) 0]
|
||||
[(quasiquote) 1]
|
||||
[(write) 2]
|
||||
[(print) 2])
|
||||
[(print trad-write write) 2])
|
||||
(case (drscheme:language:simple-settings-printing-style settings)
|
||||
[(constructor) 0]
|
||||
[(quasiquote) 0]
|
||||
[(write) 1]
|
||||
[(print) 1])))
|
||||
[(print trad-write write) 1])))
|
||||
(send fraction-style set-selection
|
||||
(case (drscheme:language:simple-settings-fraction-style settings)
|
||||
[(mixed-fraction) 0]
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
(require scheme/list
|
||||
scheme/class
|
||||
scheme/gui
|
||||
drscheme/arrow
|
||||
drracket/arrow
|
||||
framework/framework
|
||||
unstable/interval-map
|
||||
unstable/gui/notify
|
||||
|
|
|
@ -89,6 +89,18 @@ _raco_planet()
|
|||
COMPREPLY=( $(compgen -W "${planetcmds}" -- ${cur}) )
|
||||
}
|
||||
|
||||
raco_cmds=$()
|
||||
|
||||
_raco_help()
|
||||
{
|
||||
local cur="${COMP_WORDS[COMP_CWORD]}"
|
||||
if [ ${#raco_cmds[@]} -eq 0 ]; then
|
||||
# removing the empty string on the next line breaks things. such as my brain.
|
||||
raco_cmds=$( echo '' 'help' ; for x in `racket -e '(begin (require raco/all-tools) (for ([(k v) (all-tools)]) (printf "~a\n" k)))'` ; do echo ${x} ; done )
|
||||
fi
|
||||
COMPREPLY=( $(compgen -W "${raco_cmds}" -- ${cur}) )
|
||||
}
|
||||
|
||||
_raco()
|
||||
{
|
||||
COMPREPLY=()
|
||||
|
@ -101,8 +113,8 @@ _raco()
|
|||
|
||||
if [ $COMP_CWORD -eq 1 ]; then
|
||||
# removing the empty string on the next line breaks things. such as my brain.
|
||||
local cmds=$( echo '' '--help' ; for x in `racket -e '(begin (require raco/all-tools) (for ([(k v) (all-tools)]) (printf "~a\n" k)))'` ; do echo ${x} ; done )
|
||||
COMPREPLY=($(compgen -W "${cmds}" -- ${cur}))
|
||||
raco_cmds=$( echo '' 'help' ; for x in `racket -e '(begin (require raco/all-tools) (for ([(k v) (all-tools)]) (printf "~a\n" k)))'` ; do echo ${x} ; done )
|
||||
COMPREPLY=($(compgen -W "${raco_cmds}" -- ${cur}))
|
||||
elif [ $COMP_CWORD -eq 2 ]; then
|
||||
# Here we'll handle the main raco commands
|
||||
local prev="${COMP_WORDS[1]}"
|
||||
|
@ -120,7 +132,8 @@ _raco()
|
|||
planet)
|
||||
_raco_planet
|
||||
;;
|
||||
--help)
|
||||
help)
|
||||
_raco_help
|
||||
;;
|
||||
*)
|
||||
_filedir
|
||||
|
|
|
@ -150,17 +150,17 @@ src-filter := (src: "")
|
|||
docs-filter := (- (doc: "") ; all docs,
|
||||
(notes: "") ; excluding basic stuff
|
||||
std-docs) ; and things in svn
|
||||
docsrc-filter := (+ (collects: "setup/scribble.ss") ; only with doc sources
|
||||
docsrc-filter := (+ (collects: "setup/scribble.rkt") ; only with doc sources
|
||||
(collects: "**/scribblings/")
|
||||
(srcfile: "*.{scrbl|scribble}")
|
||||
std-docs)
|
||||
man-filter := (man: "*")
|
||||
tests-filter := (+ (collects: "**/tests/") (srcfile: "tests.ss"))
|
||||
tests-filter := (+ (collects: "**/tests/") (srcfile: "tests.rkt"))
|
||||
gui-filter := (- (+ (collects: "**/gui/") (srcfile: "gui.rkt"))
|
||||
;; for use in mz code that works in mr too
|
||||
(srcfile: "scheme/gui/dynamic.rkt")
|
||||
(srcfile: "racket/gui/dynamic.rkt"))
|
||||
tools-filter := (+ (collects: "**/tools/") (srcfile: "tools.ss"))
|
||||
tools-filter := (+ (collects: "**/tools/") (srcfile: "tools.rkt"))
|
||||
|
||||
;; these are in the doc directory, but are comitted in svn and should be
|
||||
;; considered like sources
|
||||
|
@ -327,7 +327,7 @@ plt := (+ dr plt-extras)
|
|||
;; Packages etc
|
||||
|
||||
mz-base := "/plt/readme.txt" ; generated
|
||||
(package: "mzscheme")
|
||||
(package: "mzscheme") (notes: "racket")
|
||||
"/plt/include/"
|
||||
;; configuration stuff
|
||||
(cond (not src) => (collects: "info-domain/")) ; filtered
|
||||
|
@ -337,22 +337,23 @@ mz-base := "/plt/readme.txt" ; generated
|
|||
;; include the time-stamp collection when not a public release
|
||||
(cond (not release)
|
||||
=> (- (collects: "repos-time-stamp/")
|
||||
(cond (not dr) => (srcfile: "time-stamp.ss"))))
|
||||
(cond (not dr) => (srcfile: "time-stamp.rkt"))))
|
||||
mz-manuals := (scribblings: "main/") ; generates main pages (next line)
|
||||
(doc: "license/" "release/" "acks/" "search/" "master-index/"
|
||||
(doc: "license/" "release/" "acks/" "search/"
|
||||
"getting-started/")
|
||||
(notes: "COPYING.LIB" "COPYING-libscheme.txt")
|
||||
(doc: "doc-license.txt") ; needed (when docs are included)
|
||||
(doc+src: "reference/" "guide/" "quick/" "more/"
|
||||
"foreign/" "inside/" ;; "places/" <- not ready yet
|
||||
"scheme/"
|
||||
"honu/")
|
||||
(doc: "*.{html|css|js|sxref}")
|
||||
(scribblings: "{{info|icons}.ss|*.png}" "compiled")
|
||||
(scribblings: "{{info|icons}.rkt|*.png}" "compiled")
|
||||
|
||||
mr-base := (package: "mred") (bin: "mred-text") (collects: "afm/")
|
||||
mr-base := (package: "mred") (notes: "gracket") (bin: "mred-text") (collects: "afm/")
|
||||
mr-manuals := (doc+src: "gui/")
|
||||
|
||||
dr-base := (package: "drscheme") (package: "framework")
|
||||
dr-base := (package: "drracket") (package: "drscheme") (package: "framework")
|
||||
dr-manuals := (doc+src: "tools/")
|
||||
|
||||
;; Misc hooks, to be added on by package rules below
|
||||
|
@ -362,7 +363,7 @@ dr-extras :=
|
|||
plt-extras :=
|
||||
|
||||
;; Tests definitions
|
||||
mz-tests := (tests: "mzscheme/" "info.ss" "utils/" "match/" "eli-tester.ss")
|
||||
mz-tests := (tests: "mzscheme/" "info.rkt" "utils/" "match/" "eli-tester.rkt")
|
||||
|
||||
;; ============================================================================
|
||||
;; Source definitions
|
||||
|
@ -383,7 +384,7 @@ mr-src := (src: "mred/" "wxcommon/"
|
|||
"worksp/{png|wxme|wxs|wxutils|wxwin|zlib}/"))
|
||||
|
||||
foreign-src := (src: "foreign/{Makefile.in|README}"
|
||||
"foreign/{foreign.*|ssc-utils.ss}"
|
||||
"foreign/{foreign.*|ssc-utils.rkt}"
|
||||
(cond win => "foreign/libffi_msvc"
|
||||
else => "foreign/gcc"))
|
||||
|
||||
|
@ -429,7 +430,7 @@ platform-dependent := ; hook for package rules
|
|||
|
||||
;; -------------------- setup
|
||||
mz-extras :+= (- (package: "setup-plt" #:collection "setup/")
|
||||
(cond (not dr) => (srcfile: "plt-installer{|-sig|-unit}.ss")))
|
||||
(cond (not dr) => (srcfile: "plt-installer{|-sig|-unit}.rkt")))
|
||||
|
||||
;; -------------------- raco
|
||||
mz-extras :+= (package: "raco")
|
||||
|
@ -508,7 +509,7 @@ mz-extras :+= (package: "srfi") (doc: "srfi-std")
|
|||
|
||||
;; -------------------- xml
|
||||
mz-extras :+= (- (package: "xml/")
|
||||
(cond* (not plt) => (srcfile: "*-{tool|snipclass}.ss"
|
||||
(cond* (not plt) => (srcfile: "*-{tool|snipclass}.rkt"
|
||||
"xml.png")))
|
||||
|
||||
;; -------------------- ffi
|
||||
|
@ -534,7 +535,7 @@ mr-extras :+= (- (+ (package: "mrlib/")
|
|||
|
||||
;; -------------------- sgl
|
||||
mr-extras :+= (package: "sgl/")
|
||||
;; gl-info.ss doesn't exist, but gl-info.zo holds platform-dependent data
|
||||
;; gl-info.rkt doesn't exist, but gl-info.zo holds platform-dependent data
|
||||
platform-dependent :+= (and (collects: "sgl/")
|
||||
(srcfile: "sgl/gl-info"))
|
||||
|
||||
|
@ -579,7 +580,7 @@ dr-extras :+= (collects: "defaults/")
|
|||
|
||||
;; -------------------- version
|
||||
mz-extras :+= (- (package: "version/")
|
||||
(cond* (not dr) => (srcfile: "tool.ss")))
|
||||
(cond* (not dr) => (srcfile: "tool.rkt")))
|
||||
|
||||
;; -------------------- browser
|
||||
dr-extras :+= (package: "browser/")
|
||||
|
@ -612,14 +613,16 @@ plt-extras :+= (package: "frtime/")
|
|||
dr-extras :+= (package: "typed-scheme/" ; used in drscheme
|
||||
#:docs "ts-{reference|guide}/")
|
||||
(- (collects: "typed/")
|
||||
(cond (not plt) => (collects: "typed/test-engine/")))
|
||||
(cond (not plt) => (collects: "typed/test-engine/")
|
||||
(collects: "typed/racunit/")
|
||||
(srcfile: "typed/racunit.rkt")))
|
||||
|
||||
;; -------------------- gui-debugger
|
||||
plt-extras :+= (collects: "gui-debugger/")
|
||||
|
||||
;; -------------------- swindle
|
||||
mz-extras :+= (- (package: "swindle")
|
||||
(cond (not dr) => (srcfile: "tool.ss" "swindle*.png")))
|
||||
(cond (not dr) => (srcfile: "tool.rkt" "swindle*.png")))
|
||||
|
||||
;; -------------------- plot
|
||||
plt-extras :+=
|
||||
|
@ -665,4 +668,6 @@ plt-extras :+= (package: "plai/")
|
|||
plt-extras :+= (package: "racunit/")
|
||||
plt-extras :+= (package: "schemeunit/")
|
||||
|
||||
plt-extras :+= (package: "raclog/")
|
||||
|
||||
;; ============================================================================
|
||||
|
|
|
@ -547,6 +547,7 @@ path/s is either such a string or a list of them.
|
|||
"collects/compiler/commands/ctool.rkt" drdr:command-line ""
|
||||
"collects/compiler/commands/exe-dir.rkt" drdr:command-line ""
|
||||
"collects/compiler/commands/exe.rkt" drdr:command-line ""
|
||||
"collects/compiler/commands/make.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/compiler/commands/pack.rkt" drdr:command-line ""
|
||||
"collects/config" responsible (mflatt eli)
|
||||
"collects/defaults" responsible (robby)
|
||||
|
@ -563,53 +564,57 @@ path/s is either such a string or a list of them.
|
|||
"collects/deinprogramm/run-dmda-code.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/deinprogramm/turtle.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/deinprogramm/world.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket" responsible (robby)
|
||||
"collects/drracket/arrow.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/drracket.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drracket/main.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drracket/private/app.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/auto-language.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/bindings-browser.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/bitmap-message.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/debug.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/drracket-normal.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drracket/private/eb.rkt" drdr:command-line "mred-text ~s"
|
||||
"collects/drracket/private/embedded-snip-utils.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/eval.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/font.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/frame.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/help-desk.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/honu-logo.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/init.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/insert-large-letters.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/label-frame-mred.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/language-configuration.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/language-object-contract.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/language.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/launcher-mred-bootstrap.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drracket/private/launcher-mz-bootstrap.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drracket/private/link.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/main.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/modes.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/module-browser.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/module-language-tools.rkt" drdr:command-line "mred-text ~s"
|
||||
"collects/drracket/private/module-language.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/multi-file-search.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/number-snip.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/palaka.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/prefs-contract.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/profile-drs.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/rep.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/stick-figures.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drracket/private/syncheck-debug.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/text.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/tools-drs.rkt" drdr:command-line "mred ~s"
|
||||
"collects/drracket/private/tools.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/tracing.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/private/unit.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/sprof.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/syncheck-drracket-button.rkt" drdr:command-line "mred-text ~s"
|
||||
"collects/drracket/syncheck.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drracket/tool-lib.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drscheme" responsible (robby)
|
||||
"collects/drscheme/arrow.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/drscheme.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drscheme/main.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drscheme/private/app.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/auto-language.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/bindings-browser.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/bitmap-message.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/debug.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/drscheme-normal.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drscheme/private/eb.rkt" drdr:command-line "mred-text ~s"
|
||||
"collects/drscheme/private/embedded-snip-utils.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/eval.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/font.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/frame.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/help-desk.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/honu-logo.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/init.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/insert-large-letters.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/label-frame-mred.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/language-configuration.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/language-object-contract.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/language.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/launcher-mred-bootstrap.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drscheme/private/launcher-mz-bootstrap.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drscheme/private/link.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/main.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/modes.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/module-browser.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/module-language-tools.rkt" drdr:command-line "mred-text ~s"
|
||||
"collects/drscheme/private/module-language.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/multi-file-search.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/number-snip.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/palaka.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/prefs-contract.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/profile-drs.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/rep.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/stick-figures.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/drscheme/private/syncheck-debug.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/text.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/tools-drs.rkt" drdr:command-line "mred ~s"
|
||||
"collects/drscheme/private/tools.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/tracing.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/private/unit.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/sprof.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/syncheck-drracket-button.rkt" drdr:command-line "mred-text ~s"
|
||||
"collects/drscheme/syncheck.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/drscheme/tool-lib.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/dynext" responsible (mflatt)
|
||||
"collects/dynext/private/macinc.rkt" drdr:command-line "mzscheme -f ~s"
|
||||
|
@ -1167,8 +1172,8 @@ path/s is either such a string or a list of them.
|
|||
"collects/redex/tests/run-tests.rkt" drdr:command-line "mred-text ~s --examples --no-bitmaps" drdr:timeout 300
|
||||
"collects/redex/tests/term-test.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/redex/tests/tl-test.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/repos-time-stamp" responsible (eli)
|
||||
"collects/repos-time-stamp/time-stamp.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/repo-time-stamp" responsible (eli)
|
||||
"collects/repo-time-stamp/time-stamp.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/rnrs" responsible (mflatt)
|
||||
"collects/s-exp" responsible (mflatt eli)
|
||||
"collects/scheme" responsible (mflatt sstrickl samth robby eli)
|
||||
|
@ -1188,7 +1193,7 @@ path/s is either such a string or a list of them.
|
|||
"collects/scribble" responsible (mflatt eli)
|
||||
"collects/scribble/run.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/scribble/tools/drscheme-buttons.rkt" drdr:command-line "mred-text ~s"
|
||||
"collects/scribble/tools/private/mk-drs-bitmaps.rkt" drdr:command-line "mred-text ~s" drdr:timeout 600
|
||||
"collects/scribble/tools/private/mk-drs-bitmaps.rkt" drdr:command-line "gracket-text ~s skip"
|
||||
"collects/scribblings" responsible (mflatt eli robby mathias)
|
||||
"collects/scribblings/foreign/unsafe-foreign.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/scribblings/framework/standard-menus.scrbl" drdr:command-line ""
|
||||
|
@ -1332,22 +1337,22 @@ path/s is either such a string or a list of them.
|
|||
"collects/tests/deinprogramm" responsible (sperber)
|
||||
"collects/tests/deinprogramm/image.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/tests/deinprogramm/run-image-test.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/tests/drscheme" responsible (robby)
|
||||
"collects/tests/drscheme/drscheme-test-util.rkt" drdr:command-line "mred -t ~s"
|
||||
"collects/tests/drscheme/io.rkt" drdr:command-line "mred ~s"
|
||||
"collects/tests/drscheme/language-test.rkt" drdr:command-line "mred ~s" drdr:timeout 600
|
||||
"collects/tests/drscheme/module-lang-test-utils.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/tests/drscheme/module-lang-test.rkt" drdr:command-line "mred ~s" drdr:timeout 120
|
||||
"collects/tests/drscheme/randomly-click-language-dialog.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/tests/drscheme/randomly-click-preferences.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/tests/drscheme/randomly-click.rkt" drdr:command-line ""
|
||||
"collects/tests/drscheme/repl-test.rkt" drdr:command-line "mred ~s" drdr:timeout 600
|
||||
"collects/tests/drscheme/sample-solutions-one-window.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/tests/drscheme/save-teaching-lang-file.rkt" drdr:command-line "mred ~s"
|
||||
"collects/tests/drscheme/stepper-test.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/tests/drscheme/syncheck-test.rkt" drdr:command-line "mred ~s"
|
||||
"collects/tests/drscheme/teachpack.rkt" drdr:command-line "mred ~s"
|
||||
"collects/tests/drscheme/time-keystrokes.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/tests/drracket" responsible (robby)
|
||||
"collects/tests/drracket/drracket-test-util.rkt" drdr:command-line "mred -t ~s"
|
||||
"collects/tests/drracket/io.rkt" drdr:command-line "mred ~s"
|
||||
"collects/tests/drracket/language-test.rkt" drdr:command-line "mred ~s" drdr:timeout 600
|
||||
"collects/tests/drracket/module-lang-test-utils.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/tests/drracket/module-lang-test.rkt" drdr:command-line "mred ~s" drdr:timeout 120
|
||||
"collects/tests/drracket/randomly-click-language-dialog.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/tests/drracket/randomly-click-preferences.rkt" drdr:command-line "mzc ~s"
|
||||
"collects/tests/drracket/randomly-click.rkt" drdr:command-line ""
|
||||
"collects/tests/drracket/repl-test.rkt" drdr:command-line "mred ~s" drdr:timeout 600
|
||||
"collects/tests/drracket/sample-solutions-one-window.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/tests/drracket/save-teaching-lang-file.rkt" drdr:command-line "mred ~s"
|
||||
"collects/tests/drracket/stepper-test.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/tests/drracket/syncheck-test.rkt" drdr:command-line "mred ~s"
|
||||
"collects/tests/drracket/teachpack.rkt" drdr:command-line "mred ~s"
|
||||
"collects/tests/drracket/time-keystrokes.rkt" drdr:command-line "mred-text -t ~s"
|
||||
"collects/tests/framework" responsible (robby)
|
||||
"collects/tests/framework/canvas.rkt" drdr:command-line "mzc -k ~s"
|
||||
"collects/tests/framework/debug.rkt" drdr:command-line "mzc -k ~s"
|
||||
|
@ -1810,14 +1815,14 @@ path/s is either such a string or a list of them.
|
|||
"doc/release-notes/gracket" responsible (mflatt)
|
||||
"doc/release-notes/racket" responsible (mflatt)
|
||||
"doc/release-notes/stepper" responsible (clements)
|
||||
"man/man1/drscheme.1" responsible (robby)
|
||||
"man/man1/drracket.1" responsible (robby)
|
||||
"man/man1/mred.1" responsible (mflatt)
|
||||
"man/man1/drscheme.1" responsible (robby)
|
||||
"man/man1/gracket.1" responsible (mflatt)
|
||||
"man/man1/mred.1" responsible (mflatt)
|
||||
"man/man1/mzscheme.1" responsible (mflatt)
|
||||
"man/man1/plt-help.1" responsible (robby)
|
||||
"man/man1/racket.1" responsible (mflatt)
|
||||
"man/man1/raco.1" responsible (mflatt)
|
||||
"man/man1/plt-help.1" responsible (robby)
|
||||
"src/Makefile.in" responsible (mflatt)
|
||||
"src/README" responsible (mflatt)
|
||||
"src/a-list" responsible (mflatt)
|
||||
|
|
|
@ -29,16 +29,18 @@ use an intermediate redirecting file due to a bug in IE7.)
|
|||
Under Mac OS X, @scheme[send-url] runs @exec{osascript} to start the
|
||||
user's chosen browser.
|
||||
|
||||
Under Unix, @scheme[send-url] uses the value of the
|
||||
@scheme[external-browser] parameter to select a browser.
|
||||
Under Unix, @scheme[send-url] uses a user-preference, or when none is
|
||||
set, it will look for a known browser. See the description of
|
||||
@scheme[external-browser] for details.
|
||||
|
||||
The @scheme[url] string is usually escaped to avoid dangerous shell
|
||||
characters (quotations, dollar signs, backslashes, and non-ASCII).
|
||||
Note that it is a good idea to encode URLs before passing them to this
|
||||
function. Also note that the encoding is meant to make the URL work
|
||||
in shell quotes: URLs can still hold characters like @litchar{#},
|
||||
@litchar{?}, and @litchar{&}, so the @scheme[external-browser] should
|
||||
use quotations.}
|
||||
characters (quotations, dollar signs, backslashes, and non-ASCII). Note
|
||||
that it is a good idea to encode URLs before passing them to this
|
||||
function.
|
||||
|
||||
On all platforms, @scheme[external-browser] parameter can be set to a
|
||||
procedure to override the above behavior --- the procedure will be
|
||||
called with the @scheme[url] string.}
|
||||
|
||||
@defproc[(send-url/file [path path-string?] [separate-window? any/c #t]
|
||||
[#:fragment fragment (or/c string? false/c) #f]
|
||||
|
@ -71,20 +73,24 @@ old temporary files are still deleted as described above.}
|
|||
|
||||
@defparam[external-browser cmd browser-preference?]{
|
||||
|
||||
A parameter that, under Unix, determines the browser started
|
||||
@scheme[send-url].
|
||||
A parameter that can hold a procedure to override how a browser is
|
||||
started, or @scheme[#f] to use the default platform-dependent command.
|
||||
|
||||
The parameter is initialized to the value of the
|
||||
@scheme['external-browser] preference.
|
||||
Under Unix, the command that is used depends on the
|
||||
@scheme['external-browser] preference. If the preference is unset,
|
||||
@scheme[send-url] uses the first of the browsers from
|
||||
@scheme[unix-browser-list] for which the executable is found.
|
||||
Otherwise, the preference should hold a symbol indicating a known
|
||||
browser (from the @scheme[unix-browser-list]), or it a pair of a prefix
|
||||
and a suffix string that are concatenated around the @scheme[url] string
|
||||
to make up a shell command to run. In addition, the
|
||||
@scheme[external-browser] paremeter can be set to one of these values,
|
||||
and @scheme[send-url] will use it instead of the preference value.
|
||||
|
||||
The parameter value can be any of the symbols in
|
||||
@scheme[unix-browser-list], @scheme[#f] to indicate that the
|
||||
preference is unset, or a pair of strings. If the preference is
|
||||
unset, @scheme[send-url] uses the first of the browsers from
|
||||
@scheme[unix-browser-list] for which the executable is found. If the
|
||||
parameter is a pair of strings, then a command line is constructed by
|
||||
concatenating in order the first string, the URL string, and the
|
||||
second string.
|
||||
Note that the URL is encoded to make it work inside shell double-quotes:
|
||||
URLs can still hold characters like @litchar{#}, @litchar{?}, and
|
||||
@litchar{&}, so if the @scheme[external-browser] is set to a pair of
|
||||
prefix/suffix strings, they should use double quotes around the url.
|
||||
|
||||
If the preferred or default browser can't be launched,
|
||||
@scheme[send-url] fails. See @scheme[get-preference] and
|
||||
|
|
|
@ -2,7 +2,8 @@
|
|||
@(require scribble/manual
|
||||
scribble/bnf
|
||||
(for-label openssl
|
||||
scheme))
|
||||
scheme
|
||||
openssl/sha1))
|
||||
|
||||
@title{@bold{OpenSSL}}
|
||||
|
||||
|
@ -339,6 +340,35 @@ collection for testing purposes where the peer identifies itself using
|
|||
|
||||
@; ----------------------------------------------------------------------
|
||||
|
||||
@section{SHA-1 Hashing}
|
||||
|
||||
@defmodule[openssl/sha1]{The @schememodname[openssl/sha1] library
|
||||
provides a Racket wrapper for the OpenSSL library's SHA-1 hashing
|
||||
functions.}
|
||||
|
||||
@defproc[(sha1 [in input-port]) string?]{
|
||||
|
||||
Returns a 40-character string that represents the SHA-1 hash (in
|
||||
hexadecimal notation) of the content from @scheme[in], consuming all
|
||||
of the input from @scheme[in] until an end-of-file.
|
||||
|
||||
The @scheme[sha1] function composes @scheme[bytes->hex-string] with
|
||||
@racket[sha1-bytes].}
|
||||
|
||||
@defproc[(sha1-bytes [in input-port]) bytes?]{
|
||||
|
||||
Returns a 20-byte byte string that represents the SHA-1 hash of the
|
||||
content from @scheme[in], consuming all of the input from @scheme[in]
|
||||
until an end-of-file.}
|
||||
|
||||
@defproc[(bytes->hex-string [bstr bytes?]) string?]{
|
||||
|
||||
Converts the given byte string to a string representation, where each
|
||||
byte in @scheme[bstr] is converted to its two-digit hexadecimal
|
||||
representation in the resulting string.}
|
||||
|
||||
@; ----------------------------------------------------------------------
|
||||
|
||||
@section{Implementation Notes}
|
||||
|
||||
For Windows, @schememodname[openssl] relies on @filepath{libeay32.dll}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#lang setup/infotab
|
||||
|
||||
(define compile-omit-paths '("private-lex/error-tests.ss"))
|
||||
(define compile-omit-paths '("private-lex/error-tests.rkt"))
|
||||
|
||||
(define scribblings '(("parser-tools.scrbl" (multi-page) (parsing-library))))
|
||||
|
|
|
@ -77,7 +77,7 @@ the names documented in this library.
|
|||
The module @schememodname[redex/reduction-semantics]
|
||||
provides only the non-GUI portions of what is described in
|
||||
this manual (everything except the last two sections),
|
||||
making it suitable for use with @tt{mzscheme} scripts.
|
||||
making it suitable for use with @tt{racket} scripts.
|
||||
|
||||
@table-of-contents[]
|
||||
|
||||
|
@ -109,20 +109,20 @@ in the grammar are terminals.
|
|||
real
|
||||
string
|
||||
variable
|
||||
(variable-except <id> ...)
|
||||
(variable-prefix <id>)
|
||||
(variable-except id ...)
|
||||
(variable-prefix id)
|
||||
variable-not-otherwise-mentioned
|
||||
hole
|
||||
symbol
|
||||
(name <id> <pattern>)
|
||||
(in-hole <pattern> <pattern>)
|
||||
(hide-hole <pattern>)
|
||||
(side-condition <pattern> guard)
|
||||
(cross <id>)
|
||||
(name id pattern)
|
||||
(in-hole pattern pattern)
|
||||
(hide-hole pattern)
|
||||
(side-condition pattern guard)
|
||||
(cross id)
|
||||
(<pattern-sequence> ...)
|
||||
<scheme-constant>]
|
||||
racket-constant]
|
||||
[pattern-sequence
|
||||
<pattern>
|
||||
pattern
|
||||
(code:line ... (code:comment "literal ellipsis"))
|
||||
..._id])
|
||||
|
||||
|
@ -262,9 +262,9 @@ there via @tt{_} pattersn) are bound using @scheme[term-let] in the
|
|||
guard.
|
||||
}
|
||||
|
||||
@item{The @tt{(@defpattech[cross] symbol)} @pattern is used for the compatible
|
||||
@item{The @scheme[(@defpattech[cross] id)] @pattern is used for the compatible
|
||||
closure functions. If the language contains a non-terminal with the
|
||||
same name as @scheme[symbol], the @pattern @scheme[(cross symbol)] matches the
|
||||
same name as @scheme[symbol], the @pattern @scheme[(cross id)] matches the
|
||||
context that corresponds to the compatible closure of that
|
||||
non-terminal.
|
||||
}
|
||||
|
@ -395,7 +395,7 @@ all non-GUI portions of Redex) and also exported by
|
|||
@schememodname[redex] (which includes all of Redex).
|
||||
|
||||
Object language expressions in Redex are written using
|
||||
@scheme[term]. It is similar to Scheme's @scheme[quote] (in
|
||||
@scheme[term]. It is similar to Racket's @scheme[quote] (in
|
||||
many cases it is identical) in that it constructs lists as
|
||||
the visible representation of terms.
|
||||
|
||||
|
@ -405,14 +405,14 @@ stands for repetition unless otherwise indicated):
|
|||
@(schemegrammar* #:literals (in-hole hole unquote unquote-splicing)
|
||||
[term identifier
|
||||
(term-sequence ...)
|
||||
,scheme-expression
|
||||
,racket-expression
|
||||
(in-hole term term)
|
||||
hole
|
||||
#t #f
|
||||
string]
|
||||
[term-sequence
|
||||
term
|
||||
,@scheme-expression
|
||||
,@racket-expression
|
||||
(code:line ... (code:comment "literal ellipsis"))])
|
||||
|
||||
@itemize[
|
||||
|
@ -425,15 +425,15 @@ corresponding symbol, unless the identifier is bound by
|
|||
@item{A term written @scheme[(_term-sequence ...)] constructs a list of
|
||||
the terms constructed by the sequence elements.}
|
||||
|
||||
@item{A term written @scheme[,_scheme-expression] evaluates the
|
||||
@scheme[scheme-expression] and substitutes its value into the term at
|
||||
@item{A term written @scheme[,_racket-expression] evaluates the
|
||||
@scheme[_racket-expression] and substitutes its value into the term at
|
||||
that point.}
|
||||
|
||||
@item{A term written @scheme[,@_scheme-expression] evaluates the
|
||||
@scheme[scheme-expression], which must produce a list. It then splices
|
||||
@item{A term written @scheme[,@_racket-expression] evaluates the
|
||||
@scheme[_racket-expression], which must produce a list. It then splices
|
||||
the contents of the list into the expression at that point in the sequence.}
|
||||
|
||||
@item{A term written @scheme[(in-hole @|tttterm| @|tttterm|)]
|
||||
@item{A term written @scheme[(in-hole @#,|tttterm| @#,|tttterm|)]
|
||||
is the dual to the @pattern @scheme[in-hole] -- it accepts
|
||||
a context and an expression and uses @scheme[plug] to combine
|
||||
them.}
|
||||
|
@ -681,9 +681,9 @@ all non-GUI portions of Redex) and also exported by
|
|||
[reduction-case (--> @#,ttpattern @#,tttterm extras ...)]
|
||||
[extras name
|
||||
(fresh fresh-clause ...)
|
||||
(side-condition scheme-expression)
|
||||
(side-condition racket-expression)
|
||||
(where tl-pat @#,tttterm)
|
||||
(side-condition/hidden scheme-expression)
|
||||
(side-condition/hidden racket-expression)
|
||||
(where/hidden tl-pat @#,tttterm)]
|
||||
[fresh-clause var ((var1 ...) (var2 ...))]
|
||||
[tl-pat identifier (tl-pat-ele ...)]
|
||||
|
@ -722,7 +722,7 @@ bound by the left-hand side of the rule.
|
|||
All side-conditions provided with @scheme[side-condition] and
|
||||
@scheme[hidden-side-condition] are collected with @scheme[and] and
|
||||
used as guards on the case being matched. The argument to each
|
||||
side-condition should be a Scheme expression, and the pattern
|
||||
side-condition should be a Racket expression, and the pattern
|
||||
variables in the @|ttpattern| are bound in that expression. A
|
||||
@scheme[side-condition/hidden] form is the same as
|
||||
@scheme[side-condition], except that the side condition is not
|
||||
|
@ -901,8 +901,8 @@ all non-GUI portions of Redex) and also exported by
|
|||
...)
|
||||
([contract (code:line)
|
||||
(code:line id : @#,ttpattern ... -> @#,ttpattern)]
|
||||
[extras (side-condition scheme-expression)
|
||||
(side-condition/hidden scheme-expression)
|
||||
[extras (side-condition racket-expression)
|
||||
(side-condition/hidden racket-expression)
|
||||
(where tl-pat @#,tttterm)
|
||||
(where/hidden tl-pat @#,tttterm)]
|
||||
[tl-pat identifier (tl-pat-ele ...)]
|
||||
|
@ -1451,9 +1451,9 @@ filled in for the remaining colors.
|
|||
|
||||
The @scheme[scheme-colors?] argument, if @scheme[#t] causes
|
||||
@scheme[traces] to color the contents of each of the windows according
|
||||
to DrScheme's Scheme mode color Scheme. If it is @scheme[#f],
|
||||
to DrRacket's Racket mode color scheme. If it is @scheme[#f],
|
||||
@scheme[traces] just uses black for the color scheme.
|
||||
In addition, Scheme-mode parenthesis highlighting is
|
||||
In addition, Racket-mode parenthesis highlighting is
|
||||
enabled when @scheme[scheme-colors?]
|
||||
is @scheme[#t] and not when it is @scheme[#f].
|
||||
|
||||
|
@ -1698,7 +1698,7 @@ Slideshow (see
|
|||
|
||||
This section documents two classes of operations, one for
|
||||
direct use of creating postscript figures for use in papers
|
||||
and for use in DrScheme to easily adjust the typesetting:
|
||||
and for use in DrRacket to easily adjust the typesetting:
|
||||
@scheme[render-term],
|
||||
@scheme[render-language],
|
||||
@scheme[render-reduction-relation],
|
||||
|
@ -1808,7 +1808,7 @@ other tools that combine picts together.
|
|||
|
||||
If provided with one argument, @scheme[render-metafunction]
|
||||
produces a pict that renders properly in the definitions
|
||||
window in DrScheme. If given two arguments, it writes
|
||||
window in DrRacket. If given two arguments, it writes
|
||||
postscript into the file named by @scheme[filename] (which
|
||||
may be either a string or bytes).
|
||||
|
||||
|
@ -2071,12 +2071,12 @@ single reduction relation.
|
|||
@deftech{Removing the pink background from PLT Redex rendered picts and ps files}
|
||||
|
||||
When reduction rules, a metafunction, or a grammar contains
|
||||
unquoted Scheme code or side-conditions, they are rendered
|
||||
unquoted Racket code or side-conditions, they are rendered
|
||||
with a pink background as a guide to help find them and
|
||||
provide alternative typesettings for them. In general, a
|
||||
good goal for a PLT Redex program that you intend to typeset
|
||||
is to only include such things when they correspond to
|
||||
standard mathematical operations, and the Scheme code is an
|
||||
standard mathematical operations, and the Racket code is an
|
||||
implementation of those operations.
|
||||
|
||||
To replace the pink code, use:
|
||||
|
@ -2174,7 +2174,7 @@ explanation of logical-space):
|
|||
@defproc[(lw? (v any/c)) boolean?]{}
|
||||
@defidform[lw]{}]]{
|
||||
|
||||
The lw data structure corresponds represents a pattern or a Scheme
|
||||
The lw data structure corresponds represents a pattern or a Racket
|
||||
expression that is to be typeset. The functions listed above
|
||||
construct @scheme[lw] structs, select fields out of them, and
|
||||
recognize them. The @scheme[lw] binding can be used with
|
||||
|
|
|
@ -638,7 +638,7 @@
|
|||
;; the last round, and #f means no desc
|
||||
(define desc-order '(part mod libs delayed #f))
|
||||
;; this defines an imposed ordering for module names
|
||||
(define lib-order '(#rx"^scheme(?:/|$)" #rx"^r.rs(?:/|$)" #rx"^lang(?:/|$)"))
|
||||
(define lib-order '(#rx"^racket(?:/|$)" #rx"^r.rs(?:/|$)" #rx"^lang(?:/|$)"))
|
||||
(define (lib<? lib1 lib2)
|
||||
(define (lib-level lib)
|
||||
(let loop ([i 0] [rxs lib-order])
|
||||
|
|
|
@ -487,7 +487,7 @@
|
|||
(let ([i (cadr (syntax->list c))])
|
||||
(set! src-col (or (syntax-column i) src-col))
|
||||
(hash-set! next-col-map src-col dest-col)
|
||||
((loop init-line! (+ quote-depth quote-delta) expr? #f) i))))]
|
||||
((loop init-line! (max 0 (+ quote-depth quote-delta)) expr? #f) i))))]
|
||||
[(and (pair? (syntax-e c))
|
||||
(or (not expr?)
|
||||
(positive? quote-depth)
|
||||
|
|
|
@ -66,4 +66,6 @@
|
|||
(send pdf-bitmap save-file "../pdf.png" 'png)
|
||||
(send html-bitmap save-file "../html.png" 'png))
|
||||
|
||||
(send f show #t)
|
||||
(match (current-command-line-arguments)
|
||||
[(vector "skip") (void)]
|
||||
[_ (send f show #t)])
|
||||
|
|
|
@ -205,7 +205,7 @@ s-exp framework/keybinding-lang
|
|||
|
||||
The @racket[framework/keybinding-lang] languages provides all of the bindings
|
||||
from @racketmodname[racket], @racketmodname[racket/class], and
|
||||
@racketmodname[drscheme/tool-lib],
|
||||
@racketmodname[drracket/tool-lib],
|
||||
except that it adjusts @|mz-mod-begin| to
|
||||
introduce a @racketidfont{keybinding} form:
|
||||
|
||||
|
|
|
@ -34,8 +34,8 @@ determines how evaluation results are printed in the
|
|||
@tech{interactions window}. This setting also applies to output
|
||||
generated by calling @racket[print] explicitly.
|
||||
|
||||
The following table illustrates the difference between the different
|
||||
output styles:
|
||||
The @onscreen{print} style is the normal Racket output style. The
|
||||
following table illustrates the other output styles:
|
||||
|
||||
@print-table[
|
||||
[(cons 1 2) (cons 1 2) `(1 . 2) (1 . 2)]
|
||||
|
@ -54,30 +54,36 @@ output styles:
|
|||
[(regexp "a") (regexp "a") (regexp "a") #rx"a"]
|
||||
]
|
||||
|
||||
The @as-index{@onscreen{Constructor} output} mode treats
|
||||
@racket[cons], @racket[vector], and similar primitives as value
|
||||
constructors, rather than functions. It also treats @racket[list] as
|
||||
shorthand for multiple @racket[cons]'s ending with the empty list.
|
||||
@onscreen{Constructor} output is especially valuable for beginning
|
||||
programmers, because output values look the same as input values.
|
||||
The @as-index{@onscreen{Constructor} output} mode is similar to
|
||||
Rackets normal print mode, except that even quotable are still printed
|
||||
with constructors, constructor functions and forms are used to
|
||||
approximate some otherwise unprintable values. For example,
|
||||
@onscreen{Constructor} output prints a procedure in a
|
||||
@racketresult[lambda] form. For output to a graphical context,
|
||||
rational numbers are printed using a special @racket[snip%] object
|
||||
that lets the user choose between improper fractions, mixed fractions,
|
||||
and repeating decimals.
|
||||
|
||||
The @as-index{@onscreen{Quasiquote} output} mode is like
|
||||
@onscreen{Constructor} output, but it uses @racket[quasiquote]
|
||||
(abbreviated with @litchar{`}) to print lists, and it uses
|
||||
@racket[unquote] (abbreviated with @litchar{,}) to escape back to
|
||||
@onscreen{Constructor} printing as needed. This mode provides the same
|
||||
benefit as @onscreen{Constructor} output, in that printed results are
|
||||
expressions, but it is more convenient for many kinds of data,
|
||||
especially data that represents expressions.
|
||||
@onscreen{Constructor} printing as needed.
|
||||
|
||||
The @as-index{@onscreen{write} output} mode corresponds to traditional
|
||||
Scheme printing via the @racket[print] procedure, which defaults to
|
||||
@racket[write]-like printing, as shown in the last column.
|
||||
Scheme printing via the @racket[write] procedure. For example, lists
|
||||
print by parenthesizing the printed form of the list elements, without
|
||||
a leading quote mark or a constructor name.
|
||||
|
||||
DrRacket also sets the @racket[global-port-print-handler] in order to
|
||||
customize a few aspects of the printing for all of these modes, namely
|
||||
printing the symbol @racket[quote] as a single tick mark (mutatis
|
||||
mutandis for @racket[quasiquote], @racket[unquote], and
|
||||
@racket[unquote-splicing]), and to print rational real numbers using a
|
||||
special @racket[snip%] object that lets the user choose between
|
||||
improper fractions, mixed fractions, and repeating decimals.
|
||||
Finally, the @as-index{@onscreen{print} output} mode corresponds to
|
||||
Racket's default printing via the @racket[print] procedure. Output via
|
||||
@racket[print] is further configurable through run-time settings, such
|
||||
as the @racket[print-as-expression] parameter, and it may be adjusted
|
||||
by a @hash-lang[]-specified language. For example, the
|
||||
@racketmodname[scheme] language sets the @racket[print-as-expression]
|
||||
parameter to @racket[#f], which essentially makes @onscreen{print}
|
||||
mode act like @onscreen{write} mode.
|
||||
|
||||
For any of the output styles, DrRacket sets the
|
||||
@racket[global-port-print-handler] so that the @racket[print]
|
||||
procedure produces output as selected.
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
@defproc[(end-atomic) void?]
|
||||
)]{
|
||||
|
||||
Disables and enables context switches at the level of Scheme
|
||||
Disables and enables context switches at the level of Racket
|
||||
threads. Calls to @scheme[start-atomic] and @scheme[end-atomic] can be
|
||||
nested.
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ operations manage tags to distinguish pointer types.
|
|||
ctype])]{
|
||||
|
||||
Construct a kind of a pointer that gets a specific tag when converted
|
||||
to Scheme, and accept only such tagged pointers when going to C. An
|
||||
to Racket, and accept only such tagged pointers when going to C. An
|
||||
optional @scheme[ptr-type] can be given to be used as the base pointer
|
||||
type, instead of @scheme[_pointer].
|
||||
|
||||
|
@ -37,7 +37,7 @@ an interface can hide its value from users (e.g., not provide the
|
|||
|
||||
@scheme[_cpointer/null] is similar to @scheme[_cpointer] except that
|
||||
it tolerates @cpp{NULL} pointers both going to C and back. Note that
|
||||
@cpp{NULL} pointers are represented as @scheme[#f] in Scheme, so they
|
||||
@cpp{NULL} pointers are represented as @scheme[#f] in Racket, so they
|
||||
are not tagged.}
|
||||
|
||||
|
||||
|
@ -63,7 +63,7 @@ obtain a tag. The tag is the string form of @schemevarfont{id}.}
|
|||
|
||||
These two functions treat pointer tags as lists of tags. As described
|
||||
in @secref["foreign:pointer-funcs"], a pointer tag does not have any
|
||||
role, except for Scheme code that uses it to distinguish pointers;
|
||||
role, except for Racket code that uses it to distinguish pointers;
|
||||
these functions treat the tag value as a list of tags, which makes it
|
||||
possible to construct pointer types that can be treated as other
|
||||
pointer types, mainly for implementing inheritance via upcasts (when a
|
||||
|
|
|
@ -17,9 +17,9 @@ pointer to a memory block).
|
|||
|
||||
Like @scheme[_bytes], @scheme[_cvector] can be used as a simple type
|
||||
that corresponds to a pointer that is managed as a safe C vector on
|
||||
the Scheme side. The longer form behaves similarly to the
|
||||
the Racket side. The longer form behaves similarly to the
|
||||
@scheme[_list] and @scheme[_vector] custom types, except that
|
||||
@scheme[_cvector] is more efficient; no Scheme list or vector is
|
||||
@scheme[_cvector] is more efficient; no Racket list or vector is
|
||||
needed.}
|
||||
|
||||
@defproc[(make-cvector [type ctype?][length exact-nonnegative-integer?]) cvector?]{
|
||||
|
|
|
@ -68,7 +68,7 @@ Looks for the given object name @scheme[objname] in the given
|
|||
@scheme[lib] library. If @scheme[lib] is not a foreign-library value
|
||||
produced by @scheme[ffi-lib], it is converted to one by calling
|
||||
@scheme[ffi-lib]. If @scheme[objname] is found in @scheme[lib], it is
|
||||
converted to Scheme using the given @scheme[type]. Types are described
|
||||
converted to Racket using the given @scheme[type]. Types are described
|
||||
in @secref["types"]; in particular the @scheme[get-ffi-obj] procedure
|
||||
is most often used with function types created with @scheme[_fun].
|
||||
|
||||
|
@ -101,7 +101,7 @@ Looks for @scheme[objname] in @scheme[lib] similarly to
|
|||
@scheme[get-ffi-obj], but then it stores the given @scheme[new] value
|
||||
into the library, converting it to a C value. This can be used for
|
||||
setting library customization variables that are part of its
|
||||
interface, including Scheme callbacks.}
|
||||
interface, including Racket callbacks.}
|
||||
|
||||
|
||||
@defproc[(make-c-parameter [objname (or/c string? bytes? symbol?)]
|
||||
|
@ -114,7 +114,7 @@ Returns a parameter-like procedure that can either references the
|
|||
specified foreign value, or set it. The arguments are handled as in
|
||||
@scheme[get-ffi-obj].
|
||||
|
||||
A parameter-like function is useful in case Scheme code and library
|
||||
A parameter-like function is useful in case Racket code and library
|
||||
code interact through a library value. Although
|
||||
@scheme[make-c-parameter] can be used with any time, it is not
|
||||
recommended to use this for foreign functions, since each reference
|
||||
|
@ -124,9 +124,9 @@ actual call.}
|
|||
|
||||
@defform[(define-c id lib-expr type-expr)]{
|
||||
|
||||
Defines @scheme[id] behave like a Scheme binding, but @scheme[id] is
|
||||
Defines @scheme[id] behave like a Racket binding, but @scheme[id] is
|
||||
actually redirected through a parameter-like procedure created by
|
||||
@scheme[make-c-parameter]. The @scheme[id] is used both for the Scheme
|
||||
@scheme[make-c-parameter]. The @scheme[id] is used both for the Racket
|
||||
binding and for the foreign object's name.}
|
||||
|
||||
@defproc[(ffi-obj-ref [objname (or/c string? bytes? symbol?)]
|
||||
|
|
|
@ -20,7 +20,7 @@ for cases where the regular expression begins with a @litchar{^} or
|
|||
ends with a @litchar{$}, in which case @scheme[regexp-replace] is
|
||||
used.
|
||||
|
||||
For example, the following makes it convenient to define Scheme
|
||||
For example, the following makes it convenient to define Racket
|
||||
bindings such as @scheme[foo-bar] for foreign names like
|
||||
@scheme[MyLib_foo_bar]:
|
||||
|
||||
|
@ -48,7 +48,7 @@ according to the given @scheme[type].}
|
|||
|
||||
@defproc[(vector->cblock [vec vector?][type type?]) any]{
|
||||
|
||||
Like @scheme[list->cblock], but for Scheme vectors.}
|
||||
Like @scheme[list->cblock], but for Racket vectors.}
|
||||
|
||||
|
||||
@defproc[(vector->cpointer [vec vector?]) cpointer?]{
|
||||
|
@ -93,7 +93,7 @@ The conversion is equivalent to
|
|||
list?]{
|
||||
|
||||
Converts C @scheme[cblock], which is a vector of @scheme[type]s, to a
|
||||
Scheme list. The arguments are the same as in the
|
||||
Racket list. The arguments are the same as in the
|
||||
@scheme[list->cblock]. The @scheme[length] must be specified because
|
||||
there is no way to know where the block ends.}
|
||||
|
||||
|
@ -101,4 +101,4 @@ there is no way to know where the block ends.}
|
|||
@defproc[(cblock->vector [cblock any/c][type ctype?][length exact-nonnegative-integer?])
|
||||
vector?]{
|
||||
|
||||
Like @scheme[cblock->vector], but for Scheme vectors.}
|
||||
Like @scheme[cblock->vector], but for Racket vectors.}
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user