Big newline at EOF scan.

This commit is contained in:
Eli Barzilay 2012-02-29 00:28:11 -05:00
parent 0243b50368
commit f7c67b49a4
87 changed files with 105 additions and 145 deletions

View File

@ -15,4 +15,4 @@
(apply launch-many-worlds/proc
(build-list 20 (lambda (x) (lambda () (aworld (+ 10 x) (make-color 255 255 x)))))))
(main)
(main)

View File

@ -6,4 +6,3 @@
(on-tick (lambda (w) (make-bundle (add1 w) '() '())) 1/28 3)
(on-msg void)
(on-new cons))

View File

@ -5,4 +5,3 @@
(big-bang 0
(on-tick add1 1/28 3)
(to-draw (lambda (w) (circle (- 100 w) 'solid 'red))))

View File

@ -15,4 +15,4 @@
(big-bang 0+0i
(to-draw render)
(on-tick add1-i 1/28 50)
(on-pad (pad-handler (up sub1-i) (down add1-i) (left sub1) (right add1))))
(on-pad (pad-handler (up sub1-i) (down add1-i) (left sub1) (right add1))))

View File

@ -45,4 +45,4 @@
(require 'server)
(require 'client)
(require 'client)

View File

@ -59,4 +59,4 @@
(overlay (text (number->string w) 22 c) (empty-scene 100 100))))
;; run universe run
(main 1 3)
(main 1 3)

View File

@ -34,4 +34,4 @@
(provide/contract
[write-theory (-> theory/c void)]
[read-theory (-> theory/c)])
[read-theory (-> theory/c)])

View File

@ -41,4 +41,4 @@
set-syncheck-mode
get-syncheck-mode
update-menu-status)
update-menu-status)

View File

@ -90,4 +90,4 @@
(define/public (get-length) all-completions-length)
(define/public (empty?) (eq? (get-length) 0))
(super-new)))
(super-new)))

View File

@ -1474,4 +1474,3 @@
(if (< start-pos click-pos)
(f click-pos eol start-pos click-pos)
(f click-pos eol click-pos end-pos))))

View File

@ -161,4 +161,4 @@
[(8) "eighth"]
[(9) "ninth"]
[(10) "tenth"]
[else (number->ord arg-posn)])]))
[else (number->ord arg-posn)])]))

View File

@ -151,4 +151,4 @@
(raise (exn:fail:filesystem
(string-append (format "~a: " sym)
(apply format fmt args))
(current-continuation-marks))))
(current-continuation-marks))))

View File

@ -5,4 +5,4 @@
(define-unit-from-context cookie@ cookie^)
(provide cookie@)
(provide cookie@)

View File

@ -462,4 +462,4 @@ pic:bloch
(clip-picture-colors 240 pic:bloch)
(clip-picture-colors 200 pic:bloch)
(clip-picture-colors 150 pic:bloch)
(clip-picture-colors 100 pic:bloch)
(clip-picture-colors 100 pic:bloch)

View File

@ -34,4 +34,4 @@
(check-error (rotate-ccw true)
"rotate-ccw: expected <image> as first argument, given: true")
(check-error (rotate-180 "goodbye")
"rotate-180: expected <image> as first argument, given: \"goodbye\"")
"rotate-180: expected <image> as first argument, given: \"goodbye\"")

View File

@ -172,4 +172,4 @@
(map
(lambda (x) (cons (car x) (map (lambda (y) (drop-last (cadr y))) (cdr x))))
buckets)))
|#
|#

View File

@ -703,4 +703,4 @@ This function is called by PLaneT to announce when things are happening. See als
@defproc[(get-planet-cache-path) (and/c path? absolute-path?)]{
Returns the path to the @filepath{cache.rktd} file for the planet installation.
}
}

View File

@ -928,4 +928,4 @@
(atomically
(when s
(cairo_surface_destroy s)
(set! s #f))))))
(set! s #f))))))

View File

@ -15,4 +15,4 @@
(raise-syntax-error #f "bad syntax" stx)
(datum->syntax stx (cdr (syntax-e stx)) stx stx))))
(#%provide (all-from '#%kernel) #%top-interaction))
(#%provide (all-from '#%kernel) #%top-interaction))

View File

@ -78,4 +78,4 @@
(syntax-case stx ()
[(_ val comp)
#'(? (lambda (x) (comp val x)))]
[(_ val) #'(? (lambda (x) (equal? val x)))])))
[(_ val) #'(? (lambda (x) (equal? val x)))])))

View File

@ -12,6 +12,3 @@
[(a) a]
[(a b) a]
[(a b c) a])])))

View File

@ -96,4 +96,4 @@
(test-equal (term (does-not-bind? (letrec ([x x] [y hole] [z z]) y) z)) #f)
(test-equal (term (does-not-bind? (letrec ([x x] [y hole] [z z]) y) a)) #t)
(test-equal (term (does-not-bind? (letrec ([x x]) (letrec ([y y]) hole)) y)) #f)
(test-equal (term (does-not-bind? (letrec ([x x]) (letrec ([y hole]) y)) y)) #f)
(test-equal (term (does-not-bind? (letrec ([x x]) (letrec ([y hole]) y)) y)) #f)

View File

@ -5,4 +5,4 @@
"CMT-test.rkt"
redex/reduction-semantics)
(test-results)
(test-results)

View File

@ -86,4 +86,4 @@
(term 2))
(test-->> reduction
(term (((λ (x) (λ (y) (x y))) (λ (z) z)) 1))
(term 1))
(term 1))

View File

@ -135,4 +135,4 @@
(judgment-holds (small-step e_1 e_2)))))
(define (trace-λv expr)
(traces small-step-rr expr))
(traces small-step-rr expr))

View File

@ -109,4 +109,4 @@
(['typeof rewrite-typeof]
['extend rewrite-extend]
['lookup rewrite-lookup])
(render-judgment-form typeof))
(render-judgment-form typeof))

View File

@ -46,4 +46,4 @@
(format
"found a cycle that includes the non-terminal ~a"
cycle)
stx)))
stx)))

View File

@ -14,4 +14,4 @@
(thunk)))
(define (report-undefined name desc)
(redex-error #f "reference to ~a ~s before its definition" desc name))
(redex-error #f "reference to ~a ~s before its definition" desc name))

View File

@ -128,4 +128,3 @@ turns into this:
(car should-be-pats))
stx))
#'(match to-match [pats rhs ...] ...))]))

View File

@ -38,4 +38,4 @@
(define (not-expression-context stx)
(when (eq? (syntax-local-context) 'expression)
(raise-syntax-error #f "not allowed in an expression context" stx)))
(raise-syntax-error #f "not allowed in an expression context" stx)))

View File

@ -63,4 +63,4 @@
#:volume 9
#:number "4"
#:pages '(244 257))
#:date "1970"))
#:date "1970"))

View File

@ -179,4 +179,4 @@
(test (send annotations collected-rename-class use-name)
(expected-rename-class (list def-name use-name))))
(print-tests-passed 'check-syntax-test.rkt)
(print-tests-passed 'check-syntax-test.rkt)

View File

@ -21,4 +21,4 @@
(define x 4)
(print-tests-passed 'defined-checks-test.rkt)
(print-tests-passed 'defined-checks-test.rkt)

View File

@ -9,4 +9,4 @@
(judgment-holds judgment))
(#rx"output q at position 2"
([judgment (ctc-fail c s)])
(judgment-holds judgment))
(judgment-holds judgment))

View File

@ -7,4 +7,4 @@
#:mode (name I)
[(name (binder1 ellipsis binder2 ellipsis))
premise])
(judgment-holds (name (1 2)))))
(judgment-holds (name (1 2)))))

View File

@ -6,4 +6,4 @@
(define-judgment-form L
#:mode (def I)
[(def 1)])
#f))
#f))

View File

@ -5,4 +5,4 @@
(define-language L)
(define-metafunction L
[(def) ()])
#f))
#f))

View File

@ -46,4 +46,4 @@
(let ()
(define t (term (use y)))
(define-term def z)
t))
t))

View File

@ -206,4 +206,4 @@
[(K a any_1 x)
(K b (use) (name inner-def any))]
[(K b any K-b-out)])
(void)))
(void)))

View File

@ -9,4 +9,4 @@
(define-judgment-form syn-err-lang
#:mode (name I)
[(name a)])
(judgment-holds bad-judgment)))
(judgment-holds bad-judgment)))

View File

@ -44,4 +44,4 @@
(-e any))
(define-language L2
(e any))
(define-union-language L L1r L2r)))
(define-union-language L L1r L2r)))

View File

@ -17,4 +17,4 @@
(define-metafunction not-id also-junk))
(#rx"expected an identifier"
([not-id junk])
(define-metafunction not-id also-junk))
(define-metafunction not-id also-junk))

View File

@ -1,3 +1,3 @@
(#rx"redex-let: duplicate pattern variable"
([dup number])
(redex-let syn-err-lang ([(dup) 1] [dup 1]) (term dup)))
(redex-let syn-err-lang ([(dup) 1] [dup 1]) (term dup)))

View File

@ -135,4 +135,4 @@
(reduction-relation
syn-err-lang
(--> 1 1
(judgment-holds bad-judgment)))))
(judgment-holds bad-judgment)))))

View File

@ -5,4 +5,4 @@
(#rx"too few ellipses"
([bound x]) ([bind x])
(... (term-let ([((bind ...) ...) '()])
(term (bound ...)))))
(term (bound ...)))))

View File

@ -686,4 +686,4 @@ Different kinds of bitmaps can produce different results:
when consistency with screen drawing is needed for some other
reason.}
]
]

View File

@ -280,12 +280,12 @@ Returns @racket[(not v)].}
(implies #f #f)
(implies #t #f)
(implies #f (error 'ack "we don't get here"))]
}
@defproc[(xor [b1 any/c] [b2 any/c]) any]{
Returns the exclusive or of @racket[b1] and @racket[b2].
If exactly one of @racket[b1] and @racket[b2] is
not @racket[#f], then return it. Otherwise, returns
@racket[#f].
@ -296,5 +296,5 @@ Returns @racket[(not v)].}
(xor #f 22)
(xor 11 22)
(xor #f #f)]
}
}

View File

@ -45,4 +45,4 @@ for the @racketmodname[racket/base] language.
is a minimal initial environment intended for scripts that require low
startup time. It re-exports the bindings of the
@indexed-racket['#%kernel], along with a binding for
@racket[#%top-interaction].}
@racket[#%top-interaction].}

View File

@ -97,4 +97,4 @@ to delegate to the scheme-lexer (in the 'no-lang-line mode).
(define (set-port-next-location-from src dest)
(define-values (line col pos) (port-next-location src))
(set-port-next-location! dest line col pos))
(set-port-next-location! dest line col pos))

View File

@ -1,4 +1,4 @@
#lang datalog
friend(arnold,arnold).
student(arnold,arnold,arnold) :- friend(arnold,arnold).
student(arnold,arnold,arnold)?
student(arnold,arnold,arnold)?

View File

@ -102,4 +102,4 @@ in let
t4m = proc (f) proc(x) if zero?(x) then 0 else -((f -(x,1)),-4)
in let times4 = (fix t4m)
in (times4 3)" 12)
)
)

View File

@ -102,4 +102,4 @@ in let
in let times4 = (fix t4m)
in (times4 3)" 12)
)
)

View File

@ -196,4 +196,4 @@ in -((g 22), (g 22))"
in -((g 22), (g 22))"
-1)
)
)

View File

@ -263,4 +263,4 @@ in begin
end"
44)
)
)

View File

@ -190,4 +190,4 @@ in begin
end"
11)
)
)

View File

@ -162,4 +162,4 @@ let f = proc (x) proc (y)
in ((f 44) 33)"
12)
)
)

View File

@ -9097,4 +9097,4 @@ lecture09/exceptions/interp.scm 15-Mar-06
#(struct:end-cont))
|(apply-cont #(struct:end-cont) #(struct:num-val -1))
|#(struct:num-val -1)
>
>

View File

@ -134,4 +134,4 @@ in let times4 = (fix t4m)
in letrec odd(x) = if zero?(x) then 0 else ((even odd) -(x,1))
in (odd 13)" 1)
)
)

View File

@ -183,4 +183,4 @@ in let times4 = (fix t4m)
in +((fib 1), 12, (fib 5))"
21)
)
)

View File

@ -236,4 +236,4 @@
proc (y) -(x,y))))"
-1)
)
)

View File

@ -237,4 +237,4 @@ in let f = proc (z) let zz = newref(-(z,deref(x))) in deref(zz)
in -((f 66), (f 55))"
11)
)
)

View File

@ -357,4 +357,4 @@ in fact"
"letrec ? f (x : ?) = (f x) in proc (n : ?) (f -(n,1))"
(int -> tvar01))
)
)

View File

@ -973,9 +973,3 @@ from m2 take foo"
)

View File

@ -44,4 +44,4 @@
((and (pair? x) (pair? y)
(= (length x) (length y))
(map foo x y))
(else '**))))
(else '**))))

View File

@ -1636,9 +1636,3 @@ from m2 take foo"
)

View File

@ -334,9 +334,3 @@ module m
)

View File

@ -755,14 +755,4 @@ We should also test deep continuations.
(run-tests future)
(run-tests would-be-future)
;; ----------------------------------------
;; ----------------------------------------

View File

@ -3,4 +3,4 @@
(define-struct a (b))
(match (make-a 1)
[(struct a (b)) b]
[#f 3])
[#f 3])

View File

@ -8,4 +8,4 @@
;; The body of this function should be the only red in the file
(define (f x)
(+ 1 1))
(+ 1 1))

View File

@ -11,4 +11,4 @@
(define (f x)
(cond* x
[(string? x) #t]
[(exact-nonnegative-integer? x) #f]))
[(exact-nonnegative-integer? x) #f]))

View File

@ -13,4 +13,4 @@
(ann (match pi
[(list n) 'success]
[other 'failure])
(U #;'success 'failure)))
(U #;'success 'failure)))

View File

@ -15,4 +15,4 @@
(add1 (f 0))
(add1 (f))
(add1 (f))

View File

@ -4,4 +4,4 @@
(unless (equal? (parameter? current-directory)
(if (parameter? current-directory) #t #f))
(error 'unsound!))
(error 'unsound!))

View File

@ -123,4 +123,4 @@
(define-go typecheck-special-tests)
(provide typecheck-special-tests)
(provide typecheck-special-tests)

View File

@ -19,4 +19,4 @@
(serve/servlet app-dispatch
#:port 8000
#:servlet-regexp #rx""
#:command-line? #t)
#:command-line? #t)

View File

@ -77,4 +77,4 @@
(get-post-data/raw "hello=world") #"hello=world")
(test-equal? "simple test 3"
(binding:form-value (bindings-assq #"hello" (force (get-bindings "hello=world"))))
#"world")))))
#"world")))))

View File

@ -87,4 +87,4 @@
(test-case "double-counters"
(test-double-counters
(make-servlet-tester ex:double:start)))))
(provide test-tests)
(provide test-tests)

View File

@ -30,4 +30,4 @@
(se-path* '(p) '(html (body (p "Hey"))))
=> "Hey"
(se-path* '(p #:bar) '(html (body (p ([bar "Zog"]) "Hey"))))
=> "Zog")
=> "Zog")

View File

@ -57,4 +57,3 @@
(provide convert convertible?)
(provide/contract
[prop:convertible (struct-type-property/c (-> convertible? pict?))])

View File

@ -20,4 +20,4 @@
#:attr mapping (dict-set (make-immutable-free-id-table) #'e.i #'x)
#:attr flag-mapping (if (attribute e.j)
(dict-set (make-immutable-free-id-table) #'e.i #'e.j)
(make-immutable-free-id-table))))
(make-immutable-free-id-table))))

View File

@ -12,4 +12,4 @@
[find-seconds (case-> (Integer Integer Integer Integer Integer Integer -> Integer)
(Integer Integer Integer Integer Integer Integer Any -> Integer))]
[date->julian/scalinger (date -> Integer)]
[julian/scalinger->string (Integer -> String)])
[julian/scalinger->string (Integer -> String)])

View File

@ -74,4 +74,4 @@ example that tests an Add-Two-Numbers.com:
(make-servlet-tester ex:add1:start))
(test-add-two-numbers
(make-servlet-tester ex:add2:start))
]
]

View File

@ -1410,4 +1410,4 @@ to be useful. There are interfaces to other databases, many tools for generating
output in HTML, XML, Javascript, etc.
There is also an active community of users on the Racket mailing list. We
welcome new users!
welcome new users!

View File

@ -78,4 +78,4 @@
[se-path*/list
(-> se-path? xexpr?
; XXX see above
(listof any/c))])
(listof any/c))])

View File

@ -8,7 +8,6 @@
(define url-base (string-append "http://" url-host url-path))
(define architecture #f) ;; set in `do-download'
(define (delete-path path)
(cond [(directory-exists? path)
(parameterize ([current-directory path])
@ -61,7 +60,6 @@
"size of ~a is ~a; doesn't match expected size ~a"
file sz size)))
(define (unpack-tgz tgz)
(printf " unpacking...") (flush-output)
(define-values [p pout pin perr]
@ -77,7 +75,6 @@
(raise-user-error 'get-libs "don't know how to install file: ~a"
file)]))
(define (do-download needed really-needed arch)
(set! architecture arch)
(printf ">> Downloading files from\n>> ~a~a\n" url-base architecture)
@ -95,4 +92,4 @@
(delete-path (caddr file+size))
(install file))
(printf " done.\n"))
(printf " already exists.\n"))))
(printf " already exists.\n"))))

View File

@ -1,16 +1,16 @@
;; This program avoids is written in #%kernel and
;; This program is written in #%kernel and
;; dynamic-requires the real downloading,
;; because it is loaded without using bytecode.
(module get-libs '#%kernel
(#%require '#%paramz (for-syntax '#%kernel))
(#%provide all-files+sizes)
(define-values (all-files+sizes)
;; alist mapping package to
;; alist mapping architecture to
;; a list of entries, each has filename and size
;; and optionally a path that it would install to and the installed size
(list
(list
;; Core Libraries
'[core
[win32/i386
@ -22,7 +22,7 @@
["libeay32.dll" 1503232]
["ssleay32.dll" 309760]]]
;; GUI Libraries
[list
[list
'gui
'[i386-macosx
["libcairo.2.dylib" 802620]
@ -69,7 +69,7 @@
["libgthread-2.0.0.dylib" 25068]
["libpng15.15.dylib" 570228]
["PSMTabBarControl.tgz" 96039 "PSMTabBarControl.framework" 229501]]
(append
(append
'[win32/i386
["libjpeg-7.dll" 233192]
["libcairo-2.dll" 921369]
@ -123,27 +123,27 @@
["myssink.dll" 92672]]
[win32/x86_64
["myssink.dll" 108032]]]))
(define-values [package dest-dir]
(let-values ([(args) (vector->list (current-command-line-arguments))])
(let-values
([(package) (if (null? args)
(error 'get-libs "missing \'package\' command-line argument")
(car args))])
(let-values ([(dd)
(error 'get-libs "missing \'package\' command-line argument")
(car args))])
(let-values ([(dd)
(if (null? (cdr args)) (current-directory) (cadr args))])
(values (string->symbol package) dd)))))
(define-values (unixize)
(lambda (p)
(let-values ([(base name dir?) (split-path p)])
(if (path? base)
(string-append (unixize base) "/" (path->string name))
(path->string name)))))
(define-values (architecture)
(string->symbol (unixize (system-library-subpath #f))))
(define-values (needed-files+sizes)
(lambda ()
(define-values (l) (assq package all-files+sizes))
@ -156,30 +156,29 @@
(if arch
(cdr arch)
'())))
(define-values (directory-size)
(lambda (dir)
(define-values (loop)
(lambda (l)
(if (null? l)
0
(+ (path-size (build-path dir (car l))) (loop (cdr l))))))
(if (null? l)
0
(+ (path-size (build-path dir (car l))) (loop (cdr l))))))
(loop (directory-list dir))))
(define-values (path-size)
(lambda (path)
(if (file-exists? path) (file-size path)
(if (directory-exists? path)
(if (directory-exists? path)
(directory-size path)
0))))
(define-values (got-path?) ; approximate, using size
(case-lambda [(path size unpacked-path unpacked-size)
(got-path? unpacked-path unpacked-size)]
[(path size)
(equal? size (path-size path))]))
;; not provided by #%kernel
(define-values (filter)
(lambda (f l)
@ -188,9 +187,9 @@
(if (f (car l))
(cons (car l) (filter f (cdr l)))
(filter f (cdr l))))))
(define-syntaxes (here-dir)
(λ (stx)
(λ (stx)
(define-values (base name dir?) (split-path (syntax-source stx)))
(datum->syntax (quote-syntax 'here) base)))
@ -204,7 +203,7 @@
current-directory dest-dir)
(let-values ()
(define-values (needed) (needed-files+sizes))
(define-values (really-needed)
(define-values (really-needed)
(filter (λ (n) (not (apply got-path? n))) needed))
(printf (if (null? needed)
">> No ~a libraries to download for ~a\n"
@ -212,7 +211,7 @@
package architecture)
(if (null? needed)
(void)
(if (null? really-needed)
(if (null? really-needed)
(printf ">> All files present, no downloads needed.\n")
((dynamic-require (build-path here-dir "download-libs.rkt") 'do-download)
needed really-needed architecture))))))))
needed really-needed architecture))))))))

View File

@ -3,4 +3,4 @@
/myssink_p.c
/myssink.tlb
/myssink.res
/dlldata.c
/dlldata.c