From yinso.chen at gmail.com Fri Aug 1 03:03:18 2008 From: yinso.chen at gmail.com (YC) Date: Thu Mar 26 02:24:45 2009 Subject: [plt-scheme] get the list of modules in a namespace In-Reply-To: <18577.7161.596847.381735@arabic.ccs.neu.edu> References: <779bf2730807301525g768d544aof2738aff70f2776a@mail.gmail.com> <18577.7161.596847.381735@arabic.ccs.neu.edu> Message-ID: <779bf2730808010003o4cc1923bucbb1a77b7ac0c743@mail.gmail.com> On Wed, Jul 30, 2008 at 6:57 PM, Eli Barzilay wrote: > > Seems like there is only `namespace-module-registry', which returns a > value that you can't really use for anything (see the docs). But I > think that to merge two namespaces you'll need to scan the bindings > from each one and create the appropriate bindings in the result, and > `identifier-binding' is what is needed for doing this. > Thanks Eli. I got from identifier-binding to resolved-module-path, and was able to get quite a bit to work, except the following issues: 1. namespace-require does not work with built-in modules such as %network 2. namespace-require also does not work with top-level modules such as 'cake 3. top-level bindings requires a different approach Lastly - it appears expensive to having to loop through all bindings... hopefully something like namespace-module-registry can offer more in the future? ;) Below is what I've got in case anyone is interested... ;; retrieve the module binding by sym and namespace (define (get-module-binding sym (ns (current-namespace))) (parameterize ((current-namespace ns)) (identifier-binding (namespace-symbol->identifier sym)))) ;; retrieve the module path (resolved) by sym and namespace (define (get-module-path sym (ns (current-namespace))) (parameterize ((current-namespace ns)) (let ((binding (get-module-binding sym ns))) (cond ((or (eq? binding #f) (equal? binding 'lexical)) binding) (else (resolved-module-path-name (module-path-index-resolve (car binding)))))))) ;; filters duplicates in a list. (define (list->unique-list lst) (define (helper rest acc) (cond ((null? rest) (reverse acc)) (else (if (member (car rest) acc) (helper (cdr rest) acc) (helper (cdr rest) (cons (car rest) acc)))))) (helper lst '())) ;; turn the symbols into module path and filter dupes. (define (namespace->module-paths (ns (current-namespace))) (list->unique-list (map (lambda (sym) (get-module-path sym ns)) (namespace-mapped-symbols ns)))) ;; compare two module paths and return the differences (one way) (define (namespace-module-paths-diff from-ns to-ns) (let ((from-paths (namespace->module-paths from-ns)) (to-paths (namespace->module-paths to-ns))) (filter (lambda (p) (not (member p to-paths))) from-paths))) ;; take the diffs in module paths and require them. (define (namespace-merge from-ns to-ns) (let ((ns-paths (namespace-module-paths-diff from-ns to-ns))) (parameterize ((current-namespace to-ns)) (for-each (lambda (path) (when path ;; doesn't work with #%network or top-level modules (namespace-require path))) ns-paths)))) ;; examples... (define ns (make-base-namespace)) ;; current-namespace in top-level is scheme. will choke on #%network for now. (namespace-merge (current-namespace) ns) -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080801/33772b9a/attachment.html From stephen at degabrielle.name Fri Aug 1 03:28:44 2008 From: stephen at degabrielle.name (Stephen De Gabrielle) Date: Thu Mar 26 02:24:48 2009 Subject: [plt-scheme] A guide for the PLT GUI Application Framework? In-Reply-To: <003301c8f37c$f20ea740$4001a8c0@BLACKIRON> References: <003301c8f37c$f20ea740$4001a8c0@BLACKIRON> Message-ID: <595b9ab20808010028i54c6f2f8p2315b7a7afabe19@mail.gmail.com> I find the scheme cookbook section on gui informative, and I do my best to add to it as I work stuff out. Once you get little more confident the reading the source code for DrScheme and framework collections can be useful too. Sorry this doesn't really answer your question. On the bright side - the list is really friendly, so don't be afraid to ask a dumb question (I do all the time). Stephen On Fri, Aug 1, 2008 at 3:18 AM, Peter Schlaifer wrote: > Like Gregory's question about A Web Guide - the PLT doc is > purely a reference and tracing out what DrScheme does is heavy > going, at least for a newbie like myself. A search in the PLT > blog didn't return any results ... Any help would be > appreciated. Thanks. > > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -- Cheers, Stephen -- Stephen De Gabrielle s.degabrielle@cs.ucl.ac.uk Telephone +44 (0)20 7679 0693 (x30693) Mobile 079 851 890 45 Project: Making Sense of Information (MaSI) Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html Home:http://www.degabrielle.name/stephen UCL Interaction Centre MPEB 8th floor University College London Gower Street London WC1E 6BT -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080801/39c0d303/attachment.htm From noelwelsh at gmail.com Fri Aug 1 03:34:32 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:24:48 2009 Subject: [plt-scheme] PLaneT messing up docs In-Reply-To: <18578.32788.116754.412334@arabic.ccs.neu.edu> References: <20080730120909.67DED650091@mail-svr1.cs.utah.edu> <990e0c030807311423y46ad37f0mb2f99f9dfce80205@mail.gmail.com> <932b2f1f0807311431m35b25e90pc564159948e1b522@mail.gmail.com> <18578.26601.599425.864893@arabic.ccs.neu.edu> <932b2f1f0807312010t31fed65crc9b12262ad361c62@mail.gmail.com> <18578.32788.116754.412334@arabic.ccs.neu.edu> Message-ID: On Fri, Aug 1, 2008 at 4:16 AM, Eli Barzilay wrote: > On Jul 31, Robby Findler wrote: >> I didn't consider that one of the tools that would complain. I mean >> things where one specifies a directory. Those would all check to see >> if the directory's name is legal. > > IIUC, the only such check is for the `scribbling' entry, which seems > arbitrary if it's the only one checked. The planet tool certainly inspects the info.ss file, which specifies the doc directory, as the planet tool prints out information from that file. If it could check for this error as well, it would be an improvement. Anything is better than nothing! We've had broken packages on planet for months and never realised this was the problem! N. From neil at neilvandyke.org Fri Aug 1 05:09:18 2008 From: neil at neilvandyke.org (Neil Van Dyke) Date: Thu Mar 26 02:24:48 2009 Subject: [plt-scheme] setup-plt --mode errortrace standard-module-name-resolver: cycle in loading Message-ID: <4892D2BE.8030906@neilvandyke.org> I'm having trouble with "setup-plt --mode errortrace -l" under 4.0.2. As the following example shows, I get a "standard-module-name-resolver: cycle in loading at #" error when I try to compile with errortrace information. Am I doing something wrong? emma ~/collects/foo cat foo.ss #lang scheme (define (foo x) (* x x)) emma ~/collects/foo setup-plt --mode errortrace -l foo setup-plt: version: 4.0.2 [3m] setup-plt: variants: 3m cgc setup-plt: main collects: /usr/local/plt-4.0.2/lib/plt/collects setup-plt: collects paths: setup-plt: /home/neil/collects setup-plt: /home/neil/.plt-scheme/4.0.2/collects setup-plt: /usr/local/plt-4.0.2/lib/plt/collects setup-plt: making: /home/neil/collects/foo setup-plt: in /home/neil/collects/foo/ setup-plt: in scheme/lang setup-plt: in syntax setup-plt: in errortrace setup-plt: in mzscheme setup-plt: in scheme setup-plt: in scheme/private standard-module-name-resolver: cycle in loading at #: (# # # #: (# # # # Message-ID: Peter Schlaifer ?rta: > Like Gregory's question about A Web Guide - the PLT doc is > purely a reference and tracing out what DrScheme does is heavy > going, at least for a newbie like myself. A search in the PLT > blog didn't return any results ... Any help would be > appreciated. Thanks. I think there is an expresion: All saints hand ... :-) If you want to create a GUI I can recommend MrEd Designer, my little project: http://www.hexahedron.hu/personal/peteri/mreddesigner/index.html MrEd Designer generates some Scheme code, so you can check that as well, how your program may look like. (It is not the best code, but it is something.) Best regards, Peter Ivanyi ______________________________________________________________________ Az idei ny?rhoz m?r nem el?g j? a telefonod? Add el a r?git ?s vegy?l egy jobbat a lehet? legolcs?bban! www.apronet.hu/telefon From grettke at acm.org Fri Aug 1 08:35:34 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:24:48 2009 Subject: [plt-scheme] A guide for the PLT GUI Application Framew In-Reply-To: References: <003301c8f37c$f20ea740$4001a8c0@BLACKIRON> Message-ID: <756daca50808010535i67361354jb7a42ed8f6bdec84@mail.gmail.com> > If you want to create a GUI I can recommend MrEd Designer, my > little project: MrEd Designer is really neat application! From mflatt at cs.utah.edu Fri Aug 1 09:25:42 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:24:48 2009 Subject: [plt-scheme] setup-plt --mode errortrace standard-module-name-resolver: cycle in loading In-Reply-To: <4892D2BE.8030906@neilvandyke.org> References: <4892D2BE.8030906@neilvandyke.org> Message-ID: <20080801132544.339EC6500C7@mail-svr1.cs.utah.edu> At Fri, 01 Aug 2008 05:09:18 -0400, Neil Van Dyke wrote: > I'm having trouble with "setup-plt --mode errortrace -l" under 4.0.2. It doesn't work, because I forgot about it for v4.0. I hope to fix it soon. Matthew From neil at neilvandyke.org Fri Aug 1 10:17:02 2008 From: neil at neilvandyke.org (Neil Van Dyke) Date: Thu Mar 26 02:24:49 2009 Subject: [plt-scheme] setup-plt --mode errortrace standard-module-name-resolver: cycle in loading In-Reply-To: <20080801132544.339EC6500C7@mail-svr1.cs.utah.edu> References: <4892D2BE.8030906@neilvandyke.org> <20080801132544.339EC6500C7@mail-svr1.cs.utah.edu> Message-ID: <48931ADE.3030208@neilvandyke.org> Thanks, Matthew. That will be great once you get a chance to work on it. In the interim, is there anything I can do to improve the backtraces when debugging, short of deleting all ".zo"s and running with "-l errortrace" (which means glacial performance, due to the way we're running right now)? We have a large Web app that we are moving to PLT 4. Sometimes the normal MzScheme 4 backtraces have source code location info, and sometimes they barely tell us more than the error message and the entry point to our app. Neil Matthew Flatt wrote at 08/01/2008 09:25 AM: > At Fri, 01 Aug 2008 05:09:18 -0400, Neil Van Dyke wrote: > >> I'm having trouble with "setup-plt --mode errortrace -l" under 4.0.2. >> > > It doesn't work, because I forgot about it for v4.0. I hope to fix it > soon. > > Matthew > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080801/eded08de/attachment.html From mflatt at cs.utah.edu Fri Aug 1 10:45:12 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:24:49 2009 Subject: [plt-scheme] setup-plt --mode errortrace standard-module-name-resolver: cycle in loading In-Reply-To: <48931ADE.3030208@neilvandyke.org> References: <4892D2BE.8030906@neilvandyke.org> <20080801132544.339EC6500C7@mail-svr1.cs.utah.edu> <48931ADE.3030208@neilvandyke.org> Message-ID: <20080801144513.223D665009E@mail-svr1.cs.utah.edu> At Fri, 01 Aug 2008 10:17:02 -0400, Neil Van Dyke wrote: > Thanks, Matthew. That will be great once you get a chance to work on it. > > In the interim, is there anything I can do to improve the backtraces > when debugging, short of deleting all ".zo"s and running with "-l > errortrace" (which means glacial performance, due to the way we're > running right now)? Here's a strategy that may help: 1. Change "errortrace-key.ss" to (module errortrace-key '#%kernel (define-values (errortrace-key) (gensym 'key)) (#%provide errortrace-key)) The key here is using the built-in '#%kernel module insteda of `scheme' modules. 2. Run `setup-plt --mode errortrace ....'. It's not getting the dependencies right, for reasons that I'm not yet sure about, but if you interrupt and re-start several times, it might work well enough. 3. Create a new "et.ss" module: (module et '#%kernel (use-compiled-file-paths (cons (build-path "compiled" "errortrace") (use-compiled-file-paths)))) Require that module before `-l errortrace' when starting. The problem with just using `-l errortrace' is that is loads parts of `scheme', and so there will be a mismatch when you load in further modules that have been compiled against the the errortrace-instrumented `scheme' modules. Matthew From neil at neilvandyke.org Fri Aug 1 11:14:09 2008 From: neil at neilvandyke.org (Neil Van Dyke) Date: Thu Mar 26 02:24:49 2009 Subject: [plt-scheme] setup-plt --mode errortrace standard-module-name-resolver: cycle in loading In-Reply-To: <20080801144513.223D665009E@mail-svr1.cs.utah.edu> References: <4892D2BE.8030906@neilvandyke.org> <20080801132544.339EC6500C7@mail-svr1.cs.utah.edu> <48931ADE.3030208@neilvandyke.org> <20080801144513.223D665009E@mail-svr1.cs.utah.edu> Message-ID: <48932841.8060206@neilvandyke.org> Matthew Flatt wrote at 08/01/2008 10:45 AM: > Here's a strategy that may help: > Thanks. Nice to know that's there if we get in a bind. From mflatt at cs.utah.edu Fri Aug 1 11:20:20 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:24:50 2009 Subject: [plt-scheme] setup-plt --mode errortrace standard-module-name-resolver: cycle in loading In-Reply-To: <48931ADE.3030208@neilvandyke.org> References: <4892D2BE.8030906@neilvandyke.org> <20080801132544.339EC6500C7@mail-svr1.cs.utah.edu> <48931ADE.3030208@neilvandyke.org> Message-ID: <20080801152020.C2FEE6500B7@mail-svr1.cs.utah.edu> At Fri, 01 Aug 2008 10:17:02 -0400, Neil Van Dyke wrote: > In the interim, is there anything I can do to improve the backtraces > when debugging One more thought: it sometimes helps to disable the JIT. The JIT and the bytecode interpreter compute stack traces in different ways, and they usually produce slightly different results. Matthew From s450r1 at gmail.com Fri Aug 1 14:17:07 2008 From: s450r1 at gmail.com (Jeff Dik) Date: Thu Mar 26 02:24:50 2009 Subject: [plt-scheme] PLT Scheme 4.0 and GNU Emacs 22.2.1 on Windows woes Message-ID: Hi, I'm trying to use PLT Scheme 4.0 in GNU Emacs 22.2.1 on Windows with the excellent Quack mode. The inferior scheme mode is not showing any errors until the mzscheme proces is closed. Here's a short example: Welcome to MzScheme v4.0.2 [3m], Copyright (c) 2004-2008 PLT Scheme Inc. > (+ 1 "3") > (foo bar baz) > (exit) +: expects type as 2nd argument, given: "3"; other arguments were: 1 === context === d:\sw\PLT\collects\scheme\private\misc.ss:68:7 reference to undefined identifier: foo === context === d:\sw\PLT\collects\scheme\private\misc.ss:68:7 Process scheme finished The errors do not appear until I run "(exit)". This problem also appears if I run mzscheme in the eshell. Emacs does not have this problem with PLT Scheme v371. The problem appears with PLT Scheme 3.99.0.25, 4.0, and 4.0.2 (these are the versions I tested). Any suggestions on how to correct the problem would be greatly appreciated :-) Thanks to all the PLT people for this wonderful Scheme implementation. Thanks, Jeff From mflatt at cs.utah.edu Fri Aug 1 14:22:49 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:24:50 2009 Subject: [plt-scheme] PLT Scheme 4.0 and GNU Emacs 22.2.1 on Windows woes In-Reply-To: References: Message-ID: <20080801182249.A9C996500B7@mail-svr1.cs.utah.edu> I think this is fixed for the next release and in the nightly builds (as of July 6 or so, which would be version 4.0.2.). Matthew At Fri, 1 Aug 2008 14:17:07 -0400, "Jeff Dik" wrote: > Hi, > > I'm trying to use PLT Scheme 4.0 in GNU Emacs 22.2.1 on Windows with > the excellent Quack mode. The inferior scheme mode is not showing any > errors until the mzscheme proces is closed. Here's a short example: > > Welcome to MzScheme v4.0.2 [3m], Copyright (c) 2004-2008 PLT Scheme Inc. > > (+ 1 "3") > > (foo bar baz) > > (exit) > +: expects type as 2nd argument, given: "3"; other > arguments were: 1 > > === context === > d:\sw\PLT\collects\scheme\private\misc.ss:68:7 > > reference to undefined identifier: foo > > === context === > d:\sw\PLT\collects\scheme\private\misc.ss:68:7 > > > Process scheme finished > > The errors do not appear until I run "(exit)". This problem also > appears if I run mzscheme in the eshell. > > Emacs does not have this problem with PLT Scheme v371. The problem > appears with PLT Scheme 3.99.0.25, 4.0, and 4.0.2 (these are the > versions I tested). > > Any suggestions on how to correct the problem would be greatly appreciated :-) > > Thanks to all the PLT people for this wonderful Scheme implementation. > > Thanks, > Jeff > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From s450r1 at gmail.com Fri Aug 1 15:05:40 2008 From: s450r1 at gmail.com (Jeff Dik) Date: Thu Mar 26 02:24:50 2009 Subject: [plt-scheme] PLT Scheme 4.0 and GNU Emacs 22.2.1 on Windows woes In-Reply-To: <20080801182249.A9C996500B7@mail-svr1.cs.utah.edu> References: <20080801182249.A9C996500B7@mail-svr1.cs.utah.edu> Message-ID: Matthew, Thanks for the fast reply. I downloaded 4.2.0.6 and can confirm that it doesn't have this problem. I'll have to remember to try the nightly builds next time! Thanks again, Jeff On Fri, Aug 1, 2008 at 2:22 PM, Matthew Flatt wrote: > I think this is fixed for the next release and in the nightly builds > (as of July 6 or so, which would be version 4.0.2.). > > Matthew > > At Fri, 1 Aug 2008 14:17:07 -0400, "Jeff Dik" wrote: >> Hi, >> >> I'm trying to use PLT Scheme 4.0 in GNU Emacs 22.2.1 on Windows with >> the excellent Quack mode. The inferior scheme mode is not showing any >> errors until the mzscheme proces is closed. Here's a short example: >> >> Welcome to MzScheme v4.0.2 [3m], Copyright (c) 2004-2008 PLT Scheme Inc. >> > (+ 1 "3") >> > (foo bar baz) >> > (exit) >> +: expects type as 2nd argument, given: "3"; other >> arguments were: 1 >> >> === context === >> d:\sw\PLT\collects\scheme\private\misc.ss:68:7 >> >> reference to undefined identifier: foo >> >> === context === >> d:\sw\PLT\collects\scheme\private\misc.ss:68:7 >> >> >> Process scheme finished >> >> The errors do not appear until I run "(exit)". This problem also >> appears if I run mzscheme in the eshell. >> >> Emacs does not have this problem with PLT Scheme v371. The problem >> appears with PLT Scheme 3.99.0.25, 4.0, and 4.0.2 (these are the >> versions I tested). >> >> Any suggestions on how to correct the problem would be greatly appreciated :-) >> >> Thanks to all the PLT people for this wonderful Scheme implementation. >> >> Thanks, >> Jeff >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From grettke at acm.org Sat Aug 2 14:48:04 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:24:50 2009 Subject: [plt-scheme] New PLT doc search area colors Message-ID: <756daca50808021148s1fd5fea7g7e9c124f012bd214@mail.gmail.com> The new PLT doc search area colors look good; much easier to see, and identify the use thereof. From grettke at acm.org Sat Aug 2 15:40:58 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:24:50 2009 Subject: [plt-scheme] SRFI 62 in PLT 4? Message-ID: <756daca50808021240s481fee9cn35a6c95552703c74@mail.gmail.com> SRFI 62 is listed in the SRFI doc page, but it isn't present in 4.0. Should it be? From cce at ccs.neu.edu Sat Aug 2 16:05:27 2008 From: cce at ccs.neu.edu (Carl Eastlund) Date: Thu Mar 26 02:24:51 2009 Subject: [plt-scheme] SRFI 62 in PLT 4? In-Reply-To: <756daca50808021240s481fee9cn35a6c95552703c74@mail.gmail.com> References: <756daca50808021240s481fee9cn35a6c95552703c74@mail.gmail.com> Message-ID: <990e0c030808021305y64122063ueddfd3715adcb523@mail.gmail.com> On Sat, Aug 2, 2008 at 3:40 PM, Grant Rettke wrote: > SRFI 62 is listed in the SRFI doc page, but it isn't present in 4.0. > > Should it be? S-expression comments are standard in PLT Scheme, rather than a separate library. -- Carl Eastlund From grettke at acm.org Sat Aug 2 16:17:14 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:24:51 2009 Subject: [plt-scheme] SRFI 62 in PLT 4? In-Reply-To: <990e0c030808021305y64122063ueddfd3715adcb523@mail.gmail.com> References: <756daca50808021240s481fee9cn35a6c95552703c74@mail.gmail.com> <990e0c030808021305y64122063ueddfd3715adcb523@mail.gmail.com> Message-ID: <756daca50808021317u244f6c7h7909ae1602e39508@mail.gmail.com> > S-expression comments are standard in PLT Scheme, rather than a > separate library. Thanks. From grettke at acm.org Sat Aug 2 16:28:50 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:24:51 2009 Subject: [plt-scheme] New PLT doc search area colors In-Reply-To: References: <756daca50808021148s1fd5fea7g7e9c124f012bd214@mail.gmail.com> Message-ID: <756daca50808021328y2e6231b0nadb1cc73d86977bb@mail.gmail.com> > You piqued my curiosity. I too like the change. I notice search within > DrScheme itself has new and nifty ovals. There is also a neat little animation while the search is being performed :). From gknauth at sunlink.net Sat Aug 2 15:48:54 2008 From: gknauth at sunlink.net (Geoffrey S. Knauth) Date: Thu Mar 26 02:24:51 2009 Subject: [plt-scheme] New PLT doc search area colors In-Reply-To: <756daca50808021148s1fd5fea7g7e9c124f012bd214@mail.gmail.com> References: <756daca50808021148s1fd5fea7g7e9c124f012bd214@mail.gmail.com> Message-ID: On Aug 2, 2008, at 14:48, Grant Rettke wrote: > The new PLT doc search area colors look good; much easier to see, and > identify the use thereof. You piqued my curiosity. I too like the change. I notice search within DrScheme itself has new and nifty ovals. From simon at joyful.com Sat Aug 2 18:12:53 2008 From: simon at joyful.com (Simon Michael) Date: Thu Mar 26 02:24:51 2009 Subject: [plt-scheme] allegro.plt updated for 4xx In-Reply-To: <90D64D4C-0724-4DD7-AF2C-4B16149B1C82@joyful.com> References: <30239EA3-E519-4C2F-92D8-E2CB3AE7A9EC@joyful.com> <48947615.6070009@ccs.neu.edu> <90D64D4C-0724-4DD7-AF2C-4B16149B1C82@joyful.com> Message-ID: > It might be nice to add this to the allegro.plt examples, and > publish the lot via darcs for easier collaboration. Any thoughts ? Well, I tried it as an experiment and to record this morning's work: http://joyful.com/darcsweb/darcsweb.cgi?r=allegro.plt;a=summary This makes all examples run with PLT 4 and adds your pacman and raptor. It doesn't (yet) contain the large allegro and libpng source trees. Thanks again, this package really seems to work pretty well. -Simon From simon at joyful.com Sat Aug 2 18:16:56 2008 From: simon at joyful.com (Simon Michael) Date: Thu Mar 26 02:24:51 2009 Subject: [plt-scheme] Re: allegro.plt updated for 4xx In-Reply-To: References: <30239EA3-E519-4C2F-92D8-E2CB3AE7A9EC@joyful.com> <48947615.6070009@ccs.neu.edu> <90D64D4C-0724-4DD7-AF2C-4B16149B1C82@joyful.com> Message-ID: PS also java-class.plt needs a small update: Simon Michael **20080802202303] hunk ./jclass.ss 90 - (init-rest rest) + (c:init-rest rest) From psykosh at earthlink.net Sun Aug 3 12:51:49 2008 From: psykosh at earthlink.net (Psy-Kosh) Date: Thu Mar 26 02:24:52 2009 Subject: [plt-scheme] possible enter!/drscheme bug Message-ID: enter! is supposed to be provided in the scheme lang (though not scheme/base) right? But in DrScheme, with #lang scheme in the definitions window, I get this: Welcome to DrScheme, version 4.0.2.6-svn30jul2008 [3m]. Language: Module; memory limit: 128 megabytes. > enter! . . reference to an identifier before its definition: enter! > undefined? hrm... further, if I instead load up mzscheme... Welcome to MzScheme v4.0.2.6 [3m], Copyright (c) 2004-2008 PLT Scheme Inc. > enter! stdin::0: enter!: bad syntax; should be `(enter! )' in: enter ! === context === C:\Program Files\PLT\collects\scheme\private\misc.ss:68:7 > so, MzScheme recognizes it. Psy-Kosh From eli at barzilay.org Sun Aug 3 13:43:04 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:24:52 2009 Subject: [plt-scheme] possible enter!/drscheme bug In-Reply-To: References: Message-ID: <18581.60968.262156.353590@arabic.ccs.neu.edu> On Aug 3, Psy-Kosh wrote: > enter! is supposed to be provided in the scheme lang (though not > scheme/base) right? No, it's provided by scheme/enter, which is included in scheme/init, which is what mzscheme actually uses. So in drscheme you need to require it explicitly (but the whole point is to have something that can be used like the module language in drscheme). You can also see that you don't get it if you run "mzscheme -I scheme". -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From psykosh at earthlink.net Sun Aug 3 14:00:27 2008 From: psykosh at earthlink.net (Psy-Kosh) Date: Thu Mar 26 02:24:52 2009 Subject: [plt-scheme] possible enter!/drscheme bug In-Reply-To: <18581.60968.262156.353590@arabic.ccs.neu.edu> References: <18581.60968.262156.353590@arabic.ccs.neu.edu> Message-ID: On Sun, 03 Aug 2008 13:43:04 -0400, Eli Barzilay wrote: > > No, it's provided by scheme/enter, which is included in scheme/init, > which is what mzscheme actually uses. So in drscheme you need to > require it explicitly (but the whole point is to have something that > can be used like the module language in drscheme). You can also see > that you don't get it if you run "mzscheme -I scheme". > Ooooh, okay, thanks. In that case it looks like there's a documentation bug: The docs insist that scheme contains scheme/enter. in the reference where it says "the scheme library combines ...", scheme/enter is included in that list, and in section 16.4 it says this: "The bindings documented in this section are provided by the scheme/enter and scheme libraries, but not scheme/base." Psy-Kosh From eli at barzilay.org Sun Aug 3 14:58:59 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:24:52 2009 Subject: [plt-scheme] possible enter!/drscheme bug In-Reply-To: References: <18581.60968.262156.353590@arabic.ccs.neu.edu> Message-ID: <18581.65523.258554.922131@arabic.ccs.neu.edu> On Aug 3, Psy-Kosh wrote: > On Sun, 03 Aug 2008 13:43:04 -0400, Eli Barzilay wrote: > > > No, it's provided by scheme/enter, which is included in > > scheme/init, which is what mzscheme actually uses. So in drscheme > > you need to require it explicitly (but the whole point is to have > > something that can be used like the module language in drscheme). > > You can also see that you don't get it if you run "mzscheme -I > > scheme". > > Ooooh, okay, thanks. In that case it looks like there's a documentation > bug: The docs insist that scheme contains scheme/enter. You're right -- fixed in svn. Thanks for pointing it out. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From goetter at mazama.net Sun Aug 3 15:12:22 2008 From: goetter at mazama.net (Ben Goetter) Date: Thu Mar 26 02:24:52 2009 Subject: [plt-scheme] Extensibility of MrEd Message-ID: <48960316.8060809@mazama.net> Does MrEd contain any hooks for operating-system-specific extensions, FFI or otherwise? What is the best way to access OS-specific UI functionality (e.g. system-defined GUI widgets, handling system-specific user interaction messages, etc.) in a MrEd program? I am building an experimental application on a yet-unreleased version of a Microsoft OS on yet-unreleased hardware. And I am hoping not to have to roll a homebrew GUI wrapper framework (fraught with danger and sundry system event trampolines), or to fork the MrEd DLL source. What are my options? Thanks, Ben From grettke at acm.org Sun Aug 3 16:19:20 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:24:52 2009 Subject: [plt-scheme] V4 request for thoughts on various question Message-ID: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> Hi folks, While reading the V4 guide (not detailed reference, yet) I noted some questions, and wondered what other folks had to say about them: When do you use weak hash tables? When might folks use case-lambda rather than keyword or optional arguments? Does anyone use the curried define form? Do folks use values and define-values much, or destructure and use lists, match-define or match-let instead? The fact that let allow paralell bindings, do some folks take that fact and perform optimizations on multiple cpu boxes? Is it worth it? How would you use letrec-values? I don't use structures much, but they seem pretty versatile and therefore important; are they? Structure guards are neat. Where does this fit in dynamic world? You could make a type change and detect it in a running system. Is typing the data enough, is that the perfect mix between static and dynamic languages? Units seem much easier to understand. Is that just a documentation change? Are any of you going to use units more? I see a place where I could use units instead of classes, which I had used because units just didn't make sense to me. Best wishes, Grant -- http://www.wisdomandwonder.com/ From noelwelsh at gmail.com Sun Aug 3 16:31:38 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:24:52 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> Message-ID: On Sun, Aug 3, 2008 at 9:19 PM, Grant Rettke wrote: > When do you use weak hash tables? When you want some kinda control over memory consumption. Look at the writeups for Java weak tables -- it's the same idea. > When might folks use case-lambda rather than keyword or optional arguments? When you're writing stuff that exists in the core of PLT Scheme, before even optional arguments are available (the so called kernel language). At least this is the only use case I know of. > Does anyone use the curried define form? Yes. It is a handy shortcut to occasionally use. > Do folks use values and define-values much, or destructure and use > lists, match-define or match-let instead? I use the most direct expression of the solution. It that means values, use that. It it means a structure, use that. > I don't use structures much, but they seem pretty versatile and > therefore important; are they? They are very important -- see HtDP. N. From grettke at acm.org Sun Aug 3 16:41:09 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:24:53 2009 Subject: [plt-scheme] PLT: How do you guys do it? Message-ID: <756daca50808031341u77c3aafeg445b2e4d8a34dbd@mail.gmail.com> Hi PLT folks, I am wondering: how do you guys do it? I mean literally, not figuratively. All of you have academic careers (or am I assuming incorrectly about the PLT body?), so your job involves many other things besides maintaining PLT. Where do you find the time for stuff? Who pays for it, where do grants fit in? Best wishes, Grant -- http://www.wisdomandwonder.com/ From goetter at mazama.net Sun Aug 3 16:42:54 2008 From: goetter at mazama.net (Ben Goetter) Date: Thu Mar 26 02:24:53 2009 Subject: [plt-scheme] Extensibility of MrEd In-Reply-To: <48960316.8060809@mazama.net> References: <48960316.8060809@mazama.net> Message-ID: <4896184E.5070903@mazama.net> P.S. The get-handle method of window<%> gets me partway there. (I overlooked this in the docs - scheme/class being new to me.) What remains now is to extend the set of messages recognized by a frame window. From czhu at cs.utah.edu Sun Aug 3 16:46:46 2008 From: czhu at cs.utah.edu (Chongkai Zhu) Date: Thu Mar 26 02:24:53 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> Message-ID: <48961936.5040902@cs.utah.edu> I will answer some here. Grant Rettke wrote: > Hi folks, > > While reading the V4 guide (not detailed reference, yet) I noted some > questions, and wondered what other folks had to say about them: > > When do you use weak hash tables? > I used weak hash once tables in v371/372 or so. It's just weak reference + hash table. See Noel's reply. > When might folks use case-lambda rather than keyword or optional arguments? > > Does anyone use the curried define form? > I did sometimes. > Do folks use values and define-values much, or destructure and use > lists, match-define or match-let instead? > I prefer values over destructure. > The fact that let allow paralell bindings, do some folks take that > fact and perform optimizations on multiple cpu boxes? Is it worth it? > > How would you use letrec-values? > > If one of the `val-expr' of a letrec returns multiple values. > I don't use structures much, but they seem pretty versatile and > therefore important; are they? > > Yes. > Structure guards are neat. Where does this fit in dynamic world? You > could make a type change and detect it in a running system. Is typing > the data enough, is that the perfect mix between static and dynamic > languages? > > Units seem much easier to understand. Is that just a documentation > change? Are any of you going to use units more? I see a place where I > could use units instead of classes, which I had used because units > just didn't make sense to me. > > I think it is just documentation. If no inherit/superclass is needed, I won't use class. > Best wishes, > > Grant > > Chongkai From eli at barzilay.org Sun Aug 3 16:59:49 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:24:53 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> Message-ID: <18582.7237.745135.866471@arabic.ccs.neu.edu> On Aug 3, Grant Rettke wrote: > Hi folks, > > While reading the V4 guide (not detailed reference, yet) I noted some > questions, and wondered what other folks had to say about them: > > When do you use weak hash tables? A classic case for weak hash tables is when you want to associate arbitrary data with values -- you use a hash table, but you don't want it to prevent collecting garbage. > When might folks use case-lambda rather than keyword or optional > arguments? Two points: optionals are a little slower currently, and there are things that you cannot do with them, for example: (define draw-foo (case-lambda [(foo) (draw-foo foo 0 0)] [(foo x y) ...])) But Noel's point is good too -- think of it as a more primitive tool. > Does anyone use the curried define form? Yes. Very convenient in some cases. > Do folks use values and define-values much, or destructure and use > lists, match-define or match-let instead? Depends. > The fact that let allow paralell bindings, do some folks take that > fact and perform optimizations on multiple cpu boxes? Is it worth > it? The values are parallel, but the computation is not. It's easy to confuse the two, but it's a mistake. > How would you use letrec-values? Very rare uses for it. Another mostly-for-primitive-use thing. > I don't use structures much, but they seem pretty versatile and > therefore important; are they? Very. > Structure guards are neat. Where does this fit in dynamic world? You > could make a type change and detect it in a running system. Is > typing the data enough, is that the perfect mix between static and > dynamic languages? Same idea as contracts. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From matthias at ccs.neu.edu Sun Aug 3 17:24:57 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:24:53 2009 Subject: [plt-scheme] PLT: How do you guys do it? In-Reply-To: <756daca50808031341u77c3aafeg445b2e4d8a34dbd@mail.gmail.com> References: <756daca50808031341u77c3aafeg445b2e4d8a34dbd@mail.gmail.com> Message-ID: <6E087CDE-A3E6-4767-9F34-C7BA60739B88@ccs.neu.edu> We're playing the DC lottery, which tends to have slightly better odds than the one in other states. -- Matthias On Aug 3, 2008, at 4:41 PM, Grant Rettke wrote: > Hi PLT folks, > > I am wondering: how do you guys do it? I mean literally, not > figuratively. > > All of you have academic careers (or am I assuming incorrectly about > the PLT body?), so your job involves many other things besides > maintaining PLT. > > Where do you find the time for stuff? Who pays for it, where do > grants fit in? > > Best wishes, > > Grant > > -- > http://www.wisdomandwonder.com/ > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From robby at cs.uchicago.edu Sun Aug 3 17:27:03 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:24:54 2009 Subject: [plt-scheme] PLT: How do you guys do it? In-Reply-To: <6E087CDE-A3E6-4767-9F34-C7BA60739B88@ccs.neu.edu> References: <756daca50808031341u77c3aafeg445b2e4d8a34dbd@mail.gmail.com> <6E087CDE-A3E6-4767-9F34-C7BA60739B88@ccs.neu.edu> Message-ID: <932b2f1f0808031427v3a84be54r401a2a149b309b6@mail.gmail.com> Oh, that and we've all moved into monasteries to shield us from Temptations to Stray from the One True Way. Robby On Sun, Aug 3, 2008 at 4:24 PM, Matthias Felleisen wrote: > > We're playing the DC lottery, which tends to have slightly better odds than > the one in other states. -- Matthias > > > On Aug 3, 2008, at 4:41 PM, Grant Rettke wrote: > >> Hi PLT folks, >> >> I am wondering: how do you guys do it? I mean literally, not figuratively. >> >> All of you have academic careers (or am I assuming incorrectly about >> the PLT body?), so your job involves many other things besides >> maintaining PLT. >> >> Where do you find the time for stuff? Who pays for it, where do grants fit >> in? >> >> Best wishes, >> >> Grant >> >> -- >> http://www.wisdomandwonder.com/ >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From vijay.the.schemer at gmail.com Mon Aug 4 02:11:42 2008 From: vijay.the.schemer at gmail.com (Vijay Mathew) Date: Thu Mar 26 02:24:54 2009 Subject: [plt-scheme] MzScheme Library support Message-ID: <9c57dec20808032311u2be8a07cw53f71f5ab8551f3b@mail.gmail.com> When trying to create a library (r6rs) in MzScheme, I am getting this error: export: misuse of unit keyword in: (export make push! pop! empty!) I was trying to get a sample in r6rs to work. Is the library implementation in MzScheme incomplete? Is it possible to implement the r6rs libraries as a simple wrapper on MzScheme modules? Thanks, -- Vijay -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080804/f6a108a5/attachment.htm From spdegabrielle at gmail.com Mon Aug 4 04:41:24 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:24:55 2009 Subject: [plt-scheme] get-text-extent problem Message-ID: <595b9ab20808040141l147bcddbs664ae0f422791c9f@mail.gmail.com> Hi, I'm using get-text-extent to determine the width a string to be included in a snip, (define/override get-extent (lambda (dc x y w h descent space lspace rspace) ;(for-each (lambda (b) (when (box? b) (set-box! b 0))) ; (list descent space lspace rspace)) (let-values (((width height b s) (send dc get-text-extent (format "~A" my-string)))) (when (box? w) (set-box! w width)) (when (box? h) (set-box! h height))))) The problem is the width is wider when get-extent calls get-text-extent than when get-text-extent is called by the (snip)draw method. The problem seems to be related to spaces; I've attached a simple example - use click-drag to select multiple snips. Any advice appreciated, Thanks, Stephen -------------- next part -------------- A non-text attachment was scrubbed... Name: my.ss Type: application/octet-stream Size: 2115 bytes Desc: not available Url : http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080804/415b4b0f/my.obj From erlendlor at gmail.com Mon Aug 4 05:14:25 2008 From: erlendlor at gmail.com (Erlend Lorentzen) Date: Thu Mar 26 02:24:56 2009 Subject: [plt-scheme] long as return type for scheme_build_list? Message-ID: <86ab98e40808040214o11b6795ble692baf4fbe67e61@mail.gmail.com> Looking in the PLT documentation i found the following entry for scheme_build_list: ----------------------------------------------------------------------------------------- long scheme_build_list(int c, Scheme_Object** elems) Creates and returns a list of length c with the elements elems. ------------------------------------------------------------------------------------------ Is this correct? Shouldn't the return type be Scheme_Object* ? Regards Erlend -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080804/1fc4f269/attachment.htm From eli at barzilay.org Mon Aug 4 05:28:39 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:24:56 2009 Subject: [plt-scheme] long as return type for scheme_build_list? In-Reply-To: <86ab98e40808040214o11b6795ble692baf4fbe67e61@mail.gmail.com> References: <86ab98e40808040214o11b6795ble692baf4fbe67e61@mail.gmail.com> Message-ID: <18582.52167.131486.560849@arabic.ccs.neu.edu> On Aug 4, Erlend Lorentzen wrote: > Looking in the PLT documentation i found the following entry for > scheme_build_list: > ----------------------------------------------------------------------------------------- > > long scheme_build_list(int c, Scheme_Object** elems) > Creates and returns a list of length c with the elements elems. > ------------------------------------------------------------------------------------------ > > Is this correct? Shouldn't the return type be Scheme_Object* ? It looks like a typo -- I fixed the docs. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From mflatt at cs.utah.edu Mon Aug 4 07:50:16 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:24:56 2009 Subject: [plt-scheme] MzScheme Library support In-Reply-To: <9c57dec20808032311u2be8a07cw53f71f5ab8551f3b@mail.gmail.com> References: <9c57dec20808032311u2be8a07cw53f71f5ab8551f3b@mail.gmail.com> Message-ID: <20080804115020.1A97D6500AC@mail-svr1.cs.utah.edu> At Mon, 4 Aug 2008 11:41:42 +0530, "Vijay Mathew" wrote: > When trying to create a library (r6rs) in MzScheme, I am getting this error: > > export: misuse of unit keyword in: (export make push! pop! empty!) > > I was trying to get a sample in r6rs to work. It sounds like you're trying to load R6RS directly into `mzscheme'. For an R6RS library, you need to either * install it with `plt-r6rs' * prefix the library with `#!r6rs' See http://docs.plt-scheme.org/r6rs/index.html for more information. Matthew From mflatt at cs.utah.edu Mon Aug 4 07:54:18 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:24:56 2009 Subject: [plt-scheme] get-text-extent problem In-Reply-To: <595b9ab20808040141l147bcddbs664ae0f422791c9f@mail.gmail.com> References: <595b9ab20808040141l147bcddbs664ae0f422791c9f@mail.gmail.com> Message-ID: <20080804115422.E7A956500AC@mail-svr1.cs.utah.edu> At Mon, 4 Aug 2008 09:41:24 +0100, "Stephen De Gabrielle" wrote: > I'm using get-text-extent to determine the width a string to be > included in a snip, > > (define/override get-extent > (lambda (dc x y w h descent space lspace rspace) > ;(for-each (lambda (b) (when (box? b) (set-box! b 0))) > ; (list descent space lspace rspace)) > > (let-values (((width height b s) (send dc get-text-extent > (format "~A" my-string)))) > (when (box? w) (set-box! w width)) > (when (box? h) (set-box! h height))))) > > The problem is the width is wider when get-extent calls > get-text-extent than when get-text-extent is called by the (snip)draw > method. When `draw' is called, the snip's font is already set in the DC. When `get-extent' is called, the font is not automatically set. So, to get the right size, you need to specify the font in `get-extent': (inherit get-style) .... (send dc get-text-extent (format "~A" my-string) (send (get-style) get-font)) Matthew From mflatt at cs.utah.edu Mon Aug 4 08:11:03 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:24:56 2009 Subject: [plt-scheme] Extensibility of MrEd In-Reply-To: <4896184E.5070903@mazama.net> References: <48960316.8060809@mazama.net> <4896184E.5070903@mazama.net> Message-ID: <20080804121107.8C4B16500AD@mail-svr1.cs.utah.edu> At Sun, 03 Aug 2008 13:42:54 -0700, Ben Goetter wrote: > P.S. The get-handle method of window<%> gets me partway there. (I > overlooked this in the docs - scheme/class being new to me.) What > remains now is to extend the set of messages recognized by a frame window. I don't think there's currently a way to extend the messages recognized by a frame, but it's something we could add. Beware that there's a bad interaction between PLT Scheme threads and Windows: a Scheme-level thread swap cannot be allowed while handling a Windows message. The solution is usually to handle a message by just queuing a callback in the eventspace, and then return to Windows immediately; that works when you don't need to compute any particular return value for the message. Would that strategy work for the messages that you need to handle (if you had a way to install a handler)? Matthew From atmamta at gmail.com Mon Aug 4 08:35:25 2008 From: atmamta at gmail.com (Atmam Ta) Date: Thu Mar 26 02:24:57 2009 Subject: [plt-scheme] installing self-made modules locally Message-ID: Hi, I have been searching in vain for the following in the docs: how do I install my own modules in my collects directory? (install = compile to native and/or byte code and move it to the collects dir) thanks Atmam -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080804/063b18dd/attachment.html From alan at alan-watson.org Mon Aug 4 11:16:48 2008 From: alan at alan-watson.org (Alan Watson) Date: Thu Mar 26 02:24:57 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <18582.7237.745135.866471@arabic.ccs.neu.edu> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> Message-ID: <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> >> The fact that let allow paralell bindings, do some folks take that >> fact and perform optimizations on multiple cpu boxes? Is it worth >> it? > > The values are parallel, but the computation is not. It's easy to > confuse the two, but it's a mistake. MPSCM[1] has a parallel let form. Eli, can you point me to language in the R5RS or R6RS that forbids interleaving the evaluation of the initializers in a standard let form? The R6RS just says, "The s are evaluated in the current environment (in some unspecified order)". I think that allows the evaluation of the initializers to be interleaved or parallelized. Regards, Alan [1] http://citeseerx.ist.psu.edu/viewdoc/summary;jsessionid=9358F23E06B535DDD5BA2AAC80190D3E?doi=10.1.1.102.2907 -- Alan Watson http://www.alan-watson.org/ From spdegabrielle at gmail.com Mon Aug 4 11:20:59 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:24:57 2009 Subject: [plt-scheme] table-snip% implementation Message-ID: <595b9ab20808040820u79a36c83we21b5b15d1960eb5@mail.gmail.com> Hi, Thanks to Matthew I have added another dodgy package to planet. (require (planet "table-snip.ss" ("spdegabrielle" "table-snip.plt" 1 0))) code/appropriateness to planet/ any comments on appreciated (code? appropriateness to planet?) Cheers, Stephen On Mon, Aug 4, 2008 at 12:54 PM, Matthew Flatt wrote: > > When `draw' is called, the snip's font is already set in the DC. When > `get-extent' is called, the font is not automatically set. > > So, to get the right size, you need to specify the font in > `get-extent': > > (inherit get-style) .... > > (send dc get-text-extent (format "~A" my-string) > (send (get-style) get-font)) From czhu at cs.utah.edu Mon Aug 4 11:29:53 2008 From: czhu at cs.utah.edu (Chongkai Zhu) Date: Thu Mar 26 02:24:58 2009 Subject: [plt-scheme] installing self-made modules locally In-Reply-To: References: Message-ID: <48972071.3080407@cs.utah.edu> 1. put files in a sub-directory under your collect dir (if you don't know what dir it is, `(current-library-collection-paths)' will tell you that) 2. compile to native and/or byte code using mzc (reference http://docs.plt-scheme.org/mzc/index.html) 3. If you want to distribute it, http://docs.plt-scheme.org/mzc/plt.html Chongkai Atmam Ta wrote: > Hi, > I have been searching in vain for the following in the docs: > how do I install my own modules in my collects directory? > (install = compile to native and/or byte code and move it to the > collects dir) > thanks > > Atmam > ------------------------------------------------------------------------ > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From jensaxel at soegaard.net Mon Aug 4 11:36:41 2008 From: jensaxel at soegaard.net (Jens Axel Soegaard) Date: Thu Mar 26 02:24:58 2009 Subject: [plt-scheme] installing self-made modules locally In-Reply-To: References: Message-ID: <48972209.9070908@soegaard.net> Atmam Ta wrote: > I have been searching in vain for the following in the docs: > how do I install my own modules in my collects directory? > (install = compile to native and/or byte code and move it to the > collects dir) > thanks The short answer: You are not supposed to. Use the planet tool to make a "link" between your directory and a planet specification. In your case something like: planet link ta my-package 1 0 In your code, you can now use (require (planet "file.scm" ("ta" "my-package.plt" 1 0))) to use your module. The full usage guide to the planet tool: Usage: planet [option ...] [note: you can name a subcommand by typing any unambiguous prefix of it.] PLT Scheme PLaneT command-line tool. Provides commands to help you manipulate your local planet cache. For help on a particular subcommand, type 'planet --help' Available subcommands: create create a PLaneT archive from a directory install download and install a given package remove remove the specified package from the local cache show list the packages installed in the local cache clearlinks clear the linkage table, allowing upgrades fileinject install a local file to the planet cache link create a development link unlink remove development link associated with the given package fetch download a package file without installing it url get a URL for the given package open unpack the contents of the given package structure display the structure of a given .plt archive print display a file within of the given .plt archive And for planet link: planet link: expects on the command line, given 0 arguments -- Jens Axel S?gaard From robby at cs.uchicago.edu Mon Aug 4 11:47:35 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:24:58 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> Message-ID: <932b2f1f0808040847m110fb054l8d1b4ac84e384aae@mail.gmail.com> On Mon, Aug 4, 2008 at 10:16 AM, Alan Watson wrote: >>> The fact that let allow paralell bindings, do some folks take that >>> fact and perform optimizations on multiple cpu boxes? Is it worth >>> it? >> >> The values are parallel, but the computation is not. It's easy to >> confuse the two, but it's a mistake. > > MPSCM[1] has a parallel let form. > > Eli, can you point me to language in the R5RS or R6RS that forbids > interleaving the evaluation of the initializers in a standard let form? The > R6RS just says, "The s are evaluated in the current environment (in > some unspecified order)". I think that allows the evaluation of the > initializers to be interleaved or parallelized. The constraint is on the values produced, not on the evaluation order per se. Specifically, this: (define q 0) (let ([x (begin (set! q (+ q 1)) 1)] [y (begin (set! q (- q 1)) 1)]) q) must evaluate to 0, not -1 or +1. Robby From alan at alan-watson.org Mon Aug 4 11:58:39 2008 From: alan at alan-watson.org (Alan Watson) Date: Thu Mar 26 02:24:59 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <932b2f1f0808040847m110fb054l8d1b4ac84e384aae@mail.gmail.com> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> <932b2f1f0808040847m110fb054l8d1b4ac84e384aae@mail.gmail.com> Message-ID: <4C4B7BCE-6A72-4DE8-BEF4-190274CC619B@alan-watson.org> > The constraint is on the values produced, not on the evaluation order > per se. I don't understand what you mean by this. Regards, Alan -- Alan Watson http://www.alan-watson.org/ From samth at ccs.neu.edu Mon Aug 4 12:06:49 2008 From: samth at ccs.neu.edu (Sam TH) Date: Thu Mar 26 02:24:59 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> Message-ID: <63bb19ae0808040906h119edea7j86cab60a228da6cc@mail.gmail.com> On Mon, Aug 4, 2008 at 11:16 AM, Alan Watson wrote: >>> The fact that let allow paralell bindings, do some folks take that >>> fact and perform optimizations on multiple cpu boxes? Is it worth >>> it? >> >> The values are parallel, but the computation is not. It's easy to >> confuse the two, but it's a mistake. > > MPSCM[1] has a parallel let form. > > Eli, can you point me to language in the R5RS or R6RS that forbids > interleaving the evaluation of the initializers in a standard let form? The > R6RS just says, "The s are evaluated in the current environment (in > some unspecified order)". I think that allows the evaluation of the > initializers to be interleaved or parallelized. Looking at the R6RS, it appears that while the evaluation of arguments may not be interleaved (the phrase is "consistent with some sequential order"), that language is not used for `let'. So I believe that the evaluation of `let' bindings may be interleaved. Thanks, -- sam th samth@ccs.neu.edu From grettke at acm.org Mon Aug 4 12:08:17 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:24:59 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <932b2f1f0808040847m110fb054l8d1b4ac84e384aae@mail.gmail.com> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> <932b2f1f0808040847m110fb054l8d1b4ac84e384aae@mail.gmail.com> Message-ID: <756daca50808040908w1c4cc257o6ab056d422bf68e2@mail.gmail.com> wrote: > The constraint is on the values produced, not on the evaluation order per se. Specifically, this: > > (define q 0) > (let ([x (begin (set! q (+ q 1)) 1)] > [y (begin (set! q (- q 1)) 1)]) > q) > > must evaluate to 0, not -1 or +1. When you say "values produced", do you mean values that are bound to the names in the name value pairs, or ordering in which the value expressions themselves are evaluated (x then y versus y then x)? From robby at cs.uchicago.edu Mon Aug 4 12:28:53 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:24:59 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <756daca50808040908w1c4cc257o6ab056d422bf68e2@mail.gmail.com> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> <932b2f1f0808040847m110fb054l8d1b4ac84e384aae@mail.gmail.com> <756daca50808040908w1c4cc257o6ab056d422bf68e2@mail.gmail.com> Message-ID: <932b2f1f0808040928l490b5deal1bc514b786654bd5@mail.gmail.com> On Mon, Aug 4, 2008 at 11:08 AM, Grant Rettke wrote: > wrote: >> The constraint is on the values produced, not on the evaluation order per se. Specifically, this: >> >> (define q 0) >> (let ([x (begin (set! q (+ q 1)) 1)] >> [y (begin (set! q (- q 1)) 1)]) >> q) >> >> must evaluate to 0, not -1 or +1. > > When you say "values produced", do you mean values that are bound to > the names in the name value pairs, or ordering in which the value > expressions themselves are evaluated (x then y versus y then x)? I just mean the result of the let expression. Robby From robby at cs.uchicago.edu Mon Aug 4 12:33:24 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:24:59 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <63bb19ae0808040906h119edea7j86cab60a228da6cc@mail.gmail.com> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> <63bb19ae0808040906h119edea7j86cab60a228da6cc@mail.gmail.com> Message-ID: <932b2f1f0808040933k61278982ha83f196f51fe8356@mail.gmail.com> On Mon, Aug 4, 2008 at 11:06 AM, Sam TH wrote: > On Mon, Aug 4, 2008 at 11:16 AM, Alan Watson wrote: >>>> The fact that let allow paralell bindings, do some folks take that >>>> fact and perform optimizations on multiple cpu boxes? Is it worth >>>> it? >>> >>> The values are parallel, but the computation is not. It's easy to >>> confuse the two, but it's a mistake. >> >> MPSCM[1] has a parallel let form. >> >> Eli, can you point me to language in the R5RS or R6RS that forbids >> interleaving the evaluation of the initializers in a standard let form? The >> R6RS just says, "The s are evaluated in the current environment (in >> some unspecified order)". I think that allows the evaluation of the >> initializers to be interleaved or parallelized. > > Looking at the R6RS, it appears that while the evaluation of arguments > may not be interleaved (the phrase is "consistent with some sequential > order"), that language is not used for `let'. So I believe that the > evaluation of `let' bindings may be interleaved. Section 1.9 seems to be saying that let and the corresponding left-left-lambda are equivalent. For those that want to look it up, the text Sam quotes is at the end of 9.1. This is what I was also referring to in my earlier message (the one with the example let expression). Robby From robby at cs.uchicago.edu Mon Aug 4 12:34:07 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:24:59 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <4C4B7BCE-6A72-4DE8-BEF4-190274CC619B@alan-watson.org> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> <932b2f1f0808040847m110fb054l8d1b4ac84e384aae@mail.gmail.com> <4C4B7BCE-6A72-4DE8-BEF4-190274CC619B@alan-watson.org> Message-ID: <932b2f1f0808040934v54865356x7b9f1d9187f06b8d@mail.gmail.com> On Mon, Aug 4, 2008 at 10:58 AM, Alan Watson wrote: >> The constraint is on the values produced, not on the evaluation order >> per se. > > I don't understand what you mean by this. I was referring to the text at the end of 9.1 in the R6RS. Robby From samth at ccs.neu.edu Mon Aug 4 12:39:34 2008 From: samth at ccs.neu.edu (Sam TH) Date: Thu Mar 26 02:25:00 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <932b2f1f0808040933k61278982ha83f196f51fe8356@mail.gmail.com> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> <63bb19ae0808040906h119edea7j86cab60a228da6cc@mail.gmail.com> <932b2f1f0808040933k61278982ha83f196f51fe8356@mail.gmail.com> Message-ID: <63bb19ae0808040939n44fa1a8ft4a2b28acc13539e1@mail.gmail.com> On Mon, Aug 4, 2008 at 12:33 PM, Robby Findler wrote: > On Mon, Aug 4, 2008 at 11:06 AM, Sam TH wrote: >> On Mon, Aug 4, 2008 at 11:16 AM, Alan Watson wrote: >>>>> The fact that let allow paralell bindings, do some folks take that >>>>> fact and perform optimizations on multiple cpu boxes? Is it worth >>>>> it? >>>> >>>> The values are parallel, but the computation is not. It's easy to >>>> confuse the two, but it's a mistake. >>> >>> MPSCM[1] has a parallel let form. >>> >>> Eli, can you point me to language in the R5RS or R6RS that forbids >>> interleaving the evaluation of the initializers in a standard let form? The >>> R6RS just says, "The s are evaluated in the current environment (in >>> some unspecified order)". I think that allows the evaluation of the >>> initializers to be interleaved or parallelized. >> >> Looking at the R6RS, it appears that while the evaluation of arguments >> may not be interleaved (the phrase is "consistent with some sequential >> order"), that language is not used for `let'. So I believe that the >> evaluation of `let' bindings may be interleaved. > > Section 1.9 seems to be saying that let and the corresponding > left-left-lambda are equivalent. It does seem that way for `let'. However, this leaves the status of `let*', `letrec', etc up in the air. I expect that this was an oversight on the part of the R6RS editors, and that the binding forms were intended to be required to be sequential. Matthew, is that correct? Thanks, -- sam th samth@ccs.neu.edu From noelwelsh at gmail.com Mon Aug 4 15:12:35 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:00 2009 Subject: [plt-scheme] ANN: SchemeUnit 3 Message-ID: Hi all, SchemeUnit 3 is out. The emphasis for this release is making testing really simple. The docs are here: http://planet.plt-scheme.org/package-source/schematics/schemeunit.plt/3/3/planet-docs/schemeunit/index.html A short essay (taken from the docs) explaining the new philosophy is below. Enjoy! N. The Philosophy of SchemeUnit SchemeUnit is designed to allow tests to evolve in step with the evolution of the program under testing. SchemeUnit scales from the unstructed checks suitable for simple programs to the complex structure necessary for large projects. Simple programs, such as those in How to Design Programs, are generally purely functional with no setup required to obtain a context in which the function may operate. Therefore the tests for these programs are extremely simple: the test expressions are single checks, usually for equality, and there are no dependencies between expressions. For example, a HtDP student may be writing simple list functions such as length, and the properties they are checking are of the form: (equal? (length null) 0) (equal? (length '(a)) 1) (equal? (length '(a b)) 2) SchemeUnit directly supports this style of testing. A check on its own is a valid test. So the above examples may be written in SchemeUnit as: (check-equal? (length null) 0) (check-equal? (length '(a)) 1) (check-equal? (length '(a b)) 2) Simple programs now get all the benefits of SchemeUnit with very little overhead. There are limitations to this style of testing that more complex programs will expose. For example, there might be dependencies between expressions, caused by state, so that it does not make sense to evaluate some expressions if earlier ones have failed. This type of program needs a way to group expressions so that a failure in one group causes evaluation of that group to stop and immediately proceed to the next group. In SchemeUnit all that is required is to wrap a test-begin expression around a group of expressions: (test-begin (setup-some-state!) (check-equal? (foo! 1) 'expected-value-1) (check-equal? (foo! 2) 'expected-value-2)) Now if any expression within the test-begin expression fails no further expressions in that group will be evaluated. Notice that all the previous tests written in the simple style are still valid. Introducing grouping is a local change only. This is a key feature of SchemeUnit's support for the evolution of the program. The programmer may wish to name a group of tests. This is done using the test-case expression, a simple variant on test-begin: (test-case "The name" ... test expressions ...) Most programs will stick with this style. However, programmers writing very complex programs may wish to maintain separate groups of tests for different parts of the program, or run their tests in different ways to the normal SchemeUnit manner (for example, test results may be logged for the purpose of improving software quality, or they may be displayed on a website to indicate service quality). For these programmers it is necessary to delay the execution of tests so they can processed in the programmer's chosen manner. To do this, the programmer simply wraps a test-suite around their tests: (test-suite "Suite name" (check ...) (test-begin ...) (test-case ...)) The tests now change from expressions that are immediately evaluated to objects that may be programmatically manipulated. Note again this is a local change. Tests outside the suite continue to evaluate as before. 2.1 Historical Context Most testing frameworks, including earlier versions of SchemeUnit, support only the final form of testing. This is likely due to the influence of the SUnit testing framework, which is the ancestor of SchemeUnit and the most widely used frameworks in Java, .Net, Python, and Ruby, and many other languages. That this is insufficient for all users is apparent if one considers the proliferation of "simpler" testing frameworks in Scheme such as SRFI-78, or the the practice of beginner programmers. Unfortunately these simpler methods are inadequate for testing larger systems. To the best of my knowledge SchemeUnit is the only testing framework that makes a conscious effort to support the testing style of all levels of programmer. From alan at alan-watson.org Mon Aug 4 15:24:37 2008 From: alan at alan-watson.org (Alan Watson) Date: Thu Mar 26 02:25:00 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: <63bb19ae0808040939n44fa1a8ft4a2b28acc13539e1@mail.gmail.com> References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> <63bb19ae0808040906h119edea7j86cab60a228da6cc@mail.gmail.com> <932b2f1f0808040933k61278982ha83f196f51fe8356@mail.gmail.com> <63bb19ae0808040939n44fa1a8ft4a2b28acc13539e1@mail.gmail.com> Message-ID: Thanks to Robby and Sam for their explanations. Regarding let*, ?11.4.6 says that "the ?init?s are evaluated and bindings created sequentially from left to right." No room for interleaving there. Nor in letrec*. However, I think letrec is still up for grabs. Regards, Alan -- Alan Watson http://www.alan-watson.org/ From jensaxel at soegaard.net Mon Aug 4 15:32:06 2008 From: jensaxel at soegaard.net (Jens Axel Soegaard) Date: Thu Mar 26 02:25:00 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> <63bb19ae0808040906h119edea7j86cab60a228da6cc@mail.gmail.com> <932b2f1f0808040933k61278982ha83f196f51fe8356@mail.gmail.com> <63bb19ae0808040939n44fa1a8ft4a2b28acc13539e1@mail.gmail.com> Message-ID: <48975936.10506@soegaard.net> Alan Watson wrote: > Thanks to Robby and Sam for their explanations. Regarding let*, > ?11.4.6 says that "the ?init?s are evaluated and bindings created > sequentially from left to right." No room for interleaving there. If you can prove that interleaving the s give the same result as when the bindings are evaluated and created sequentially (e.g. when all s are without side effects), then no one would know if you evaluated then in parallel. -- Jens Axel S?gaard From samth at ccs.neu.edu Mon Aug 4 15:38:04 2008 From: samth at ccs.neu.edu (Sam TH) Date: Thu Mar 26 02:25:00 2009 Subject: [plt-scheme] V4 request for thoughts on various question In-Reply-To: References: <756daca50808031319s1a165b6bx877dea4f7b6d156d@mail.gmail.com> <18582.7237.745135.866471@arabic.ccs.neu.edu> <9F1E8536-3B1A-4F7D-9FA8-8E6933ED3B6A@alan-watson.org> <63bb19ae0808040906h119edea7j86cab60a228da6cc@mail.gmail.com> <932b2f1f0808040933k61278982ha83f196f51fe8356@mail.gmail.com> <63bb19ae0808040939n44fa1a8ft4a2b28acc13539e1@mail.gmail.com> Message-ID: <63bb19ae0808041238v79aa3e7tf215785812f03c52@mail.gmail.com> On Mon, Aug 4, 2008 at 3:24 PM, Alan Watson wrote: > Thanks to Robby and Sam for their explanations. Regarding let*, ?11.4.6 says > that "the ?init?s are evaluated and bindings created sequentially from left > to right." No room for interleaving there. Nor in letrec*. However, I think > letrec is still up for grabs. Definitely. Certainly the semantics of `letrec*' and `let*' are unambiguous in this regard. I expect that the underspecification here of `let' (the discussion Robby points to does not seem to be intended as defining the semantics of `let') and `letrec' is merely an oversight by the editors. Thanks, -- sam th samth@ccs.neu.edu From grettke at acm.org Mon Aug 4 15:41:25 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:01 2009 Subject: [plt-scheme] ANN: SchemeUnit 3 In-Reply-To: References: Message-ID: <756daca50808041241h119c8a09t799eee8c5239f2a6@mail.gmail.com> > To the best of my knowledge > SchemeUnit is the only testing framework that makes a conscious effort > to support the testing style of all levels of programmer. Looks great, thanks Noel. From morazanm at gmail.com Mon Aug 4 16:06:18 2008 From: morazanm at gmail.com (Marco Morazan) Date: Thu Mar 26 02:25:01 2009 Subject: [plt-scheme] Design Recipe & Software Engineering Message-ID: <9b1fff280808041306i1707ddefqb69addaacf98a6e0@mail.gmail.com> Dear All, Anyone have a reference to work using the Design Recipe in Software Engineering? Any references citing the value of the Design Recipe in a SE project or a SE course will be useful. Cheers, Marco From matthias at ccs.neu.edu Mon Aug 4 17:05:16 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:01 2009 Subject: [plt-scheme] Re: [plt-edu] Design Recipe & Software Engineering In-Reply-To: <9b1fff280808041306i1707ddefqb69addaacf98a6e0@mail.gmail.com> References: <9b1fff280808041306i1707ddefqb69addaacf98a6e0@mail.gmail.com> Message-ID: <70E398CC-39E7-4F9C-B681-A1DD17621785@ccs.neu.edu> 1. I use it a course that I consider a bridge between programming and software engineering. It explain how the design recipe scales to large systems (and where it breaks). 2. Recently one of our PhD students wrote that he survived an interview at a widely known company more or less by just knowing how to interpret HtDP and the design recipe for them. -- Matthias On Aug 4, 2008, at 4:06 PM, Marco Morazan wrote: > Dear All, > > Anyone have a reference to work using the Design Recipe in Software > Engineering? Any references citing the value of the Design Recipe in a > SE project or a SE course will be useful. > > Cheers, > > Marco > _________________________________________________ > PLT Educators mailing list > plt-edu@list.cs.brown.edu > http://list.cs.brown.edu/mailman/listinfo/plt-edu From icfp.publicity at googlemail.com Mon Aug 4 17:43:20 2008 From: icfp.publicity at googlemail.com (Matthew Fluet (ICFP Publicity Chair)) Date: Thu Mar 26 02:25:01 2009 Subject: [plt-scheme] ICFP08 Call for Participation Message-ID: <53ff55480808041443o5d17a0b2j5112230bf48cfcf4@mail.gmail.com> ===================================================================== Call for Participation The 13th ACM SIGPLAN International Conference on Functional Programming (ICFP 2008) http://www.icfpconference.org/icfp2008 Victoria, BC, Canada, 22-24 September 2008 ===================================================================== ICFP 2008 provides a forum for researchers and developers to hear about the latest work on the design, implementations, principles, and uses of functional programming. The conference covers the entire spectrum of work, from practice to theory, including its peripheries. Preliminary program: * http://www.icfpconference.org/icfp2008/schedule.html * Invited speakers: + Butler Lampson, Microsoft Research; Lazy and Speculative Execution in Computer Systems + Olivier Danvy, University of Aarhus; Defunctionalized Interpreters for Higher-Order Languages + Mark Jones, Portland State University; Polymorphism and Page Tables -- Systems Programming From a Functional Programmer's Perspective Schedule including related workshops: * Sep 20: ACM SIGPLAN Workshop on Generic Programming * Sep 20: ACM SIGPLAN Workshop on Mechanizing Metatheory * Sep 20: ACM SIGPLAN Workshop on Scheme and Functional Programming * Sep 21: ACM SIGPLAN Workshop on ML * Sep 21: ACM SIGPLAN Functional and Declarative Programming in Education * Sep 22-24: ICFP08 * Sep 25: ACM SIGPLAN Haskell Symposium * Sep 25: Functional Programming Developer Tracks * Sep 26: Commercial Users of Functional Programming * Sep 27: ACM SIGPLAN Erlang Workshop * Sep 27: Functional Programming Developer Tracks Registration information: * http://www.regmaster.com/conf/icfp2008.html * Early registration deadline: August 20, 2008 Conference hotel accommodation information: * http://www.deltahotels.com/groups/online/VIC/acm.php * Conference rate deadline: August 18, 2008 * Wiki page to coordinate room-sharing: http://www.icfpconference.org/pmwiki/pmwiki.php?n=Main.ICFP08RoomShare Conference organizers: * General Chair: James Hook (Portland State University) * Program Chair: Peter Thiemann (Universit?t Freiburg) * Local Arrangements Chair: George Tzanetakis (University of Victoria) * Workshop Co-Chairs: Michael Sperber (DeinProgramm) and Graham Hutton (University of Nottingham) * Programming Contest Co-Chairs: John Reppy (University of Chicago) and Tim Sheard (Portland State University) * Publicity Chair: Matthew Fluet (Toyota Technological Institute at Chicago) From info at reatlas.com Mon Aug 4 17:47:51 2008 From: info at reatlas.com (Ethan Herdrick) Date: Thu Mar 26 02:25:02 2009 Subject: [plt-scheme] Which packages on Planet work with v4? Message-ID: <91f48dbf0808041447v1dbce560y305ba15f634030af@mail.gmail.com> Is there a way for users to know if a package in Planet is compatible with v4 before using it and watching it crash? It would be a useful thing to say on each package home page. The question arises because the indispensable HtmlPrag doesn't work with v4 yet. (It uses set-cdr! in a couple of places.) Perhaps it's a very rare case? -Ethan From s450r1 at gmail.com Mon Aug 4 17:49:25 2008 From: s450r1 at gmail.com (Jeff Dik) Date: Thu Mar 26 02:25:02 2009 Subject: [plt-scheme] MysterX only responding to COM events with no parameters Message-ID: Hi, I've been trying to get MysterX to respond to COM events for the past couple of days. The only COM events I can get it to respond to are events that do not have any parameters, for example, the OnQuit event for InternetExplorer.Application, the Click event for MSCAL.Calendar.7, and the PerformUserValidationTrigger for a COM component I use at work. Here is the Scheme script that I've been using to test Internet Explorer events: (module ie mzscheme (require mzlib/class) (require mysterx) (define ie (cci/progid "InternetExplorer.Application")) (com-register-event-handler ie "NavigateComplete2" (lambda args (display "NavigateComplete2\n"))) (com-register-event-handler ie "DocumentComplete" (lambda (pDisp url) (display "DocumentComplete\n"))) (com-register-event-handler ie "OnFullScreen" (lambda (fullscreen) (if fullscreen (display "Fullscreen\n") (display "Not Fullscreen\n")))) (com-register-event-handler ie "OnVisible" (lambda (visible) (if visible (display "Visible\n") (display "Not visible\n")))) (com-register-event-handler ie "OnQuit" (lambda args (display "Quit\n"))) (com-set-property! ie "Visible" #t) (com-invoke ie "Navigate" "http://www.google.com") ;; Wait (sync never-evt)) The only event that gets displayed is the "OnQuit" event. Here's the Scheme script I've been using to test Excel (taken from http://www.cs.brown.edu/pipermail/plt-scheme/2005-May/008836.html): (module excel mzscheme (require mysterx) (define excel (cci/progid "Excel.Application")) (com-set-property! excel "Visible" #t) (define workbook #f) (com-register-event-handler excel "NewWorkbook" (lambda(wb)(set! workbook wb)(printf "open ~a~%" wb))) (com-register-event-handler excel "WorkbookBeforeClose" (lambda(wb cancel)(printf "closing ~a ~a~%" wb cancel)(set-box! cancel #t))) ;; Wait (sync never-evt)) This script never displays any events. Does anybody know why the events with parameters are not working? I'm quite new to MysterX and have been using the MysterX PLT documentation, the "MysterX: A Scheme Toolkit for Building Interactive Applications with COM", "Component Support in PLT Scheme", and the mxdemo.ss script as documentation. If anybody knows of other good MysterX documentation, or has a script they would be willing to share, I'd greatly appreciate it. Thanks, Jeff From robby at cs.uchicago.edu Mon Aug 4 17:54:45 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:02 2009 Subject: [plt-scheme] Which packages on Planet work with v4? In-Reply-To: <91f48dbf0808041447v1dbce560y305ba15f634030af@mail.gmail.com> References: <91f48dbf0808041447v1dbce560y305ba15f634030af@mail.gmail.com> Message-ID: <932b2f1f0808041454g72be0990vc7545c2773ce5993@mail.gmail.com> I haven't survey'd them to find out how true this is, but the hope is that most packages will just work, so they were all included in the v4 repository by default. Robby On Mon, Aug 4, 2008 at 4:47 PM, Ethan Herdrick wrote: > Is there a way for users to know if a package in Planet is compatible > with v4 before using it and watching it crash? It would be a useful > thing to say on each package home page. > > The question arises because the indispensable HtmlPrag doesn't work > with v4 yet. (It uses set-cdr! in a couple of places.) Perhaps it's > a very rare case? > > -Ethan > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From yinso.chen at gmail.com Mon Aug 4 21:54:46 2008 From: yinso.chen at gmail.com (YC) Date: Thu Mar 26 02:25:02 2009 Subject: [plt-scheme] datum->syntax rules Message-ID: <779bf2730808041854g16d7ea6aof1f05eb1327499eb@mail.gmail.com> Hi - are there specific rules that governs the choice of context to datum->syntax? I'm finding that the choices of the context impacts whether the name can be captured, and are not seeing what the issues are... Below are two versions of `if-it` - the first version works with #'_, but the second version cannot work with it (it works with #'test). Any pointers are appreciated, thanks. yc (define-syntax (if-it stx) (syntax-case stx () ((_ test then else) (with-syntax ((it (datum->syntax #'_ 'it))) #'(let ((it test)) (if it test else)))))) (if-it '(abc def) it 'nil) ;; works (define-syntax (if-it1 stx) (syntax-case stx () ((_ test then else) (with-syntax ((it (datum->syntax #'_ ;; doesn't work... works if replaced with #'test 'it))) #'(let ((it test)) (if it then else) ))))) (if-it1 '(abc def) it 'nil) ;; => reference to undefined identifier: it -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080804/01d2193f/attachment.htm From czhu at cs.utah.edu Mon Aug 4 23:43:53 2008 From: czhu at cs.utah.edu (Chongkai Zhu) Date: Thu Mar 26 02:25:03 2009 Subject: [plt-scheme] datum->syntax rules In-Reply-To: <779bf2730808041854g16d7ea6aof1f05eb1327499eb@mail.gmail.com> References: <779bf2730808041854g16d7ea6aof1f05eb1327499eb@mail.gmail.com> Message-ID: <4897CC79.5000302@cs.utah.edu> The "_" in "(_ test then else)" is a special pattern that match's anything. So the #'_ given to datum->syntax is not binding to "if-it". This is a PLT v4 change. I think you want: (define-syntax (if-it stx) (syntax-case stx () ((if-it test then else) (with-syntax ((it (datum->syntax #'if-it 'it))) #'(let ((it test)) (if it then else) ))))) Chongkai YC wrote: > Hi - > > are there specific rules that governs the choice of context to > datum->syntax? I'm finding that the choices of the context impacts > whether the name can be captured, and are not seeing what the issues > are... > > Below are two versions of `if-it` - the first version works with #'_, > but the second version cannot work with it (it works with #'test). > > Any pointers are appreciated, thanks. > yc > > (define-syntax (if-it stx) > (syntax-case stx () > ((_ test then else) > (with-syntax ((it > (datum->syntax #'_ > 'it))) > #'(let ((it test)) > (if it test else)))))) > > (if-it '(abc def) it 'nil) ;; works > > (define-syntax (if-it1 stx) > (syntax-case stx () > ((_ test then else) > (with-syntax ((it > (datum->syntax #'_ ;; doesn't work... works if > replaced with #'test > 'it))) > #'(let ((it test)) > (if it then else) > ))))) > > (if-it1 '(abc def) it 'nil) ;; => reference to undefined identifier: it > > ------------------------------------------------------------------------ > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From grettke at acm.org Mon Aug 4 23:53:59 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:03 2009 Subject: [plt-scheme] Which packages on Planet work with v4? In-Reply-To: <91f48dbf0808041447v1dbce560y305ba15f634030af@mail.gmail.com> References: <91f48dbf0808041447v1dbce560y305ba15f634030af@mail.gmail.com> Message-ID: <756daca50808042053l65b5d078n3e91d6d469339a05@mail.gmail.com> http://list.cs.brown.edu/pipermail/plt-scheme/2008-June/025129.html From yinso.chen at gmail.com Tue Aug 5 00:44:54 2008 From: yinso.chen at gmail.com (YC) Date: Thu Mar 26 02:25:03 2009 Subject: [plt-scheme] datum->syntax rules In-Reply-To: <4897CC79.5000302@cs.utah.edu> References: <779bf2730808041854g16d7ea6aof1f05eb1327499eb@mail.gmail.com> <4897CC79.5000302@cs.utah.edu> Message-ID: <779bf2730808042144x3de1e4adp7d87312c08663489@mail.gmail.com> On Mon, Aug 4, 2008 at 8:43 PM, Chongkai Zhu wrote: > The "_" in "(_ test then else)" is a special pattern that match's anything. > So the #'_ given to datum->syntax is not binding to "if-it". This is a PLT > v4 change. I think you want: > Thanks Chongkai for the explanation. In that case, why does the first version work? Does #'_ sometimes binds against the identifier and sometimes not? Thanks, yc -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080804/6947498e/attachment.html From jomirez at gmail.com Tue Aug 5 00:53:11 2008 From: jomirez at gmail.com (Jose Ramirez) Date: Thu Mar 26 02:25:04 2009 Subject: [plt-scheme] PLT: How do you guys do it? In-Reply-To: <932b2f1f0808031427v3a84be54r401a2a149b309b6@mail.gmail.com> References: <756daca50808031341u77c3aafeg445b2e4d8a34dbd@mail.gmail.com> <6E087CDE-A3E6-4767-9F34-C7BA60739B88@ccs.neu.edu> <932b2f1f0808031427v3a84be54r401a2a149b309b6@mail.gmail.com> Message-ID: <89c11d70808042153n2cd6e280u7b25042e569617c7@mail.gmail.com> And besides pushing PLT on those new-generation weapons of mass destruction, powering www.white-slaves.com also fetched a few bucks, n'est?ce pas? ;-))) PS: no offense intended, your answers were so inspiring i just had to take them to another level ;-) On Sun, Aug 3, 2008 at 11:27 PM, Robby Findler wrote: > Oh, that and we've all moved into monasteries to shield us from > Temptations to Stray from the One True Way. > > Robby > > On Sun, Aug 3, 2008 at 4:24 PM, Matthias Felleisen wrote: >> >> We're playing the DC lottery, which tends to have slightly better odds than >> the one in other states. -- Matthias From czhu at cs.utah.edu Tue Aug 5 00:58:25 2008 From: czhu at cs.utah.edu (Chongkai Zhu) Date: Thu Mar 26 02:25:04 2009 Subject: [plt-scheme] datum->syntax rules In-Reply-To: <779bf2730808042144x3de1e4adp7d87312c08663489@mail.gmail.com> References: <779bf2730808041854g16d7ea6aof1f05eb1327499eb@mail.gmail.com> <4897CC79.5000302@cs.utah.edu> <779bf2730808042144x3de1e4adp7d87312c08663489@mail.gmail.com> Message-ID: <4897DDF1.8070106@cs.utah.edu> YC wrote: > > In that case, why does the first version work? Does #'_ sometimes > binds against the identifier and sometimes not? > No, #'_ never binds against the identifier. Your first version is exactly the same as (define-syntax (if-it stx) (syntax-case stx () ((_ test then else) #'(let ((it test)) (if it test else))))) With is the same as (define-syntax (if-it stx) (syntax-case stx () ((_ test then else) #'(if test test else)))) I can only say you confused yourself. Chongkai > Thanks, > yc > From cce at ccs.neu.edu Tue Aug 5 01:13:12 2008 From: cce at ccs.neu.edu (Carl Eastlund) Date: Thu Mar 26 02:25:04 2009 Subject: [plt-scheme] datum->syntax rules In-Reply-To: <779bf2730808041854g16d7ea6aof1f05eb1327499eb@mail.gmail.com> References: <779bf2730808041854g16d7ea6aof1f05eb1327499eb@mail.gmail.com> Message-ID: <990e0c030808042213w7c159392k1f1947d37cc0e8ab@mail.gmail.com> You have a typo - one version of the macro has (if it test else), the other has (if it then else). The version with (if it test else) never actually uses the "then" clause, which is where you refer to "it". That's why it doesn't get a syntax error. It's not that "it" is bound correctly, it's that you discard the reference. --Carl On Mon, Aug 4, 2008 at 9:54 PM, YC wrote: > Hi - > > are there specific rules that governs the choice of context to > datum->syntax? I'm finding that the choices of the context impacts whether > the name can be captured, and are not seeing what the issues are... > > Below are two versions of `if-it` - the first version works with #'_, but > the second version cannot work with it (it works with #'test). > > Any pointers are appreciated, thanks. > yc > > (define-syntax (if-it stx) > (syntax-case stx () > ((_ test then else) > (with-syntax ((it > (datum->syntax #'_ > 'it))) > #'(let ((it test)) > (if it test else)))))) > > (if-it '(abc def) it 'nil) ;; works > > (define-syntax (if-it1 stx) > (syntax-case stx () > ((_ test then else) > (with-syntax ((it > (datum->syntax #'_ ;; doesn't work... works if replaced > with #'test > 'it))) > #'(let ((it test)) > (if it then else) > ))))) > > (if-it1 '(abc def) it 'nil) ;; => reference to undefined identifier: it From yinso.chen at gmail.com Tue Aug 5 01:20:15 2008 From: yinso.chen at gmail.com (YC) Date: Thu Mar 26 02:25:04 2009 Subject: [plt-scheme] datum->syntax rules In-Reply-To: <990e0c030808042213w7c159392k1f1947d37cc0e8ab@mail.gmail.com> References: <779bf2730808041854g16d7ea6aof1f05eb1327499eb@mail.gmail.com> <990e0c030808042213w7c159392k1f1947d37cc0e8ab@mail.gmail.com> Message-ID: <779bf2730808042220o1c264880mf4695051cd99de55@mail.gmail.com> On Mon, Aug 4, 2008 at 10:13 PM, Carl Eastlund wrote: > You have a typo - one version of the macro has (if it test else), the > other has (if it then else). The version with (if it test else) never > actually uses the "then" clause, which is where you refer to "it". > That's why it doesn't get a syntax error. It's not that "it" is bound > correctly, it's that you discard the reference. > Ah I see - Thanks for catching this typo for me... I literally stared at the issue for hours... :) Thanks Chongkai for the explanation as well. yc -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080804/35473927/attachment.htm From jadudm at gmail.com Tue Aug 5 10:36:55 2008 From: jadudm at gmail.com (Matt Jadud) Date: Thu Mar 26 02:25:05 2009 Subject: [plt-scheme] Which packages on Planet work with v4? In-Reply-To: <932b2f1f0808041454g72be0990vc7545c2773ce5993@mail.gmail.com> References: <91f48dbf0808041447v1dbce560y305ba15f634030af@mail.gmail.com> <932b2f1f0808041454g72be0990vc7545c2773ce5993@mail.gmail.com> Message-ID: Hi Robby, On Mon, Aug 4, 2008 at 5:54 PM, Robby Findler wrote: > I haven't survey'd them to find out how true this is, but the hope is > that most packages will just work, so they were all included in the v4 > repository by default. > > Robby I'm not sure if including things in the v4 repos by default is a good idea. When I tried to update a library there, I found that the majority of the libraries I depended on had not been ported. As I don't have the time to update all the libraries I depend on myself, I need to pull my library until the world catches up. Basically, automatically promoting v3 libraries to v4 makes PLaneT seem like a place where "code that may-or-may-not work" lives. Cheers, Matt From cce at ccs.neu.edu Tue Aug 5 10:58:47 2008 From: cce at ccs.neu.edu (Carl Eastlund) Date: Thu Mar 26 02:25:05 2009 Subject: [plt-scheme] Which packages on Planet work with v4? In-Reply-To: References: <91f48dbf0808041447v1dbce560y305ba15f634030af@mail.gmail.com> <932b2f1f0808041454g72be0990vc7545c2773ce5993@mail.gmail.com> Message-ID: <990e0c030808050758x564481d3y373fefa03c7c0218@mail.gmail.com> On Tue, Aug 5, 2008 at 10:36 AM, Matt Jadud wrote: > > I'm not sure if including things in the v4 repos by default is a good > idea. When I tried to update a library there, I found that the > majority of the libraries I depended on had not been ported. As I > don't have the time to update all the libraries I depend on myself, I > need to pull my library until the world catches up. > > Basically, automatically promoting v3 libraries to v4 makes PLaneT > seem like a place where "code that may-or-may-not work" lives. > > Cheers, > Matt On the other hand, if we don't, packages that do still work would be unavailable until such time as their author went in and enabled them. Since it is not always clear how to contact an author, or when they will respond, it seems better (to me, at least) to make potentially bad code available than to make potentially good code unavailable. Perhaps we might have improved the situation by leaving old packages out of the v4 repository, but providing a way to explicitly access the v372 repository from v4 code. I just made that up as I typed it, though, so no one may have thought of it before. -- Carl Eastlund From grettke at acm.org Tue Aug 5 11:38:08 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:05 2009 Subject: [plt-scheme] Which packages on Planet work with v4? In-Reply-To: <990e0c030808050758x564481d3y373fefa03c7c0218@mail.gmail.com> References: <91f48dbf0808041447v1dbce560y305ba15f634030af@mail.gmail.com> <932b2f1f0808041454g72be0990vc7545c2773ce5993@mail.gmail.com> <990e0c030808050758x564481d3y373fefa03c7c0218@mail.gmail.com> Message-ID: <756daca50808050838t2f8e2567n8ade33ff6d992f54@mail.gmail.com> > Perhaps we might have improved the situation by leaving old packages > out of the v4 repository, but providing a way to explicitly access the > v372 repository from v4 code. That sounds perfect. Is it difficult? From robby at cs.uchicago.edu Tue Aug 5 11:39:36 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:05 2009 Subject: [plt-scheme] Which packages on Planet work with v4? In-Reply-To: <756daca50808050838t2f8e2567n8ade33ff6d992f54@mail.gmail.com> References: <91f48dbf0808041447v1dbce560y305ba15f634030af@mail.gmail.com> <932b2f1f0808041454g72be0990vc7545c2773ce5993@mail.gmail.com> <990e0c030808050758x564481d3y373fefa03c7c0218@mail.gmail.com> <756daca50808050838t2f8e2567n8ade33ff6d992f54@mail.gmail.com> Message-ID: <932b2f1f0808050839h3732a0a4k1c257d284666d4fb@mail.gmail.com> I don't think that will work. It goes against the grain of how planet is set up internally (iiuc). Robby On Tue, Aug 5, 2008 at 10:38 AM, Grant Rettke wrote: >> Perhaps we might have improved the situation by leaving old packages >> out of the v4 repository, but providing a way to explicitly access the >> v372 repository from v4 code. > > That sounds perfect. Is it difficult? > > From wookiz at hotmail.com Tue Aug 5 15:01:02 2008 From: wookiz at hotmail.com (wooks) Date: Thu Mar 26 02:25:05 2009 Subject: [plt-scheme] Reasons to be cheerful Message-ID: Something to look forward to. Lately, I have moved from industry to academia and now see the education problems from a different angle. We need to improve the education of our software developers. Over the last three years, I have developed a new course for freshmen (first-year students, often first-time programmers). This has given me the opportunity to address an audience I have never before known well and the result is a beginner's textbook "Programming: Principles and Practice using C++" which will be available in October. http://www.computerworld.com.au/index.php/id;1422447371 From dtp at mindstory.com Tue Aug 5 22:45:17 2008 From: dtp at mindstory.com (David T. Pierson) Date: Thu Mar 26 02:25:05 2009 Subject: [plt-scheme] 4.0.2 on OS X 10.3.9 Message-ID: <20080806024517.GA2145@yoshi.local> Hi, The download page for 4.0.2 says: System Requirements: ... Mac OS X (10.3 and up) I am trying to use 4.0.2 on a PowerPC Mac running OS X 10.3.9. The GUI apps like DrScheme don't come up when launched (no windows, no error messages, nothing). The command-line tools give me an error like this: $ /Applications/PLT\ Scheme\ v4.0.2/bin/mzscheme dyld: /Applications/PLT Scheme v4.0.2/bin/mzscheme Undefined symbols: PLT_MzScheme undefined reference to ___stderrp expected to be defined in /usr/lib/libSystem.B.dylib Trace/BPT trap Is 10.3 really supported? Any suggestions? Thanks. David From cce at ccs.neu.edu Wed Aug 6 01:58:44 2008 From: cce at ccs.neu.edu (Carl Eastlund) Date: Thu Mar 26 02:25:06 2009 Subject: [plt-scheme] 4.0.2 on OS X 10.3.9 In-Reply-To: <20080806024517.GA2145@yoshi.local> References: <20080806024517.GA2145@yoshi.local> Message-ID: <990e0c030808052258r53cbf67dn8e386a5d7e6ff79f@mail.gmail.com> I reported this previously as bug 9549, for version 4.0.1: http://bugs.plt-scheme.org/query/?cmd=view&pr=9549 It works when built from source on the same system, so it's probably a matter of compatibility between Mac OS 10.3.9 and whatever the release was built on (10.4.something, I believe). You should be able to build it from source as a workaround, if you have the developer tools installed; meanwhile, I'll see if someone can whip up a 10.3.9-compatible version of the release. --Carl On Tue, Aug 5, 2008 at 10:45 PM, David T. Pierson wrote: > Hi, > > The download page for 4.0.2 says: > > System Requirements: ... Mac OS X (10.3 and up) > > I am trying to use 4.0.2 on a PowerPC Mac running OS X 10.3.9. The GUI > apps like DrScheme don't come up when launched (no windows, no error > messages, nothing). The command-line tools give me an error like this: > > $ /Applications/PLT\ Scheme\ v4.0.2/bin/mzscheme > dyld: /Applications/PLT Scheme v4.0.2/bin/mzscheme Undefined symbols: > PLT_MzScheme undefined reference to ___stderrp expected to be defined in /usr/lib/libSystem.B.dylib > Trace/BPT trap > > Is 10.3 really supported? Any suggestions? > > Thanks. > > David From egarrulo at gmail.com Wed Aug 6 04:37:15 2008 From: egarrulo at gmail.com (Elena Garrulo) Date: Thu Mar 26 02:25:06 2009 Subject: [plt-scheme] PLT Scheme FFI on Win32: handling structures and byte arrays Message-ID: <9bd8a08a0808060137s1d5de2aaj11e3706c2c2d2dad@mail.gmail.com> Hello, I'm trying out PLT Scheme FFI on WIn32. Examples included into the distribution show only simpler cases. Here is the C snippet I'm trying to translate: typedef unsigned char BYTE; typedef BYTE* LPBYTE; typedef const BYTE* LPCBYTE; typedef unsigned long DWORD; typedef DWORD* LPDWORD; typedef void* SCARDHANDLE; // Just an handle. typedef struct _SCARD_IO_REQUEST{ DWORD dwProtocol; // Protocol identifier DWORD cbPciLength; // Protocol Control Information Length } SCARD_IO_REQUEST, *PSCARD_IO_REQUEST, *LPSCARD_IO_REQUEST; typedef const SCARD_IO_REQUEST *LPCSCARD_IO_REQUEST; LONG SCardTransmit( /* IN */ SCARDHANDLE hCard, /* IN */ LPCSCARD_I0_REQUEST pioSendPci, /* IN */ LPCBYTE pbSendBuffer, /* IN */ DWORD cbSendLength, /* OUT */ LPSCARD_IO_REQUEST pioRecvPci, /* OUT */ LPBYTE pbRecvBuffer, /* OUT */ LPDWORD pcbRecvLength ); Here the resulting PLT Scheme code, with compiler errors: (module winscard mzscheme (require mzlib/foreign) (unsafe!) (define _DWORD _int) ;; It should be 32 bits unsigned integer. (define _LONG _int) ;; OK: 32 bits integer. (define _SCARDHANDLE _int) ;; This is an handle, I'd prefer using a "typed" integer for type checking. (define-cstruct _SCARD_IO_REQUEST ((dwProtocol _DWORD) ;; // Protocol identifier (cbPciLength _DWORD))) ;; // Protocol Control Information Length (define winscard (ffi-lib "winscard")) ;; [simpler functions not included] (provide scard-transmit) (define-struct scard-transmit-result (error recv-pci recv-buffer recv-length)) (define scard-transmit (get-ffi-obj "SCardTransmit" winscard (_fun (hCard : _SCARDHANDLE) (pioSendPci : _SCARD_I0_REQUEST-pointer) ;; ERROR: expand: unbound variable in module in: __SCARD_I0_REQUEST-pointer (pbSendBuffer : (_cvector i _byte)) ;; ERROR: expand: unbound variable in module in: i (cbSendLength : _DWORD) (ioRecvPci : (_ptr o _SCARD_IO_REQUEST)) (pbRecvBuffer : (_cvector o _byte )) ;; ERROR: expand: unbound variable in module in: o (cbRecvLength : (_ptr o _DWORD)) -> (error : _LONG) -> (make-scard-transmit-result error ioRecvPci pbRecvBuffer cbRecvLength)))) ) What's wrong? And what about byte aligned, word aligned, double word aligned structures? What about calling conventions? Thanks -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080806/d152f45b/attachment.html From noelwelsh at gmail.com Wed Aug 6 07:29:54 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:07 2009 Subject: [plt-scheme] Error building docs for docs.plt-scheme.org and local copy Message-ID: Hi all, The docs on http://docs.plt-scheme.org/reference/ and in my local PLT install all have a broken stylesheet. The problem is the link to the stylesheet is "../scribble.css", and that file doesn't exist. Should be just scribble.css methinks. N. From jpc-ml at zenburn.net Wed Aug 6 07:41:18 2008 From: jpc-ml at zenburn.net (=?UTF-8?B?SmFrdWIgUGlvdHIgQ8WCYXBh?=) Date: Thu Mar 26 02:25:07 2009 Subject: [plt-scheme] PLT Scheme FFI on Win32: handling structures and byte arrays In-Reply-To: <9bd8a08a0808060137s1d5de2aaj11e3706c2c2d2dad@mail.gmail.com> References: <9bd8a08a0808060137s1d5de2aaj11e3706c2c2d2dad@mail.gmail.com> Message-ID: <48998DDE.5010704@zenburn.net> Elena Garrulo wrote: > I'm trying out PLT Scheme FFI on WIn32. Examples included into the > distribution show only simpler cases. IMHO the distribution could use some more elaborate examples. It's just that there is little code in the wild using the PLT Scheme FFI. > (pioSendPci : _SCARD_I0_REQUEST-pointer) ;; ERROR: expand: unbound variable in module in: __SCARD_I0_REQUEST-pointer I guess it should be IO instead of I0. > (pbSendBuffer : (_cvector i _byte)) ;; ERROR: expand: unbound variable in module in: i Should be _vector here, not _cvector. > (pbRecvBuffer : (_cvector o _byte )) ;; ERROR: expand: unbound variable in module in: o For output vectors you need the length so try this: (pbRecvBuffer : (_vector o _byte cbRecvLength)) (cbRecvLength : (_ptr io _DWORD)) Quote from the manual: #v+ The optional len argument is needed for output values where it is used in the post code, and in the pre code of an output mode to allocate the block. In either case, it can refer to a previous binding for the length of the list which the C function will most likely require. #v- Btw. Eli, as can be seen here we can refer to a following binding as well. Maybe the docs could use some clarification? > And what about byte aligned, word aligned, double word aligned > structures? What about calling conventions? Everything is handled by libffi. -- regards, Jakub Piotr C?apa From jpc-ml at zenburn.net Wed Aug 6 07:42:13 2008 From: jpc-ml at zenburn.net (=?UTF-8?B?SmFrdWIgUGlvdHIgQ8WCYXBh?=) Date: Thu Mar 26 02:25:07 2009 Subject: [plt-scheme] Error building docs for docs.plt-scheme.org and local copy In-Reply-To: References: Message-ID: <48998E15.7090706@zenburn.net> Noel Welsh wrote: > Hi all, > > The docs on http://docs.plt-scheme.org/reference/ and in my local PLT > install all have a broken stylesheet. The problem is the link to the > stylesheet is "../scribble.css", and that file doesn't exist. Should > be just scribble.css methinks. The index page is missing as well. The link from the front page takes you to the Apache directory index. -- regards, Jakub Piotr C?apa From noelwelsh at gmail.com Wed Aug 6 07:43:46 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:07 2009 Subject: [plt-scheme] Reasons to be cheerful In-Reply-To: References: Message-ID: The link given seems to go the wrong place (a Luca Cardelli interview) but information on the book is here: http://www.research.att.com/~bs/programming.html N. On Tue, Aug 5, 2008 at 8:01 PM, wooks wrote: > Something to look forward to. > > Lately, I have moved from industry to academia and now see the > education problems from a different angle. We need to improve the > education of our software developers. Over the last three years, I > have developed a new course for freshmen (first-year students, often > first-time programmers). This has given me the opportunity to address > an audience I have never before known well and the result is a > beginner's textbook "Programming: Principles and Practice using C++" > which will be available in October. > > http://www.computerworld.com.au/index.php/id;1422447371 From icfp.publicity at googlemail.com Wed Aug 6 21:37:36 2008 From: icfp.publicity at googlemail.com (Matthew Fluet (ICFP Publicity Chair)) Date: Thu Mar 26 02:25:07 2009 Subject: [plt-scheme] DEFUN 2008 (Developer Tracks on Functional Programming): Call for participation Message-ID: <53ff55480808061837u164441d9xb0ba44ad7551a123@mail.gmail.com> ACM SIGPLAN 2008 Developer Tracks on Functional Programming http://www.deinprogramm.de/defun-2008/ Victoria, BC, Canada, 25, 27 September, 2008 Held in conjunction with ICFP 2008: http://www.icfpconference.org/icfp2008/ DEFUN 2008 is the event for developers using functional languages: Recognized experts on functional programming technologies share their knowledge and professional skills in talks and tutorials in 10 exciting tracks. Find out how to best make functional programming work in your development project! Acquire new development skills! Learn about other functional languages! The DEFUN program (attached) has tracks with the following types of presentations: - Half-day general language tutorials for specific functional languages, given by recognized experts for the respective languages. - Half-day tutorials on specific techniques or the use of specific technologies in functional programming. - 45-minute "how-to" talks that provide specific information on how to solve specific problems using functional programming. These talks focus on concrete examples, but provide useful information for developers working on different projects or in different contexts. The developer tracks are complementary to ICFP itself (which is for researchers). They are anchored by CUFP, the Haskell Symposium, and the Erlang workshop. Organizers Kathleen Fisher AT&T Labs Simon Peyton Jones Microsoft Research Mike Sperber (co-chair) DeinProgramm Don Stewart (co-chair) Galois PROGRAM: Note: The sessions of a given morning or afternoon are concurrent. The markers (M1, M2, A1, A2, etc.) mark a particular session, and correspond to the designations on the registration forms. Note that the talks M5 together constitute a session. DAY 1 - 25 SEPTEMBER, 2008 MORNING SESSION M1 (Tutorial): Practical Erlang Programming Francesco Cesarini Erlang Training and Consulting M2 (Tutorial): A Gentle Introduction to Functional Information Visualization Jefferson Heard Renaissance Computing Institute, University of North Carolina M3 (Tutorial): JavaScript: from basics to building custom frameworks Sameer Sundresh and Erik Hinterbichler University of Illinois Urbana-Champaign and Pattern Insight, Inc. AFTERNOON SESSION A1 (Tutorial): Erlang DBG and the Trace Biff Tamas Nagy Erlang Training and Consulting A2 (Tutorial): Erlang QuickCheck Tutorial Thomas Arts IT University of Gothenburg and Quviq A3 (Tutorial): Practical and Portable Programming in Scheme Donovan Kolbly TippingPoint Technologies DAY 2 - 27 SEPTEMBER 2008 MORNING SESSION M4 (Tutorial): Real World Haskell Bryan O'Sullivan M5 (Talks): Ten one-liners: handling power series in Haskell Doug McIlroy Dartmouth Incremental multi-level input processing with left-fold enumerator Oleg Kiselyov How we locate wild animals with a functional program Ryan Newton MIT AFTERNOON SESSION A4 (Tutorial): Using QuickCheck and HPC - Obtaining Quality Assurance for Haskell Code Andy Gill Kansas University Koen Claessen Chalmers A5 (Tutorial): Introduction to F# Don Syme and Chris Smith Microsoft Research From DekuDekuplex at Yahoo.com Wed Aug 6 23:36:15 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:25:07 2009 Subject: [plt-scheme] Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] References: Message-ID: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> In the following recent thread on comp.lang.scheme, in the Preface of _Sketchy LISP: An Introduction to Functional Programming in Scheme,_ the author, Nils M. Holm points out an inconsistency between the original spirit of a small, succinct language, as stated in the Introduction to RnRS, and some of the changes in R6RS. According to the following document, the community standards document for R5RS Scheme used to fit in fifty pages: Scheme R5RS Manual > Programming and Technical Books > Bartlett Publishing | CafePress http://www.cafepress.com/bartlettpublish.9174125 > The Scheme programming language is one of the under-appreciated gems > of the computer science community. It has a form and beauty that is > simplyUnmatched [sic] by any other programming language.It's simplicity > speaks for itself - this community standards document is only 50 pages long. > It is just like Scheme - small, elegant, efficient, and complete. The following is the reference to Holm's book: On Wed, 6 Aug 2008 11:10:08 +0000 (UTC), Nils M Holm wrote: >I am happy to announce the third edition of my textbook > >Sketchy LISP >An Introduction to Functional Programming in Scheme > >[...] > >Where to get it > >The full text of this edition can be viewed online. Paper copies >and inexpensive PDF files can be purchased at Lulu.com. > >Online Edition: http://www.t3x.org/sketchy/vol1/ > >Paper copies and PDF files: http://www.lulu.com/content/213736/ In his Preface to his Third Edition, he writes as follows: >Programming languages should be designed not by piling feature on top of >feature, but by removing the weaknesses and restrictions that make >additional features appear necessary. >-- RnRS introduction >[see http://www.r6rs.org/final/html/r6rs/r6rs-Z-H-3.html#node_chap_Temp_3] > >Unfortunately this principle was abandoned in the R6RS process. I >created this edition in the hope that enough people will stay interested >in the small and beautiful language that Scheme used to be, so the R5RS >will remain a de-facto standard. According to the following document, he seems to be correct: Revised^6 Report on the Algorithmic Language Scheme - Appendix E - Language Changes http://www.r6rs.org/final/html/r6rs/r6rs-Z-H-19.html#node_chap_E > * Libraries have been added to the language. > > * The old notion of program structure and Scheme$B!G(Bs top-level environment >has been replaced by top-level programs and libraries. I have been reading through the recent R6RS-related threads in the plt-scheme mailing list, and it seems that PLT Scheme is heading toward becoming an R6RS-interoperable variant of Scheme. However, I am concerned about the direction of the future evolution of PLT Scheme. One of the main reasons that I preferred Scheme over Common Lisp was the succinctness of Scheme, caused precisely by the lack of libraries. One of the main reasons that I stopped studying Java was precisely the huge growth in libraries. How does PLT Scheme plan to address the apparent inconsistency between the above-mentioned original guiding principle of RnRS Scheme and the above-mentioned changes in R6RS Scheme? I have an ominous feeling of dark clouds approaching.... I just hope that Scheme doesn't become the kind of monstrosity that Java and Common Lisp have become, requiring constant flipping through huge library reference manuals just to use. That makes Scheme just another huge collection of libraries, rather than a small, elegant, and complete adaptable precision tool.... -- Benjamin L. Russell From samth at ccs.neu.edu Wed Aug 6 23:56:55 2008 From: samth at ccs.neu.edu (Sam TH) Date: Thu Mar 26 02:25:08 2009 Subject: [plt-scheme] Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] In-Reply-To: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> References: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> Message-ID: <63bb19ae0808062056k4d3b60fqf8fa377605c7fd90@mail.gmail.com> 2008/8/6 Benjamin L. Russell : > I have been reading through the recent R6RS-related threads in the > plt-scheme mailing list, and it seems that PLT Scheme is heading > toward becoming an R6RS-interoperable variant of Scheme. However, I > am concerned about the direction of the future evolution of PLT > Scheme. > > One of the main reasons that I preferred Scheme over Common Lisp > was the succinctness of Scheme, caused precisely by the lack of > libraries. One of the main reasons that I stopped studying Java was > precisely the huge growth in libraries. How does PLT Scheme plan to > address the apparent inconsistency between the above-mentioned > original guiding principle of RnRS Scheme and the above-mentioned > changes in R6RS Scheme? Prior to the beginning of the R6RS process, PLT Scheme already had a library system of more complexity than that of the R6RS (and a wonderful library system it is, too). PLT Scheme also has a vast standard library, much larger than that specified by R6RS. However, I and probably many other PLT people would take issue with the idea that there is a tension between the guiding principles of Scheme, as expressed in both the R5RS and R6RS and the design of PLT Scheme. We strive to create powerful, extensible and flexible language features, that we can combine do new things in new ways, and to give programmers expressiveness as well as access to lots of built-in features. The greater complexity of everything since the days when Steele and Sussman invented Scheme mean that PLT Scheme is larger than those systems, but that's not a flaw. So in sum, I don't think there's an inconsistency, but if you think there is one, then PLT Scheme is already on the R6RS side. Thanks, -- sam th samth@ccs.neu.edu From mvanier42 at gmail.com Wed Aug 6 23:59:51 2008 From: mvanier42 at gmail.com (Michael Vanier) Date: Thu Mar 26 02:25:08 2009 Subject: [plt-scheme] Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] In-Reply-To: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> References: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> Message-ID: <489A7337.40800@cs.caltech.edu> Benjamin, I think you're heading into a massive flame war. There are a variety of very strongly-held opinions on this topic, and there is no way to make everyone happy. My personal opinion is that the changes in R6RS Scheme (which seem to have been largely driven by the PLT team, correct me if I'm wrong) are absolutely necessary to make Scheme a truly _usable_ language for writing large programs in, rather than a fun toy language and/or great teaching language. One piece of evidence in this direction is that many of the features in R6RS are features that most Schemes implement already, but in completely incompatible ways. A good standard helps everyone. The real question is this: can you point to specific features in R6RS that you feel are completely unnecessary or badly specified? Mike > In the following recent thread on comp.lang.scheme, in the Preface of > _Sketchy LISP: An Introduction to Functional Programming in Scheme,_ > the author, Nils M. Holm points out an inconsistency between the > original spirit of a small, succinct language, as stated in the > Introduction to RnRS, and some of the changes in R6RS. > > According to the following document, the community standards document > for R5RS Scheme used to fit in fifty pages: > > Scheme R5RS Manual > Programming and Technical Books > Bartlett > Publishing | CafePress > http://www.cafepress.com/bartlettpublish.9174125 > > >> The Scheme programming language is one of the under-appreciated gems >> of the computer science community. It has a form and beauty that is >> simplyUnmatched [sic] by any other programming language.It's simplicity >> speaks for itself - this community standards document is only 50 pages long. >> It is just like Scheme - small, elegant, efficient, and complete. >> > > The following is the reference to Holm's book: > > On Wed, 6 Aug 2008 11:10:08 +0000 (UTC), Nils M Holm > wrote: > > >> I am happy to announce the third edition of my textbook >> >> Sketchy LISP >> An Introduction to Functional Programming in Scheme >> >> [...] >> >> Where to get it >> >> The full text of this edition can be viewed online. Paper copies >> and inexpensive PDF files can be purchased at Lulu.com. >> >> Online Edition: http://www.t3x.org/sketchy/vol1/ >> >> Paper copies and PDF files: http://www.lulu.com/content/213736/ >> > > In his Preface to his Third Edition, he writes as follows: > > >> Programming languages should be designed not by piling feature on top of >> feature, but by removing the weaknesses and restrictions that make >> additional features appear necessary. >> -- RnRS introduction >> [see http://www.r6rs.org/final/html/r6rs/r6rs-Z-H-3.html#node_chap_Temp_3] >> >> Unfortunately this principle was abandoned in the R6RS process. I >> created this edition in the hope that enough people will stay interested >> in the small and beautiful language that Scheme used to be, so the R5RS >> will remain a de-facto standard. >> > > According to the following document, he seems to be correct: > > Revised^6 Report on the Algorithmic Language Scheme - Appendix E - > Language Changes > http://www.r6rs.org/final/html/r6rs/r6rs-Z-H-19.html#node_chap_E > > >> * Libraries have been added to the language. >> >> * The old notion of program structure and Scheme$B!G(Bs top-level environment >> has been replaced by top-level programs and libraries. >> > > I have been reading through the recent R6RS-related threads in the > plt-scheme mailing list, and it seems that PLT Scheme is heading > toward becoming an R6RS-interoperable variant of Scheme. However, I > am concerned about the direction of the future evolution of PLT > Scheme. > > One of the main reasons that I preferred Scheme over Common Lisp > was the succinctness of Scheme, caused precisely by the lack of > libraries. One of the main reasons that I stopped studying Java was > precisely the huge growth in libraries. How does PLT Scheme plan to > address the apparent inconsistency between the above-mentioned > original guiding principle of RnRS Scheme and the above-mentioned > changes in R6RS Scheme? > > I have an ominous feeling of dark clouds approaching.... I just hope > that Scheme doesn't become the kind of monstrosity that Java and > Common Lisp have become, requiring constant flipping through huge > library reference manuals just to use. That makes Scheme just another > huge collection of libraries, rather than a small, elegant, and > complete adaptable precision tool.... > > -- Benjamin L. Russell > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From gregory.woodhouse at gmail.com Thu Aug 7 01:07:46 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:25:08 2009 Subject: [plt-scheme] Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] In-Reply-To: <63bb19ae0808062056k4d3b60fqf8fa377605c7fd90@mail.gmail.com> References: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> <63bb19ae0808062056k4d3b60fqf8fa377605c7fd90@mail.gmail.com> Message-ID: On Aug 6, 2008, at 8:56 PM, Sam TH wrote: > However, I and probably many other PLT people would take issue with > the idea that there is a tension between the guiding principles of > Scheme, as expressed in both the R5RS and R6RS and the design of PLT > Scheme. We strive to create powerful, extensible and flexible > language features, that we can combine do new things in new ways, and > to give programmers expressiveness as well as access to lots of > built-in features. The greater complexity of everything since the > days when Steele and Sussman invented Scheme mean that PLT Scheme is > larger than those systems, but that's not a flaw. To me, "piling feature upon feature" suggests a haphazard, poorly thought out process. I agree that there's a lot more to PLT Scheme than just, say, scheme/base, but I don't think it follows that it is not well designed. One interest of mine is using Scheme in practical applications (specifically, health information systems). I've thought about other functional languages, but find Scheme especially attractive. There are practical concerns of course, but I just find Scheme more elegant than, say, Common LISP. I've thought about languages like ML and Haskell, too, but haven't really found a compelling reason to switch to them -- even if I do like the fact that they are strongly typed. And let's face it: PLT Scheme has a strong, vibrant community behind it. "It is never too late to become reasonable and wise; but if the insight comes too late, there is always more difficulty in starting the change." -- Immanuel Kant http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080806/9f053c6a/attachment.htm From noelwelsh at gmail.com Thu Aug 7 05:51:38 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:09 2009 Subject: [plt-scheme] Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] In-Reply-To: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> References: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> Message-ID: 2008/8/7 Benjamin L. Russell : > One of the main reasons that I preferred Scheme over Common Lisp > was the succinctness of Scheme, caused precisely by the lack of > libraries. One of the main reasons that I stopped studying Java was > precisely the huge growth in libraries... > > I have an ominous feeling of dark clouds approaching.... I just hope > that Scheme doesn't become the kind of monstrosity that Java and > Common Lisp have become, requiring constant flipping through huge > library reference manuals just to use. ... I don't understand this argument. Either your program benefits from libraries or it doesn't. If it does why wouldn't you use them, and if it doesn't why wouldn't you just ignore the libraries? For example, if you were writing an image processing program in Java you'd be bonkers to not at least look at the Java image API. You might then decide it doesn't fit your needs or is too hard to use, but I don't see how this can become a criticism of the language. N. From robby at cs.uchicago.edu Thu Aug 7 07:09:27 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:09 2009 Subject: [plt-scheme] Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] In-Reply-To: <489A7337.40800@cs.caltech.edu> References: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> <489A7337.40800@cs.caltech.edu> Message-ID: <932b2f1f0808070409g64d51266o1b3e076cc631d28a@mail.gmail.com> 2008/8/6 Michael Vanier : > My personal opinion is that the changes in R6RS Scheme > (which seem to have been largely driven by the PLT team, correct me if I'm > wrong) You're welcome to judge his influence by looking at the R6RS, but the editors of the R6RS report contain just one PLT Schemer. (Jacob and I wrote the semantics, but made no contributions to the language itself beyond pointing out issues that the semantics raised.) Robby From erich at snafu.de Thu Aug 7 08:08:31 2008 From: erich at snafu.de (Erich Rast) Date: Thu Mar 26 02:25:09 2009 Subject: [plt-scheme] (Off) Tool for Visualizing Beta-Reductions? Message-ID: <1218110911.7812.9.camel@darkstar> Hi, Sorry for this slightly off-topic question. I'm working in intensional natural language semantics (aka "Montague Grammar"), where the lexical meaning of expressions is sometimes (not always) specified in ordinary language, like in this example where the expression type is given as a subscript: (\lambda x_e. x_e walks) john_e ==> john_e walks Now imagine rather complicated formulas with complex functional types and lots of function applications. Think of generalized quantifiers being modified by prepositions to yield sentence- to sentence-type operators and fancy stuff like that. It turns out to be very cumbersome and error-prone to do all the beta-reductions by hand that come up in examples. Does anyone know a tool that visualizes individual reduction steps, but also allows for the inclusion of arbitrary strings like "walks" in the above trivial example? Can the PLT redex tool be used for this? Best regards, Erich From cce at ccs.neu.edu Thu Aug 7 09:05:22 2008 From: cce at ccs.neu.edu (Carl Eastlund) Date: Thu Mar 26 02:25:09 2009 Subject: [plt-scheme] (Off) Tool for Visualizing Beta-Reductions? In-Reply-To: <1218110911.7812.9.camel@darkstar> References: <1218110911.7812.9.camel@darkstar> Message-ID: <990e0c030808070605q74dc5fb5vfe1c5e556e242a70@mail.gmail.com> On Thu, Aug 7, 2008 at 8:08 AM, Erich Rast wrote: > Hi, > > Sorry for this slightly off-topic question. I'm working in intensional > natural language semantics (aka "Montague Grammar"), where the lexical > meaning of expressions is sometimes (not always) specified in ordinary > language, like in this example where the expression type is given as a > subscript: > > (\lambda x_e. x_e walks) john_e > > ==> john_e walks > > Now imagine rather complicated formulas with complex functional types > and lots of function applications. Think of generalized quantifiers > being modified by prepositions to yield sentence- to sentence-type > operators and fancy stuff like that. It turns out to be very cumbersome > and error-prone to do all the beta-reductions by hand that come up in > examples. > > Does anyone know a tool that visualizes individual reduction steps, but > also allows for the inclusion of arbitrary strings like "walks" in the > above trivial example? Can the PLT redex tool be used for this? > > Best regards, > > Erich PLT Redex can do a lot of that. Certainly, it doesn't check automatically whether variables are bound, so "walks" won't pose a problem. It uses "_" in its own naming convention, though, so you'd have to fit your variable-typing convention into PLT Redex's convention, and recognize typed identifiers yourself or give them a compound form (e.g. "(typed john e)"). Other than that, sounds like PLT Redex is exactly what you want. -- Carl Eastlund From lispercat at gmail.com Thu Aug 7 11:24:53 2008 From: lispercat at gmail.com (Andrei Stebakov) Date: Thu Mar 26 02:25:10 2009 Subject: [plt-scheme] Using Windows COM objects with IUnknown and other interfaces Message-ID: Hi MisterX can only instantiate objects which implement IDispatch interface. If I need to create components based on IUnknown or some other interface, should I use FFI or write a wrapper in C++, just like MisterX implemented? Thank you, Andrew -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080807/cd27c365/attachment.html From matthias at ccs.neu.edu Thu Aug 7 11:36:44 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:10 2009 Subject: [plt-scheme] Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] In-Reply-To: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> References: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> Message-ID: <72728F9D-9F1F-43A8-A364-8F849C8C4CF9@ccs.neu.edu> The responses have been highly informative and have given you more than you can ask for. Here are a couple of questions that you might want to ponder: 1. What is a language? What is a library? 2. Is Scheme really a large language? 3. Is the library system designed so that programmers may ignore it? When you have figured out the answers, you may wish to reflect on the quote of 'piling features upon features in a language'. I bet you will be able to reconcile this all on your own. -- Matthias P.S. Someone in our department claims that there are between 60 and 80 actively maintained Scheme implementations. From alan at alan-watson.org Thu Aug 7 11:37:04 2008 From: alan at alan-watson.org (Alan Watson) Date: Thu Mar 26 02:25:10 2009 Subject: [plt-scheme] Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] In-Reply-To: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> References: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> Message-ID: <390F6D9B-9D0A-4CBA-AA36-C8442CEA3FA9@alan-watson.org> > According to the following document, the community standards document > for R5RS Scheme used to fit in fifty pages: An appropriate comparison is between the R5RS and the R6RS Language document. Ignoring the formal semantics (sorry, Robby), appendices, and references, the former runs to 37 pages and the latter to 60 pages. The extra 23 pages gets you a module system, a means to compose modules into programs, a foot in the door of an exception system, and in many cases a clearer specification of the semantics of Scheme and its standard procedures. I think the R6RS would have been considered a failure if it had not attempted to include these features. The R6RS, like any standard, is not perfect, but I think criticism that it is too long is fairly wide of the mark. Regards, Alan -- Alan Watson http://www.alan-watson.org/ From skyo at ccs.neu.edu Thu Aug 7 12:59:22 2008 From: skyo at ccs.neu.edu (Sky O'Mara) Date: Thu Mar 26 02:25:10 2009 Subject: [plt-scheme] Text field font troubles Message-ID: <27F3B47D-D660-435A-8915-D637F71CF85B@ccs.neu.edu> Hi, I am using MrEd to write a program with a GUI that contains a text field to send feedback to the user. I would like to be able to insert segments of colored text into the text field, but I am running into a roadblock because I do not fully understand how styles work. Here is some example code to demonstrate what I have tried so far. The documentation does not seem to make it much clearer than this: #lang scheme/gui (define main-window (new frame% [label "Window"] [width 500] [height 500])) (define editor (new text%)) (define canvas (new editor-canvas% [parent main-window] [editor editor])) ;; insert-red-text : String editor<%> -> Void ;; Inserts red text into the editor. (define (insert-red-text str ed) (let* ([snip (make-object string-snip% str)] [style (send snip get-style)] [delta (make-object style-delta%)] [newdelta (send delta set-delta-foreground "Red")]) (send style set-delta newdelta) (send snip set-style style) (send ed insert snip))) (send main-window show #t) (send editor insert "Regular text...") (insert-red-text "Red text..." editor) The idea behind insert-red-text is to create a new snip% object, change its style to have a different color, and then insert the snip into the editor. I am not having luck getting it to work. The function inserts the text, but only in the default font. Any help would be much appreciated. - Sky O. From dherman at ccs.neu.edu Thu Aug 7 13:01:20 2008 From: dherman at ccs.neu.edu (Dave Herman) Date: Thu Mar 26 02:25:11 2009 Subject: [plt-scheme] Reasons to be cheerful In-Reply-To: References: Message-ID: <489B2A60.5090902@ccs.neu.edu> I find it unlikely that that's the book he was referring to... unless our friend Wooks here is Bjarne Stroustrup...? You aren't, are you Wooks? All very mysterious. Dave "not pseudonymous" Herman Noel Welsh wrote: > The link given seems to go the wrong place (a Luca Cardelli interview) > but information on the book is here: > > http://www.research.att.com/~bs/programming.html > > N. > > On Tue, Aug 5, 2008 at 8:01 PM, wooks wrote: >> Something to look forward to. >> >> Lately, I have moved from industry to academia and now see the >> education problems from a different angle. We need to improve the >> education of our software developers. Over the last three years, I >> have developed a new course for freshmen (first-year students, often >> first-time programmers). This has given me the opportunity to address >> an audience I have never before known well and the result is a >> beginner's textbook "Programming: Principles and Practice using C++" >> which will be available in October. >> >> http://www.computerworld.com.au/index.php/id;1422447371 > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From alan at alan-watson.org Thu Aug 7 13:21:34 2008 From: alan at alan-watson.org (Alan Watson) Date: Thu Mar 26 02:25:11 2009 Subject: [plt-scheme] Reasons to be cheerful In-Reply-To: <489B2A60.5090902@ccs.neu.edu> References: <489B2A60.5090902@ccs.neu.edu> Message-ID: <8838186C-E67D-4D3C-A33E-73AE8FF60472@alan-watson.org> The original quotation (although it was not marked as such) is from the last paragraph of the interview with BS that is linked to in the first paragraph of the interview with LC. Regards, Alan -- Alan Watson http://www.alan-watson.org/ From dherman at ccs.neu.edu Thu Aug 7 13:46:32 2008 From: dherman at ccs.neu.edu (Dave Herman) Date: Thu Mar 26 02:25:11 2009 Subject: [plt-scheme] Reasons to be cheerful In-Reply-To: <8838186C-E67D-4D3C-A33E-73AE8FF60472@alan-watson.org> References: <489B2A60.5090902@ccs.neu.edu> <8838186C-E67D-4D3C-A33E-73AE8FF60472@alan-watson.org> Message-ID: <489B34F8.5040801@ccs.neu.edu> *A-ha!* Thank you, Dr. Watson! ;) Dave "not Sherlock" Herman Alan Watson wrote: > The original quotation (although it was not marked as such) is from the > last paragraph of the interview with BS that is linked to in the first > paragraph of the interview with LC. > > Regards, > > Alan From decker at cis.udel.edu Wed Aug 6 09:22:27 2008 From: decker at cis.udel.edu (Keith S. Decker) Date: Thu Mar 26 02:25:11 2009 Subject: [plt-scheme] Handin Server checkers for v4? Message-ID: <05468D9B-098B-442F-B36E-09D59B2C25BD@cis.udel.edu> I was playing around with the handin-server using the 4.0.2.6 full distribution, and was able to get everything work except the example checker; I wondered if anyone had a few working checker examples, as the checker source has a lot of Scheme macros and I admit my macro experience is Common Lisp only :-). The example I was trying, based on a small change to the example in the scribbled doc, was: (module checker (lib "checker.ss" "handin-server") (check: :language 'lang/htdp-intermediate ;;Note :language 'intermediate didn't work in 4.0.2.6 :users pairs-or-singles-with-warning :coverage? #t (!procedure Fahrenheit->Celsius 1) (!test (Fahrenheit->Celsius 32) 0) (!test (Fahrenheit->Celsius 212) 100) (!test (Fahrenheit->Celsius -4) -20))) placed in a file checker.ss inside an active handin directory. When handing in any program, however, this throws the error "ERROR: Error in your code -- program:1:0: function call: expected a name after an open parenthesis, but nothing's there in: (#%app)" Any thoughts? Other Notes: 1) For future-Google-searching posterity, if you are new to PLT and are trying to install the handin server, the magic incantation (after getting the full distribution) is setup-plt -l handin-server The documentation will then be in your local library, so for example on a Mac it is in ~/Library/PLTScheme/4.0.2.6/doc..... 2) There are 2 errors in the (otherwise very nice) handin documentation. First, the Quick Start works great until you get to the last line: "Check the status of your submission by pointing a web browser athttps://localhost:7980/servlets/status.ss. " Unfortunately, the status server is disabled by default, so you need to add (https-port- number 7980) to the config.ss file before trying the web browser bit. Took me a while to figure that one out (basically by giving up and reading the rest of the doc :-) Second, by default the Master Password is disabled, and set to #f. However, this interacts badly with unix or plaintext passwords because the #f (first in the passwords list) causes the good? test inside the ormap inside has-password? to throw an immediate error. Works fine if you just set a master password. 3) submission directories must be created by hand prior to entry in active-dirs in config.ss. The error message was quite clear, but you might want to note that in the doc (since all the other directories are created on-the-fly by the server code). Thanks, /Keith Dr. Keith Decker Assoc. Professor, Computer & Information Sciences University of Delaware From moderntelemachus at gmail.com Thu Aug 7 02:14:44 2008 From: moderntelemachus at gmail.com (Levi Smith) Date: Thu Mar 26 02:25:12 2009 Subject: [plt-scheme] (unsafe!) results in ffi-lib - already imported Message-ID: <716d3bd10808062314p32847baao83b322875ee0c362@mail.gmail.com> I'm working on an SDL binding for PLT Scheme, and could use a hand understanding some error messages. As it currently stands I'm using (require scheme/foreign)(unsafe!) in two seperate modules, sdl and sdl-gfx. I'm using (provide (all-defined-out)) across the board. When both of the aforementioned modules are *require*d at the same time, say as might be done in "display-test" module, scheme complains about ffi-lib already being imported from a different source. For me this has occured in any situation where I have multiple modules that are defining foreign libraries. Removing (unsafe!) from the scheme/foreign import, and placing all the foreign library definitions defined with ffi-lib within a single module clears this up however. Is (unsafe!) introducing new bindings into the lexical context of the module, and if so is the proper solution to abandon (all-defined-out) for something more specific? -- Levi Smith -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080806/9b260e72/attachment.htm From Ido.Yehieli at gmail.com Thu Aug 7 08:24:06 2008 From: Ido.Yehieli at gmail.com (Ido Yehieli) Date: Thu Mar 26 02:25:12 2009 Subject: [plt-scheme] Using curses with plt scheme Message-ID: Hi, is there an easy way to use a curses (or similar library) with plt scheme? Do I need to write a wrapper/use the FFI or can i just use a ready made library? Or is there some better way to handle terminal output/input in plt scheme without using curses or a curses-like library? This seems like one solution: http://groups.google.com/group/plt-scheme/browse_frm/thread/5c415000093f90ef/68f322eedcdb4dff?hl=en&lnk=gst&q=curses#68f322eedcdb4dff But I was wondering if I can do it without calling external libs (for one thing, it forces me to handle platform Independence myself). Thank you in advance, Ido. From gmh at Cs.Nott.AC.UK Tue Aug 5 07:17:04 2008 From: gmh at Cs.Nott.AC.UK (Graham Hutton) Date: Thu Mar 26 02:25:12 2009 Subject: [plt-scheme] Lectureship in Functional Programming, Nottingham Message-ID: <2934.1217935024@cs.nott.ac.uk> Dear all, We are currently seeking a new Lecturer (Assistant Professor) in the Functional Programming Lab in Nottingham, a recently formed research group that comprises Thorsten Altenkirch, Graham Hutton, Henrik Nilsson, four research fellows, and eleven PhD students. The closing date for applications is *** Friday 15th August 2008 *** Best wishes, Graham +-----------------------------------------------------------------+ UNIVERSITY OF NOTTINGHAM School of Computer Science Lectureship in Functional Programming Applications are invited for the above post in the School of Computer Science. The successful candidate will be expected to participate in the School's teaching activities and contribute to research in the recently formed Functional Programming Laboratory. Candidates must hold a PhD or equivalent in a relevant subject, have an excellent publication record and the ability to teach at undergraduate and postgraduate level. It is desirable that candidates have a track record of external research funding, collaboration across disciplines, experience of different types of assessment and higher education quality assurance. They should also have the ability to play a role in the routine running of the School of Computer Science. The Functional Programming Laboratory covers a broad range of topics in the theory, practice, and implementation of functional programming languages. Current interests include type theory, language design, program semantics, program verification, modelling and simulation, category theory, programming tools, and quantum programming. Applications are welcome from any area that complements existing research strengths in the laboratory. Informal enquiries may be addressed to Dr T Altenkirch, tel: 0115 846 6516, Email: Thorsten.Altenkirch@Nottingham.ac.uk or Dr G Hutton, tel: 0115 951 4220, Email: Graham.M.Hutton@Nottingham.ac.uk. School of Computer Science : http://nottingham.ac.uk/cs Functional programming lab : http://sneezy.cs.nott.ac.uk/joomla/ How to apply : http://jobs.nottingham.ac.uk/CJ24461S Closing date : 15th August 2008 +-----------------------------------------------------------------+ | Dr Graham Hutton Email : gmh@cs.nott.ac.uk | | Functional Programming Lab | | School of Computer Science Web : www.cs.nott.ac.uk/~gmh | | University of Nottingham | | Jubilee Campus, Wollaton Road Phone : +44 (0)115 951 4220 | | Nottingham NG8 1BB, UK | +-----------------------------------------------------------------+ This message has been checked for viruses but the contents of an attachment may still contain software viruses, which could damage your computer system: you are advised to perform your own checks. Email communications with the University of Nottingham may be monitored as permitted by UK legislation. From grettke at acm.org Thu Aug 7 14:31:36 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:12 2009 Subject: [plt-scheme] Handin server DrScheme version? Message-ID: <756daca50808071131u18f647fcs181c0103911ac0bc@mail.gmail.com> Hi folks, In this thread: http://groups.google.com/group/plt-scheme/browse_thread/thread/552ef9d1d529db72/bedc174f564d138b?hl=en&lnk=gst&q=Commenting+code+for+teaching# I see that the server and client are not included with "stable" releases; instead they are only available from SVN or pre-releases. Why is that the case? Do you normally have students use the same pre-release as the server? I am used to using the "stable" release all around, so I'm not sure how to proceed here. Best wishes, Grant -- http://www.wisdomandwonder.com/ From grettke at acm.org Thu Aug 7 14:32:50 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:13 2009 Subject: [plt-scheme] Comment on default #lang in definitions window Message-ID: <756daca50808071132m2007d769qbeba32906882c91d@mail.gmail.com> In DrScheme 4.0.2.6-svn6aug2008 #lang shows up automatically in new definitions windows in the module language. Very nice! From grettke at acm.org Thu Aug 7 14:40:52 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:13 2009 Subject: [plt-scheme] Re: Handin server DrScheme version? In-Reply-To: <756daca50808071131u18f647fcs181c0103911ac0bc@mail.gmail.com> References: <756daca50808071131u18f647fcs181c0103911ac0bc@mail.gmail.com> Message-ID: <756daca50808071140g13aedc36p6393d015cebac858@mail.gmail.com> After reading that thread, I downloaded the 4.0.2.6 nightly build; the handin server and client aren't in there. Am I looking in the wrong place? From simon at joyful.com Thu Aug 7 14:45:54 2008 From: simon at joyful.com (Simon Michael) Date: Thu Mar 26 02:25:13 2009 Subject: [plt-scheme] Re: Comment on default #lang in definitions window In-Reply-To: <756daca50808071132m2007d769qbeba32906882c91d@mail.gmail.com> References: <756daca50808071132m2007d769qbeba32906882c91d@mail.gmail.com> Message-ID: Yay! I was just noticing that as a frequent annoyance yesterday. Go PLT! From robby at cs.uchicago.edu Thu Aug 7 15:24:15 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:13 2009 Subject: [plt-scheme] Text field font troubles In-Reply-To: <27F3B47D-D660-435A-8915-D637F71CF85B@ccs.neu.edu> References: <27F3B47D-D660-435A-8915-D637F71CF85B@ccs.neu.edu> Message-ID: <932b2f1f0808071224s767f550bn1531392fe5f90273@mail.gmail.com> I think you want the change-style method of the text (using the style-delta as an argument to that). See also begin-edit-sequence and end-edit-sequence. (If that's not enough help, I can adjust your program below to get you started.) Robby On Thu, Aug 7, 2008 at 11:59 AM, Sky O'Mara wrote: > Hi, > > I am using MrEd to write a program with a GUI that contains a text field to > send feedback to the user. I would like to be able to insert segments of > colored text into the text field, but I am running into a roadblock because > I do not fully understand how styles work. > > Here is some example code to demonstrate what I have tried so far. The > documentation does not seem to make it much clearer than this: > > #lang scheme/gui > > (define main-window > (new frame% > [label "Window"] > [width 500] > [height 500])) > > (define editor (new text%)) > > (define canvas > (new editor-canvas% > [parent main-window] > [editor editor])) > > ;; insert-red-text : String editor<%> -> Void > ;; Inserts red text into the editor. > (define (insert-red-text str ed) > (let* ([snip (make-object string-snip% str)] > [style (send snip get-style)] > [delta (make-object style-delta%)] > [newdelta (send delta set-delta-foreground "Red")]) > (send style set-delta newdelta) > (send snip set-style style) > (send ed insert snip))) > > (send main-window show #t) > > (send editor insert "Regular text...") > (insert-red-text "Red text..." editor) > > The idea behind insert-red-text is to create a new snip% object, change its > style to have a different color, and then insert the snip into the editor. I > am not having luck getting it to work. The function inserts the text, but > only in the default font. > > Any help would be much appreciated. > > - Sky O. > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From jpc-ml at zenburn.net Thu Aug 7 16:38:06 2008 From: jpc-ml at zenburn.net (=?UTF-8?B?SmFrdWIgUGlvdHIgQ8WCYXBh?=) Date: Thu Mar 26 02:25:13 2009 Subject: [plt-scheme] Using curses with plt scheme In-Reply-To: References: Message-ID: <489B5D2E.3070108@zenburn.net> Ido Yehieli wrote: > But I was wondering if I can do it without calling external libs (for > one thing, it forces me to handle platform Independence myself). You cannot since there is no cross platform way of doing fancy console output. Either write such a lib (using ncurses and WinAPI as backends; I can send you some example python WinAPI code) or write something console like using MrEd. -- regards, Jakub Piotr C?apa From skyo at ccs.neu.edu Thu Aug 7 17:03:10 2008 From: skyo at ccs.neu.edu (Sky O'Mara) Date: Thu Mar 26 02:25:13 2009 Subject: [plt-scheme] Text field font troubles In-Reply-To: <932b2f1f0808071224s767f550bn1531392fe5f90273@mail.gmail.com> References: <27F3B47D-D660-435A-8915-D637F71CF85B@ccs.neu.edu> <932b2f1f0808071224s767f550bn1531392fe5f90273@mail.gmail.com> Message-ID: <17599B47-BBFB-4C4E-8753-3A7790E92F76@ccs.neu.edu> Thank you, change-style did the trick! - Sky O. On Aug 7, 2008, at 3:24 PM, Robby Findler wrote: > I think you want the change-style method of the text (using the > style-delta as an argument to that). See also begin-edit-sequence and > end-edit-sequence. > > (If that's not enough help, I can adjust your program below to get > you started.) > > Robby > > On Thu, Aug 7, 2008 at 11:59 AM, Sky O'Mara wrote: >> Hi, >> >> I am using MrEd to write a program with a GUI that contains a text >> field to >> send feedback to the user. I would like to be able to insert >> segments of >> colored text into the text field, but I am running into a roadblock >> because >> I do not fully understand how styles work. >> >> Here is some example code to demonstrate what I have tried so far. >> The >> documentation does not seem to make it much clearer than this: >> >> #lang scheme/gui >> >> (define main-window >> (new frame% >> [label "Window"] >> [width 500] >> [height 500])) >> >> (define editor (new text%)) >> >> (define canvas >> (new editor-canvas% >> [parent main-window] >> [editor editor])) >> >> ;; insert-red-text : String editor<%> -> Void >> ;; Inserts red text into the editor. >> (define (insert-red-text str ed) >> (let* ([snip (make-object string-snip% str)] >> [style (send snip get-style)] >> [delta (make-object style-delta%)] >> [newdelta (send delta set-delta-foreground "Red")]) >> (send style set-delta newdelta) >> (send snip set-style style) >> (send ed insert snip))) >> >> (send main-window show #t) >> >> (send editor insert "Regular text...") >> (insert-red-text "Red text..." editor) >> >> The idea behind insert-red-text is to create a new snip% object, >> change its >> style to have a different color, and then insert the snip into the >> editor. I >> am not having luck getting it to work. The function inserts the >> text, but >> only in the default font. >> >> Any help would be much appreciated. >> >> - Sky O. >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> From eli at barzilay.org Thu Aug 7 21:31:43 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:13 2009 Subject: [plt-scheme] Handin Server checkers for v4? In-Reply-To: <05468D9B-098B-442F-B36E-09D59B2C25BD@cis.udel.edu> References: <756daca50808071131u18f647fcs181c0103911ac0bc@mail.gmail.com> <756daca50808071140g13aedc36p6393d015cebac858@mail.gmail.com> <05468D9B-098B-442F-B36E-09D59B2C25BD@cis.udel.edu> Message-ID: <18587.41471.90852.962015@arabic.ccs.neu.edu> On Aug 6, Keith S. Decker wrote: > I was playing around with the handin-server using the 4.0.2.6 full > distribution, and was able to get everything work except the example > checker; I wondered if anyone had a few working checker examples, as > the checker source has a lot of Scheme macros and I admit my macro > experience is Common Lisp only :-). There are some issues that are still open with the handin server, especially around its testing framework. I hope that this semester I'll get to make things work again. So there will probably be changes to it through the semester. (Last semester I ended up using it only to receive submissions, but not to evaluate them.) > 1) For future-Google-searching posterity, if you are new to PLT and > are trying to install the handin server, the magic incantation > (after getting the full distribution) is > setup-plt -l handin-server > The documentation will then be in your local library, so for example > on a Mac it is in ~/Library/PLTScheme/4.0.2.6/doc..... Yes. And the installation is only needed if you want this manual. > 2) There are 2 errors in the (otherwise very nice) handin > documentation. > > First, the Quick Start works great until you get to the last line: > "Check the status of your submission by pointing a web browser at > https://localhost:7980/servlets/status.ss. " Unfortunately, the > status server is disabled by default, so you need to add > (https-port- number 7980) to the config.ss file before trying the > web browser bit. Took me a while to figure that one out (basically > by giving up and reading the rest of the doc :-) I think that there is either a bug report on this, or a mail that John sent me when he noticed it. > Second, by default the Master Password is disabled, and set to #f. > However, this interacts badly with unix or plaintext passwords because > the #f (first in the passwords list) causes the good? test inside the > ormap inside has-password? to throw an immediate error. Works fine if > you just set a master password. There shouldn't be any default master passwords. Can you explain more how you got this problem? > 3) submission directories must be created by hand prior to entry in > active-dirs in config.ss. The error message was quite clear, but you > might want to note that in the doc (since all the other directories > are created on-the-fly by the server code). I'm not sure about making it create the directories, perhaps it's a good idea. On Aug 7, Grant Rettke wrote: > Hi folks, > > In this thread: > > http://groups.google.com/group/plt-scheme/browse_thread/thread/552ef9d1d529db72/bedc174f564d138b?hl=en&lnk=gst&q=Commenting+code+for+teaching# > > I see that the server and client are not included with "stable" > releases; instead they are only available from SVN or pre-releases. > > Why is that the case? Because the handin client is not intended to be used as is -- it is intended instead to be customized for your own class. If I had the time, I'd get rid of the handin client altogether, then make some wizard code that would create it for you and set the right options in it. On Aug 7, Grant Rettke wrote: > After reading that thread, I downloaded the 4.0.2.6 nightly build; > the handin server and client aren't in there. It's only included in the "Full" distribution, which contains the complete PLT tree. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From eli at barzilay.org Thu Aug 7 21:34:04 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:14 2009 Subject: [plt-scheme] (unsafe!) results in ffi-lib - already imported In-Reply-To: <716d3bd10808062314p32847baao83b322875ee0c362@mail.gmail.com> References: <716d3bd10808062314p32847baao83b322875ee0c362@mail.gmail.com> Message-ID: <18587.41612.153452.400451@arabic.ccs.neu.edu> On Aug 6, Levi Smith wrote: > > Removing (unsafe!) from the scheme/foreign import, and placing all > the foreign library definitions defined with ffi-lib within a single > module clears this up however. Is (unsafe!) introducing new bindings > into the lexical context of the module, and if so is the proper > solution to abandon (all-defined-out) for something more specific? Yes. When you require the foreign library, the bindings are all hidden in a way, and (unsafe!) is basically defining them for you. This doesn't play nicely with all-defined, so you need to provide the bindings that you create. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From geoff at knauth.org Thu Aug 7 22:02:12 2008 From: geoff at knauth.org (Geoffrey S. Knauth) Date: Thu Mar 26 02:25:14 2009 Subject: [plt-scheme] codeswarm Message-ID: Some day I'd like to see code_swarm run on the PLT tree. http://vis.cs.ucdavis.edu/~ogawa/codeswarm/ From dtp at mindstory.com Thu Aug 7 22:07:40 2008 From: dtp at mindstory.com (David T. Pierson) Date: Thu Mar 26 02:25:14 2009 Subject: [plt-scheme] 4.0.2 on OS X 10.3.9 In-Reply-To: <990e0c030808052258r53cbf67dn8e386a5d7e6ff79f@mail.gmail.com> References: <20080806024517.GA2145@yoshi.local> <990e0c030808052258r53cbf67dn8e386a5d7e6ff79f@mail.gmail.com> Message-ID: <20080808020740.GA9153@yoshi.local> On Wed, Aug 06, 2008 at 01:58:44AM -0400, Carl Eastlund wrote: > It works when built from source on the same system, so it's probably a > matter of compatibility between Mac OS 10.3.9 and whatever the release > was built on (10.4.something, I believe). You should be able to build > it from source as a workaround, if you have the developer tools Perhaps the download page should be changed to say 10.4? Also, it did not build from source without some tweaking. Specifically, I encountered link errors like this one: g++ -dynamiclib -o PLT_MrEd.framework/Versions/4.0.2_3m/PLT_MrEd -Wl,-headerpad_max_install_names mwb_item.o mwb_panel.o mwb_timer.o mwb_frame.o mwb_list.o mPSDC.o mwb_types.o mwb_canvs.o mwb_gdi.o mwb_main.o mwb_utils.o mwb_data.o mwb_hash.o mwb_stdev.o mwb_win.o mwb_dc.o mwb_sysev.o mwb_dialg.o mwb_obj.o mxfspline.o mwx_choic.o mwx_main.o mwx_clipb.o mwx_menu.o mwx_messg.o mwxBorder.o mwx_dc.o mwxBorderArea.o mwx_dccan1.o mwx_mnuit.o mwxButtonBorder.o mwx_dccan2.o mwx_dccan3.o mwx_panel.o mwxLabelArea.o mwx_dcmem.o mwx_print.o mwxMacDC.o mwx_dcpr1.o mwx_rbox.o mwx_rbut.o mwx_sbar.o mwx_dialg.o mwx_screen.o mwxRectBorder.o mwx_slidr.o mwxScroll.o mwx_frame.o mwxScrollArea.o mwx_gauge.o mwxScrollData.o mwx_gdi.o mwx_app.o mwx_util.o mwx_area.o mwx_win.o mwx_buttn.o mwx_item.o mwximgfil.o mwx_canvs.o mwx_lbox.o mwx_check.o mwx_tabc.o mwx_gbox.o mwx_mac_utils.o mwx_bmp.o mwx_image.o mwx_xbm.o simpledrop.o wxs_bmap.o wxs_butn.o wxs_chce.o wxs_ckbx.o wxs_cnvs.o wxs_dc.o wxs_evnt.o wxs_fram.o wxs_gage.o wxs_gdi.o wxs_glob.o wxs_item.o wxs_lbox.o wxs_madm.o wxs_mede.o wxs_medi.o wxs_menu.o wxs_mio.o wxs_misc.o wxs_mpb.o wxs_obj.o wxs_panl.o wxs_rado.o wxs_slid.o wxs_snip.o wxs_styl.o wxs_tabc.o wxs_win.o wxscheme.o wx_media.o wx_mpriv.o wx_snip.o wx_msnip.o wx_mbuf.o wx_mpbrd.o wx_keym.o wx_medio.o wx_medad.o wx_style.o wx_mline.o wx_cgrec.o wxJPEG.o mred.o mredmac.o xcglue.o wxGC.o ../../wxmac/src/crbuffri.o ../../wxmac/src/crdatfri.o ../../wxmac/src/create.o ../../wxmac/src/crifrbuf.o ../../wxmac/src/crifrdat.o ../../wxmac/src/data.o ../../wxmac/src/hashtab.o ../../wxmac/src/miscellaneous.o ../../wxmac/src/parse.o ../../wxmac/src/rdftodat.o ../../wxmac/src/rdftoi.o ../../wxmac/src/rgb.o ../../wxmac/src/scan.o ../../wxmac/src/simx.o ../../wxmac/src/wrffrdat.o ../../wxmac/src/wrffri.o ../../wxmac/src/ALBirthDeath.o ../../wxmac/src/ALKeyboard.o ../../wxmac/src/ALUserPane.o ../../wxmac/src/LongControls.o ../../wxmac/src/ALCellData.o ../../wxmac/src/ALMouse.o ../../wxmac/src/ALUtilities.o ../../wxmac/src/ALDrawing.o ../../wxmac/src/ALScrolling.o ../../wxmac/src/LongCoords.o ../../wxmac/src/ALEditing.o ../../wxmac/src/ALSelecting.o ../../wxmac/src/QDDrawingState.o ../../wxmac/src/ALHeirarchical.o ../../wxmac/src/ALSelectors.o ../../mzscheme/libmzscheme3m.a -framework Carbon -framework Cocoa -framework QuickTime -framework AGL -framework OpenGL ../../wxcommon/jpeg/libjpeg.a ../../wxcommon/libpng/libpng.a -lz -ldl -lm -liconv wx_font.o ld: /usr/lib/gcc/darwin/3.3/libgcc.a(_fixunssfdi.o) illegal reference to symbol: ___cmpdi2 defined in indirectly referenced dynamic library /usr/lib/libgcc_s.1.dylib I was able to resolve these by adding /usr/lib/libgcc_s.1.dylib to the link arguments in a few places: (paths are relative to the build directory) ./mred/gc2/Makefile:wx_mac_LIBS = -framework Carbon -framework Cocoa -framework QuickTime -framework AGL -framework OpenGL $(JPEG_A) $(PNG_A) -lz -ldl -lm -liconv -lc /usr/lib/libgcc_s.1.dylib ./mred/gc2/Makefile: $(MREDLINKER) $(LDFLAGS) -o ../MrEd3m.app/Contents/MacOS/MrEd3m mrmain.o -Wl,-headerpad_max_install_names -F. -framework PLT_MrEd -framework Carbon -framework Cocoa /usr/lib/libgcc_s.1.dylib ./mred/Makefile:EXTRALDFLAGS_wx_mac = -framework Carbon -framework Cocoa -framework QuickTime -framework AGL -framework OpenGL -lz /usr/lib/libgcc_s.1.dylib I'm not sure the last one was necessary, as I had changed it mistakenly trying to resolve the first occurrence but it was not applicable to that occurrence. David From matthias at ccs.neu.edu Thu Aug 7 22:47:29 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:14 2009 Subject: [plt-scheme] codeswarm In-Reply-To: References: Message-ID: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> There is a certain beauty to this video but what information did you glean from it? On Aug 7, 2008, at 10:02 PM, Geoffrey S. Knauth wrote: > Some day I'd like to see code_swarm run on the PLT tree. > > http://vis.cs.ucdavis.edu/~ogawa/codeswarm/ > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From grettke at acm.org Thu Aug 7 23:08:55 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:14 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> References: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> Message-ID: <756daca50808072008u2b45dc48wa669b25c34895c3@mail.gmail.com> > There is a certain beauty to this video but what information did you glean from it? Using the "brightest star" analogy, this is how you find out which developer really is the center his respective heliocentric universe :). From gregory.woodhouse at gmail.com Thu Aug 7 23:22:44 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:25:15 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> References: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> Message-ID: <7D7C9AEF-C2F8-4503-A3DC-8A8F2E76F48C@gmail.com> On Aug 7, 2008, at 7:47 PM, Matthias Felleisen wrote: > There is a certain beauty to this video but what information did > you glean from it? One possibility is that you could get a picture of areas that tend to be updated together. Think of it as a kind of Hebbian "Neurons that fire together wire together". "In the human mind, one-sidedness has always been the rule and many-sidedness the exception. Hence, even in revolutions of thought, one part of the truth usually sets while another rises." --John Stuart Mill http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080807/cc501ae8/attachment.html From robby at cs.uchicago.edu Thu Aug 7 23:36:03 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:15 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <7D7C9AEF-C2F8-4503-A3DC-8A8F2E76F48C@gmail.com> References: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> <7D7C9AEF-C2F8-4503-A3DC-8A8F2E76F48C@gmail.com> Message-ID: <932b2f1f0808072036k25be3e39se05767a5866632f9@mail.gmail.com> But the picture doesn't really tell you that, since files actually move around. No? Does the author of the pictures actually advocate any particular information or are they intended to be art? (which, IMO, they succeed very well at being art!) Robby On Thu, Aug 7, 2008 at 10:22 PM, Woodhouse Gregory wrote: > > On Aug 7, 2008, at 7:47 PM, Matthias Felleisen wrote: > > There is a certain beauty to this video but what information did you glean > from it? > > One possibility is that you could get a picture of areas that tend to be > updated together. Think of it as a kind of Hebbian "Neurons that fire > together wire together". > "In the human mind, one-sidedness has > always been the rule and many-sidedness the > exception. Hence, even in revolutions of > thought, one part of the truth usually sets while > another rises." > --John Stuart Mill > http://www.gwoodhouse.com > http://GregWoodhouse.ImageKind.com > > > > > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From S.Scholz at herts.ac.uk Thu Aug 7 23:40:31 2008 From: S.Scholz at herts.ac.uk (Sven-Bodo Scholz) Date: Thu Mar 26 02:25:15 2009 Subject: [plt-scheme] 2nd call for papers IFL 2008 Message-ID: <20080808034031.GB12050@herts.ac.uk> ******************************************************************************** * * CALL FOR PAPERS * * 20th International Symposium on the * Implementation and Application of Functional Languages * IFL 2008 * 10-12.Sept 2008, Hatfield UK * * http://events.sac-home.org/ifl2008/ * ******************************************************************************** The aim of the IFL symposia is to bring together researchers actively engaged in the implementation and application of functional and function-based programming languages. They provide an open forum for researchers who wish to present and discuss new ideas and concepts, work in progress, preliminary results, etc. related primarily but not exclusively to the implementation and application of functional languages. Formal proceedings are produced after the symposium, so that authors can incorporate the feedback from discussions at the symposium in their published papers. Topics ====== Topics of interest include, but are not limited to: * language concepts * type checking * compilation techniques * (abstract) interpretation * generic programming techniques * automatic program generation * array processing * concurrent/parallel programming * concurrent/parallel program execution * functional programming on embedded systems * functional programming on multi-cores/ many-cores * heap management * runtime profiling * performance measurements * debugging and tracing * (abstract) machine architectures * verification * formal aspects * tools and programming techniques Papers on applications or tools demonstrating the suitability of novel ideas in any of the above areas and contributions on related theoretical work are also welcomed. The change of the symposium name adding the term application, introduced in 2004, is to reflect the broader scope IFL has gained over the years. Paper Submissions ================= Prospective authors are encouraged to submit papers to be published in the draft proceedings and to present them at the symposium. All contributions must be written in English, conform to the Springer-Verlag LNCS series format and not exceed 16 pages. The draft proceedings will appear as a Technical Report of the School of Computer Science of the University of Hertfordshire. Attendees of IFL 2008 will have the opportunity to submit a revised version of their paper for post-symposium reviewing. As in previous years, we hope that selected papers will be published by Springer Verlag in the Lecture Notes in Computer Science (LNCS) Series. The Peter Landin Prize ====================== Since 2002 every year the Peter Landin Prize of 150 GBP is awarded to the best paper presented at the symposium, as selected by the program committee. Important Dates =============== * Submission for draft proceedings: 22. August * Early Registration: 25. August * Symposium: 10-12. September * Submission for post-refereeing: 14. November * Notification of acceptance / rejection: 23. January 2009 * Submission of a camera ready version: 20. February 2009 Contact ======= For further details see or contact us by email: events sac-home.org From grettke at acm.org Fri Aug 8 00:29:22 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:15 2009 Subject: [plt-scheme] How to do something to all element of a list but the last Message-ID: <756daca50808072129q56ab605ag2c17fb635c0bd550@mail.gmail.com> Hi folks, While reviewing some code I wrote a while back, I found 'do' used in many places. On further review, I found that this use of 'do' doesn't qualify as "there was no better way" but more like "when I wrote it I didn't know any other way". The usage is like that of 'for-each', but for the fact that different functionality is executed depending on whether or not the element being processed is the last element of the list, or not. Is there a "best way" to do something like this? I haven't thought too much into this because I am too tired, but, I did come up with this for the fun of it. I will think about it more tomorrow. #lang scheme (define (foo args fun last-fun) (match args [(list arg args ..1) (fun arg) (foo args fun last-fun)] [(list arg) (last-fun arg)])) (foo '(a b c d e) (? (x) (printf "Got: ~a~n" x)) (? (x) (printf "Last One: ~a~n" x))) Best wishes, Grant From robby at cs.uchicago.edu Fri Aug 8 00:47:20 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:16 2009 Subject: [plt-scheme] How to do something to all element of a list but the last In-Reply-To: <756daca50808072129q56ab605ag2c17fb635c0bd550@mail.gmail.com> References: <756daca50808072129q56ab605ag2c17fb635c0bd550@mail.gmail.com> Message-ID: <932b2f1f0808072147l36b8e0cfhdc17c8e060236c78@mail.gmail.com> I'm not sure, but that definition might require O(n^2) time. (Try timing it and seeing ...) This is how I'd write it but I'm old fashioned when it comes to little loops like these. (And I didn't run the code. here's hoping no typos.) #lang scheme (provide/contract [foo (-> (cons/c any/c (listof any/c)) (-> any/c any) (-> any/c void?) void?)]) (define (foo args fun last-fun) (let loop ([fst (car args)] [rst (cdr args)]) (cond [(empty? rst) (last-fun fst)] [else (fun fst) (loop (car rst) (cdr rst))]))) Robby 2008/8/7 Grant Rettke : > Hi folks, > > While reviewing some code I wrote a while back, I found 'do' used in > many places. On further review, I found that this use of 'do' doesn't > qualify as "there was no better way" but more like "when I wrote it I > didn't know any other way". > > The usage is like that of 'for-each', but for the fact that different > functionality is executed depending on whether or not the element > being processed is the last element of the list, or not. > > Is there a "best way" to do something like this? > > I haven't thought too much into this because I am too tired, but, I > did come up with this for the fun of it. I will think about it more > tomorrow. > > #lang scheme > > (define (foo args fun last-fun) > (match args > [(list arg args ..1) > (fun arg) > (foo args fun last-fun)] > [(list arg) > (last-fun arg)])) > > (foo '(a b c d e) > (? (x) (printf "Got: ~a~n" x)) > (? (x) (printf "Last One: ~a~n" x))) > > Best wishes, > > Grant > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From DekuDekuplex at Yahoo.com Fri Aug 8 05:21:13 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:25:16 2009 Subject: [plt-scheme] Re: Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] References: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> <4apk94djdtq82jvv41a9rhbegtgkmtsef1-e09XROE/p8c@public.gmane.org> Message-ID: On Thu, 7 Aug 2008 10:51:38 +0100, "Noel Welsh" wrote: >2008/8/7 Benjamin L. Russell : >> One of the main reasons that I preferred Scheme over Common Lisp >> was the succinctness of Scheme, caused precisely by the lack of >> libraries. One of the main reasons that I stopped studying Java was >> precisely the huge growth in libraries... >> >> I have an ominous feeling of dark clouds approaching.... I just hope >> that Scheme doesn't become the kind of monstrosity that Java and >> Common Lisp have become, requiring constant flipping through huge >> library reference manuals just to use. ... > >I don't understand this argument. Either your program benefits from >libraries or it doesn't. If it does why wouldn't you use them, and if >it doesn't why wouldn't you just ignore the libraries? For example, >if you were writing an image processing program in Java you'd be >bonkers to not at least look at the Java image API. You might then >decide it doesn't fit your needs or is too hard to use, but I don't >see how this can become a criticism of the language. Okay; after some further discussion on comp.lang.scheme, I discovered that R6RS, unlike Common Lisp, allows the language to restrict the imported libraries so as not to import those that are undesired, so this is not a concern with R6RS in its present state. My worry concerned my experiences with Common Lisp. When I was starting out in my first course in Computer Science, which used both Common Lisp and Scheme (and a one-page translation chart, labelled "Common Lisp for Schemers," written by the professor, Drew McDermott, to let us do the exercises in SICP in Common Lisp if we preferred), back in fall of 1990, we used, if I remember correctly, a reference manual for Franz Lisp that was over a thousand pages long that documented the available libraries. Being new to Common Lisp, I was afraid of namespace collisions, and didn't know how to avoid them yet, so I kept thumbing through this huge reference manual every time I defined a new function to ensure that the following conditions held: 1) I wasn't reinventing any functions that already existed, and 2) I wasn't redefining any reserved words. Because I was still new to Common Lisp, I thought that all existing function names were reserved words, and was afraid that renaming an already-existing function would cause a naming conflict. (It turns out that this worry was apparently well-founded, because there is apparently a specific section in chapter 11 that prohibits redefining the operators of the package CL.) Because the level of this course was still introductory, some of the other students actually told me that I could probably have done the assignments faster by just ignoring this book and coding all the elementary functions myself. Further, some of these students told me that some of the existing functions were inefficient, and that I could probably rewrite them myself to work faster, so that there was little reason to use these functions. These statements caused even more confusion, because I didn't know enough yet to distinguish between inefficient and efficient functions just by looking at their code. This book caused a lot of confusion for me in this class, because I was still new to Common Lisp and didn't know enough reserved words to be able to avoid namespace collisions easily, so I spent about ten to fifteen minutes flipping through the book every time I redefined a new function. I couldn't escape the feeling that using such a huge reference for an introductory course was a mistake. When a later course switched from Common Lisp to Scheme, which had a much smaller community standards document, I was elated: Both the namespace and the set of included functions was much smaller, so I was finally free to concentrate on the algorithms themselves, rather than searching through a thick reference manual to avoid reinventing the wheel and encountering namespace collisions. While libraries are definitely a benefit for professional programmers, I believe that they can actually be a hindrance in an introductory course in computer science, because of the following reasons: 1) They shift the focus from thinking about the underlying algorithms to looking up libraries, and 2) They can cause confusion for some beginner-level students who do not know enough reserved words to avoid namespace collisions easily. For beginners, keeping the language simple helps immensely. In particular, it helps to keep the student focused on algorithms, rather than libraries, and to keep from having to worry about namespace collisions. I just hope that the changes in R6RS will still allow beginning students who use R6RS to focus not on using libraries and avoiding namespace collisons, but on applying language-independent programming concepts creatively. -- Benjamin L. Russell From robby at cs.uchicago.edu Fri Aug 8 05:30:55 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:16 2009 Subject: [plt-scheme] Re: Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] In-Reply-To: References: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> <4apk94djdtq82jvv41a9rhbegtgkmtsef1-e09XROE/p8c@public.gmane.org> Message-ID: <932b2f1f0808080230m31342d8bvb5e04353b6026eca@mail.gmail.com> Of course, PLT Scheme takes this particular belief directly to heart and has a series of languages that grow with the student thru the introductory course that, more than just being small, are designed with the curriculum in mind. Here's a talk about it, if you're interested: http://www.ccs.neu.edu/home/matthias/Presentations/ccsne.html http://www.ccs.neu.edu/home/matthias/Presentations/CCSNE/first%20year.pdf And, just in case it wasn't clear from what was said earlier in this thread, these languages are in fact libraries in PLT Scheme and yet they enjoy the wonderful no-15-minute-flipping-required property. :) Robby On Fri, Aug 8, 2008 at 4:21 AM, Benjamin L. Russell wrote: > On Thu, 7 Aug 2008 10:51:38 +0100, "Noel Welsh" > wrote: > >>2008/8/7 Benjamin L. Russell : >>> One of the main reasons that I preferred Scheme over Common Lisp >>> was the succinctness of Scheme, caused precisely by the lack of >>> libraries. One of the main reasons that I stopped studying Java was >>> precisely the huge growth in libraries... >>> >>> I have an ominous feeling of dark clouds approaching.... I just hope >>> that Scheme doesn't become the kind of monstrosity that Java and >>> Common Lisp have become, requiring constant flipping through huge >>> library reference manuals just to use. ... >> >>I don't understand this argument. Either your program benefits from >>libraries or it doesn't. If it does why wouldn't you use them, and if >>it doesn't why wouldn't you just ignore the libraries? For example, >>if you were writing an image processing program in Java you'd be >>bonkers to not at least look at the Java image API. You might then >>decide it doesn't fit your needs or is too hard to use, but I don't >>see how this can become a criticism of the language. > > Okay; after some further discussion on comp.lang.scheme, I discovered > that R6RS, unlike Common Lisp, allows the language to restrict the > imported libraries so as not to import those that are undesired, so > this is not a concern with R6RS in its present state. > > My worry concerned my experiences with Common Lisp. When I was > starting out in my first course in Computer Science, which used both > Common Lisp and Scheme (and a one-page translation chart, labelled > "Common Lisp for Schemers," written by the professor, Drew McDermott, > to let us do the exercises in SICP in Common Lisp if we preferred), > back in fall of 1990, we used, if I remember correctly, a reference > manual for Franz Lisp that was over a thousand pages long that > documented the available libraries. > > Being new to Common Lisp, I was afraid of namespace collisions, and > didn't know how to avoid them yet, so I kept thumbing > through this huge reference manual every time I defined a new function > to ensure that the following conditions held: > > 1) I wasn't reinventing any functions that already existed, and > > 2) I wasn't redefining any reserved words. > > Because I was still new to Common Lisp, I thought that all existing > function names were reserved words, and was afraid that renaming an > already-existing function would cause a naming conflict. (It turns > out that this worry was apparently well-founded, because there is > apparently a specific section in chapter 11 that prohibits redefining > the operators of the package CL.) > > Because the level of this course was still introductory, some of the > other students actually told me that I could probably have done the > assignments faster by just ignoring this book and coding all the > elementary functions myself. Further, some of these students told me > that some of the existing functions were inefficient, and that I could > probably rewrite them myself to work faster, so that there was little > reason to use these functions. These statements caused even more > confusion, because I didn't know enough yet to distinguish between > inefficient and efficient functions just by looking at their code. > > This book caused a lot of confusion for me in this class, because I > was still new to Common Lisp and didn't know enough reserved words to > be able to avoid namespace collisions easily, so I spent about ten to > fifteen minutes flipping through the book every time I redefined a new > function. I couldn't escape the feeling that using such a huge > reference for an introductory course was a mistake. > > When a later course switched from Common Lisp to Scheme, which had a > much smaller community standards document, I was elated: Both the > namespace and the set of included functions was much smaller, so I was > finally free to concentrate on the algorithms themselves, rather than > searching through a thick reference manual to avoid reinventing the > wheel and encountering namespace collisions. > > While libraries are definitely a benefit for professional programmers, > I believe that they can actually be a hindrance in an introductory > course in computer science, because of the following reasons: > > 1) They shift the focus from thinking about the underlying algorithms > to looking up libraries, and > > 2) They can cause confusion for some beginner-level students who do > not know enough reserved words to avoid namespace collisions easily. > > For beginners, keeping the language simple helps immensely. In > particular, it helps to keep the student focused on algorithms, rather > than libraries, and to keep from having to worry about namespace > collisions. I just hope that the changes in R6RS will still allow > beginning students who use R6RS to focus not on using libraries and > avoiding namespace collisons, but on applying language-independent > programming concepts creatively. > > -- Benjamin L. Russell > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From eli at barzilay.org Fri Aug 8 05:45:13 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:16 2009 Subject: [plt-scheme] Re: Apparent inconsistencies between original spirit of RnRS and R6RS [Fw: Ann: Sketchy LISP, Third Edition] In-Reply-To: References: <4apk94djdtq82jvv41a9rhbegtgkmtsef1@4ax.com> <4apk94djdtq82jvv41a9rhbegtgkmtsef1-e09XROE/p8c@public.gmane.org> Message-ID: <18588.5545.263154.329688@arabic.ccs.neu.edu> On Aug 8, Benjamin L.Russell wrote: > > Okay; after some further discussion on comp.lang.scheme, I > discovered that R6RS, unlike Common Lisp, allows the language to > restrict the imported libraries so as not to import those that are > undesired, so this is not a concern with R6RS in its present state. This was true in PLT for a long time now. You can have a language that is as restricted as you want. You can even exclude `require' from the language, and looking at all that extra documentation becomes irrelevant bcause you can't use it. (And BTW, this is not something that I say in theory -- in my course I give the students a different language for each homework.) > My worry concerned my experiences with Common Lisp. When I was > starting out in my first course in Computer Science, which used both > Common Lisp and Scheme (and a one-page translation chart, labelled > "Common Lisp for Schemers," written by the professor, Drew > McDermott, to let us do the exercises in SICP in Common Lisp if we > preferred), back in fall of 1990, we used, if I remember correctly, > a reference manual for Franz Lisp that was over a thousand pages > long that documented the available libraries. That is, IMO, one of the biggest problems of CL to this day: not only is it big -- but it is unclear which parts are the core and which parts are not. In fact, at the technical programmer level, there is no such distinction... (And yes, there is the restriction that forbids your from overriding builtins, but that's not nearly the same. And yes, you also have packages, but comparing CL packages to the PLT module system is like [ugh, I dislike such analogies, so I'll let you imagine the rest].) > While libraries are definitely a benefit for professional > programmers, I believe that they can actually be a hindrance in an > introductory course in computer science, because of the following > reasons: > > 1) They shift the focus from thinking about the underlying algorithms > to looking up libraries, and [JFYI, these days students are always looking up stuff -- there's always a chance that google will come up with a solution to your homework, right?] > 2) They can cause confusion for some beginner-level students who do > not know enough reserved words to avoid namespace collisions easily. In addition to the ability to provide restricted languages, the main advantage of the PLT module system is that it is impossible to break by just writing random stuff. Recently, mzscheme was changed to allow "overwriting" required bindings, so this is a valid module: #lang scheme (define + *) (+ 4 5) And the result will be 20. But no other parts of the system break as a result -- it's only your own code that sees the new binding. If you run that in DrScheme (which is actually running your code -- it doesn't start a subprocess to protect itself from such things), you get the same result -- and the rest of drscheme works perfectly fine (and *not* because the source code doesn't use any additions...). In other words, you're likely to not know about some binding in the language -- it's pretty big now (I'm counting around 1500 bindings in the `scheme' language, whereas CLtL lists aroun 1100). So you can write this code: #lang scheme (define (warn string) (fprintf "WARNING: ~a\n" string)) and miss the fact that about a month ago `warn' got added to the language. Your code will still work fine; drscheme will still work fine too. > For beginners, keeping the language simple helps immensely. [...] ... and you've just motivated the student languages. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From yarkun at gmail.com Fri Aug 8 08:03:22 2008 From: yarkun at gmail.com (Yavuz Arkun) Date: Thu Mar 26 02:25:16 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <932b2f1f0808072036k25be3e39se05767a5866632f9@mail.gmail.com> References: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> <7D7C9AEF-C2F8-4503-A3DC-8A8F2E76F48C@gmail.com> <932b2f1f0808072036k25be3e39se05767a5866632f9@mail.gmail.com> Message-ID: <2748b30b0808080503q56ecf575w1dc7ccb4e6d73b0c@mail.gmail.com> I think these visualizations are informative as well as beautiful. It may be best to view them as impressionistic "watercolors" rather than realistic "technical pen drawings". You may be unable to get the minutiae because of the speed, jitter and low resolution, but at least you get an overall idea of the type of the activity of a large project, which may be difficult to do in a few minutes going over the log files. As an example, it is easy to see the development of the contributor base of Python over time. --Yavuz On Fri, Aug 8, 2008 at 06:36, Robby Findler wrote: > But the picture doesn't really tell you that, since files actually > move around. No? > > Does the author of the pictures actually advocate any particular > information or are they intended to be art? (which, IMO, they succeed > very well at being art!) > > Robby > > On Thu, Aug 7, 2008 at 10:22 PM, Woodhouse Gregory > wrote: >> >> On Aug 7, 2008, at 7:47 PM, Matthias Felleisen wrote: >> >> There is a certain beauty to this video but what information did you glean >> from it? >> >> One possibility is that you could get a picture of areas that tend to be >> updated together. Think of it as a kind of Hebbian "Neurons that fire >> together wire together". >> "In the human mind, one-sidedness has >> always been the rule and many-sidedness the >> exception. Hence, even in revolutions of >> thought, one part of the truth usually sets while >> another rises." >> --John Stuart Mill >> http://www.gwoodhouse.com >> http://GregWoodhouse.ImageKind.com >> >> >> >> >> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From matthias at ccs.neu.edu Fri Aug 8 09:11:35 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:17 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <756daca50808072008u2b45dc48wa669b25c34895c3@mail.gmail.com> References: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> <756daca50808072008u2b45dc48wa669b25c34895c3@mail.gmail.com> Message-ID: <8716929E-90F6-4576-9CCA-86CFA6466CA1@ccs.neu.edu> PLT's code base is firmly founded on a double star. The overall project is an entire constellation, with each member playing a unique role and making singular contributions. Academia works that way; we are not a company though for the sake of our users we try to live up to those standards. -- Matthias From atmamta at gmail.com Fri Aug 8 09:13:34 2008 From: atmamta at gmail.com (Atmam Ta) Date: Thu Mar 26 02:25:17 2009 Subject: [plt-scheme] creating long double/complex ctype in the ffi Message-ID: Hi, I am trying to create a plt-scheme interface to a c library that uses complex numbers as arguments. The complex type is either long double or the standard c++ complex value. Does anyone have any idea how I could create these ctypes in the ffi? thanks A -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080808/b5df7248/attachment.htm From eli at barzilay.org Fri Aug 8 09:22:43 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:17 2009 Subject: [plt-scheme] creating long double/complex ctype in the ffi In-Reply-To: References: Message-ID: <18588.18595.653400.523842@arabic.ccs.neu.edu> On Aug 8, Atmam Ta wrote: > Hi, > > I am trying to create a plt-scheme interface to a c library that > uses complex numbers as arguments. The complex type is either long > double or the standard c++ complex value. Does anyone have any idea > how I could create these ctypes in the ffi? The foreign interface has only simple C types, no C++. If you can reach it from C, then the easiest way would be to write a small C file that does the translation to the C++ types and glue that in. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From sk at cs.brown.edu Fri Aug 8 09:22:54 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:25:17 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <756daca50808072008u2b45dc48wa669b25c34895c3@mail.gmail.com> References: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> <756daca50808072008u2b45dc48wa669b25c34895c3@mail.gmail.com> Message-ID: You could just ask and we'd tell you. (-: On Thu, Aug 7, 2008 at 11:08 PM, Grant Rettke wrote: >> There is a certain beauty to this video but what information did you glean from it? > > Using the "brightest star" analogy, this is how you find out which > developer really is the center his respective heliocentric universe > :). > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From robby at cs.uchicago.edu Fri Aug 8 09:24:34 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:18 2009 Subject: [plt-scheme] codeswarm In-Reply-To: References: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> <756daca50808072008u2b45dc48wa669b25c34895c3@mail.gmail.com> Message-ID: <932b2f1f0808080624r6bce417dod41512b75e26956f@mail.gmail.com> But our answers wouldn't be as beautiful! Robby On Fri, Aug 8, 2008 at 8:22 AM, Shriram Krishnamurthi wrote: > You could just ask and we'd tell you. (-: > > On Thu, Aug 7, 2008 at 11:08 PM, Grant Rettke wrote: >>> There is a certain beauty to this video but what information did you glean from it? >> >> Using the "brightest star" analogy, this is how you find out which >> developer really is the center his respective heliocentric universe >> :). >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From praimon at gmail.com Fri Aug 8 17:52:47 2008 From: praimon at gmail.com (praimon) Date: Thu Mar 26 02:25:18 2009 Subject: [plt-scheme] Text field font troubles In-Reply-To: <932b2f1f0808071224s767f550bn1531392fe5f90273@mail.gmail.com> References: <27F3B47D-D660-435A-8915-D637F71CF85B@ccs.neu.edu> <932b2f1f0808071224s767f550bn1531392fe5f90273@mail.gmail.com> Message-ID: <4acd8930808081452u4a4371f7s5a14bc5c5788d633@mail.gmail.com> Hi, I'm just beginning to learn about gui, so the hint didn't help and I had to resort to the much more convoluted: (define (insert-red-text str ed) (let* ([style (make-object style-list%)] [delta (make-object style-delta%)] [basic (send style basic-style)]) (send ed set-style-list style) (send delta set-delta-foreground "Red") (send ed change-style (send style find-or-create-style basic delta)) (send ed insert str))) If I saw the intended solution, that might also answer another question of mine: When dealing with text, what are the advantages of using snips (which I don't really understand) in place of strings (which get automatically converted to snips anyway). The lack of worked-out examples in the gui manual makes it a difficult learning experience, so all examples presented here are much appreciated. regards, praimon On Thu, Aug 7, 2008 at 3:24 PM, Robby Findler wrote: > I think you want the change-style method of the text (using the > style-delta as an argument to that). See also begin-edit-sequence and > end-edit-sequence. > > (If that's not enough help, I can adjust your program below to get you started.) > > Robby > > On Thu, Aug 7, 2008 at 11:59 AM, Sky O'Mara wrote: >> Hi, >> >> I am using MrEd to write a program with a GUI that contains a text field to >> send feedback to the user. I would like to be able to insert segments of >> colored text into the text field, but I am running into a roadblock because >> I do not fully understand how styles work. >> >> Here is some example code to demonstrate what I have tried so far. The >> documentation does not seem to make it much clearer than this: >> >> #lang scheme/gui >> >> (define main-window >> (new frame% >> [label "Window"] >> [width 500] >> [height 500])) >> >> (define editor (new text%)) >> >> (define canvas >> (new editor-canvas% >> [parent main-window] >> [editor editor])) >> >> ;; insert-red-text : String editor<%> -> Void >> ;; Inserts red text into the editor. >> (define (insert-red-text str ed) >> (let* ([snip (make-object string-snip% str)] >> [style (send snip get-style)] >> [delta (make-object style-delta%)] >> [newdelta (send delta set-delta-foreground "Red")]) >> (send style set-delta newdelta) >> (send snip set-style style) >> (send ed insert snip))) >> >> (send main-window show #t) >> >> (send editor insert "Regular text...") >> (insert-red-text "Red text..." editor) >> >> The idea behind insert-red-text is to create a new snip% object, change its >> style to have a different color, and then insert the snip into the editor. I >> am not having luck getting it to work. The function inserts the text, but >> only in the default font. >> >> Any help would be much appreciated. >> >> - Sky O. >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From grettke at acm.org Fri Aug 8 18:59:03 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:18 2009 Subject: [plt-scheme] How to do something to all element of a list but the last In-Reply-To: <932b2f1f0808072147l36b8e0cfhdc17c8e060236c78@mail.gmail.com> References: <756daca50808072129q56ab605ag2c17fb635c0bd550@mail.gmail.com> <932b2f1f0808072147l36b8e0cfhdc17c8e060236c78@mail.gmail.com> Message-ID: <756daca50808081559l428379a1mb86df8c7d7a1095f@mail.gmail.com> > I'm not sure, but that definition might require O(n^2) time. (Try > timing it and seeing ...) Running it against a 10,000 item list, and doing no work in the function (calling void), it is: cpu time: 2422 real time: 2422 gc time: 565 cpu time: 16 real time: 16 gc time: 0 > This is how I'd write it but I'm old fashioned when it comes to little > loops like these. (And I didn't run the code. here's hoping no typos.) Thanks. From geoff at knauth.org Sat Aug 9 08:08:06 2008 From: geoff at knauth.org (Geoffrey S. Knauth) Date: Thu Mar 26 02:25:18 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> References: <74F80AE8-A456-4FDE-ACCE-1B706710E30E@ccs.neu.edu> Message-ID: On Aug 7, 2008, at 22:47, Matthias Felleisen wrote: > There is a certain beauty to this video but what information did you > glean from it? > > On Aug 7, 2008, at 10:02 PM, Geoffrey S. Knauth had previously shared: >> http://vis.cs.ucdavis.edu/~ogawa/codeswarm/ I learned the most by comparing videos of different projects. Mainly I was thinking, if Eclipse, Python and Apache are represented in the gallery, then PLT ought to be there too, because it has functionality similar to all three of those projects. DrScheme is a very significant achievement. It has always been good, but now it is great, it keeps getting better, and for years it's been at the point where you can do almost anything with it. I was struck that the Python video showed almost a solo effort for many years, until suddenly it became really popular and it really picked up steam. That made me wonder what the PLT story line would show. code_swarm does not show qualitative leaps, but they can be highlighted with video annotations. From d.j.gurnell at gmail.com Sat Aug 9 09:05:43 2008 From: d.j.gurnell at gmail.com (Dave Gurnell) Date: Thu Mar 26 02:25:18 2009 Subject: [plt-scheme] toString equivalent Message-ID: <6F6FCF17-9147-48C6-8DFD-E818370D7619@gmail.com> Hi PLTers, I want a way to override the default way objects of a certain class get printed. Is there any equivalent of Java's toString method in the PLT class system? Alternatively, can I attach a prop:custom-write to a class, or is there some way of customising the default printer? Cheers, -- Dave From offby1 at blarg.net Sat Aug 9 12:55:47 2008 From: offby1 at blarg.net (Eric Hanchrow) Date: Thu Mar 26 02:25:19 2009 Subject: [plt-scheme] How to do something to all element of a list but the last In-Reply-To: <756daca50808081559l428379a1mb86df8c7d7a1095f@mail.gmail.com> (Grant Rettke's message of "Fri, 8 Aug 2008 17:59:03 -0500") References: <756daca50808072129q56ab605ag2c17fb635c0bd550@mail.gmail.com> <932b2f1f0808072147l36b8e0cfhdc17c8e060236c78@mail.gmail.com> <756daca50808081559l428379a1mb86df8c7d7a1095f@mail.gmail.com> Message-ID: <873aleunzg.fsf@offby1.atm01.sea.blarg.net> How about something like this? (require (lib "1.ss" "srfi")) (pair-fold (lambda (a b) (when (not (null? (cdr a))) (printf "I'm doing something to ~s~%" (car a)))) (void) (list 1 2 3 4)) -- "That sounds like a bunch of baloney," [Feynman] said. "Give me something real to do." So we sent him out to buy some office supplies. -- Danny Hillis From skyo at ccs.neu.edu Sat Aug 9 15:07:38 2008 From: skyo at ccs.neu.edu (Sky O'Mara) Date: Thu Mar 26 02:25:19 2009 Subject: [plt-scheme] Text field font troubles In-Reply-To: <4acd8930808081452u4a4371f7s5a14bc5c5788d633@mail.gmail.com> References: <27F3B47D-D660-435A-8915-D637F71CF85B@ccs.neu.edu> <932b2f1f0808071224s767f550bn1531392fe5f90273@mail.gmail.com> <4acd8930808081452u4a4371f7s5a14bc5c5788d633@mail.gmail.com> Message-ID: <5FC81EB3-54F0-4183-A270-91859ACAA434@ccs.neu.edu> This is what I came up with to make use of change-style: (define (insert-red-text str ed) (let ([red-delta (send (make-object style-delta%) set-delta- foreground "Red")] [end-before (send ed last-position)]) ;; the end of the text before inserting str (send ed insert str end-before) (send ed change-style red-delta end-before (send ed last- position)))) I hope this is a useful example. I agree that the documentation for the gui leaves much to be desired. - Sky O. On Aug 8, 2008, at 5:52 PM, praimon wrote: > Hi, > I'm just beginning to learn about gui, so the hint didn't help > and I had to resort to the much more convoluted: > > (define (insert-red-text str ed) > (let* ([style (make-object style-list%)] > [delta (make-object style-delta%)] > [basic (send style basic-style)]) > (send ed set-style-list style) > (send delta set-delta-foreground "Red") > (send ed change-style > (send style find-or-create-style basic delta)) > (send ed insert str))) > > If I saw the intended solution, that might also answer another > question of mine: When dealing with text, what are the > advantages of using snips (which I don't really understand) > in place of strings (which get automatically converted to snips > anyway). > > The lack of worked-out examples in the gui manual makes > it a difficult learning experience, so all examples presented > here are much appreciated. > regards, > praimon > > > On Thu, Aug 7, 2008 at 3:24 PM, Robby Findler > wrote: >> I think you want the change-style method of the text (using the >> style-delta as an argument to that). See also begin-edit-sequence and >> end-edit-sequence. >> >> (If that's not enough help, I can adjust your program below to get >> you started.) >> >> Robby >> >> On Thu, Aug 7, 2008 at 11:59 AM, Sky O'Mara wrote: >>> Hi, >>> >>> I am using MrEd to write a program with a GUI that contains a text >>> field to >>> send feedback to the user. I would like to be able to insert >>> segments of >>> colored text into the text field, but I am running into a >>> roadblock because >>> I do not fully understand how styles work. >>> >>> Here is some example code to demonstrate what I have tried so far. >>> The >>> documentation does not seem to make it much clearer than this: >>> >>> #lang scheme/gui >>> >>> (define main-window >>> (new frame% >>> [label "Window"] >>> [width 500] >>> [height 500])) >>> >>> (define editor (new text%)) >>> >>> (define canvas >>> (new editor-canvas% >>> [parent main-window] >>> [editor editor])) >>> >>> ;; insert-red-text : String editor<%> -> Void >>> ;; Inserts red text into the editor. >>> (define (insert-red-text str ed) >>> (let* ([snip (make-object string-snip% str)] >>> [style (send snip get-style)] >>> [delta (make-object style-delta%)] >>> [newdelta (send delta set-delta-foreground "Red")]) >>> (send style set-delta newdelta) >>> (send snip set-style style) >>> (send ed insert snip))) >>> >>> (send main-window show #t) >>> >>> (send editor insert "Regular text...") >>> (insert-red-text "Red text..." editor) >>> >>> The idea behind insert-red-text is to create a new snip% object, >>> change its >>> style to have a different color, and then insert the snip into the >>> editor. I >>> am not having luck getting it to work. The function inserts the >>> text, but >>> only in the default font. >>> >>> Any help would be much appreciated. >>> >>> - Sky O. >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>> >>> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From info at reatlas.com Sat Aug 9 15:10:24 2008 From: info at reatlas.com (Ethan Herdrick) Date: Thu Mar 26 02:25:19 2009 Subject: [plt-scheme] How to do something to all element of a list but the last In-Reply-To: <756daca50808072129q56ab605ag2c17fb635c0bd550@mail.gmail.com> References: <756daca50808072129q56ab605ag2c17fb635c0bd550@mail.gmail.com> Message-ID: <91f48dbf0808091210j46802046r3cbafe122054de4e@mail.gmail.com> Hi Grant: You should always start with the functional programming approach: (require (lib "1.ss" "srfi")) (for-each (? (x) (printf "Got: ~a~n" x)) (drop-right '(1 2 3 4) 1)) The key here is "drop-right". In general, manipulate your list first, then it's map (or for-each), filter, or sometimes fold. Repeat as necessary. Hope this is helps. -Ethan 2008/8/7 Grant Rettke : > Hi folks, > > While reviewing some code I wrote a while back, I found 'do' used in > many places. On further review, I found that this use of 'do' doesn't > qualify as "there was no better way" but more like "when I wrote it I > didn't know any other way". > > The usage is like that of 'for-each', but for the fact that different > functionality is executed depending on whether or not the element > being processed is the last element of the list, or not. > > Is there a "best way" to do something like this? > > I haven't thought too much into this because I am too tired, but, I > did come up with this for the fun of it. I will think about it more > tomorrow. > > #lang scheme > > (define (foo args fun last-fun) > (match args > [(list arg args ..1) > (fun arg) > (foo args fun last-fun)] > [(list arg) > (last-fun arg)])) > > (foo '(a b c d e) > (? (x) (printf "Got: ~a~n" x)) > (? (x) (printf "Last One: ~a~n" x))) > > Best wishes, > > Grant > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From lordgeoffrey at optushome.com.au Sat Aug 9 17:49:14 2008 From: lordgeoffrey at optushome.com.au (LordGeoffrey) Date: Thu Mar 26 02:25:19 2009 Subject: [plt-scheme] csv.plt - expand: unbound variable in module in: set-cdr! Message-ID: <489E10DA.1030103@optushome.com.au> Hi, Is this something wrong with my drscheme configuration (which i always find confusing) or incompatibilities with v4 Settings: Language: Pretty Big (includes MrEd and Advanced Student); memory limit: 128 megabytes. Used: (require (planet "csv.ss" ("neil" "csv.plt" 1 1))) Thanks From praimon at gmail.com Sat Aug 9 21:37:44 2008 From: praimon at gmail.com (praimon) Date: Thu Mar 26 02:25:19 2009 Subject: [plt-scheme] Text field font troubles In-Reply-To: <5FC81EB3-54F0-4183-A270-91859ACAA434@ccs.neu.edu> References: <27F3B47D-D660-435A-8915-D637F71CF85B@ccs.neu.edu> <932b2f1f0808071224s767f550bn1531392fe5f90273@mail.gmail.com> <4acd8930808081452u4a4371f7s5a14bc5c5788d633@mail.gmail.com> <5FC81EB3-54F0-4183-A270-91859ACAA434@ccs.neu.edu> Message-ID: <4acd8930808091837x45c5b842k23edd66c1edec90@mail.gmail.com> Thanks, It was helpful to see positions used here. (btw, I think your final (send ed last-position) can be replaced with 'end). But...you too abandoned snips! I wonder what a snip-based version would look like. regards, praimon On Sat, Aug 9, 2008 at 3:07 PM, Sky O'Mara wrote: > This is what I came up with to make use of change-style: > > (define (insert-red-text str ed) > (let ([red-delta (send (make-object style-delta%) set-delta-foreground > "Red")] > [end-before (send ed last-position)]) ;; the end of the text before > inserting str > (send ed insert str end-before) > (send ed change-style red-delta end-before (send ed last-position)))) > > I hope this is a useful example. I agree that the documentation for the gui > leaves much to be desired. > > - Sky O. > From moderntelemachus at gmail.com Sat Aug 9 21:40:05 2008 From: moderntelemachus at gmail.com (Levi Smith) Date: Thu Mar 26 02:25:20 2009 Subject: [plt-scheme] csv.plt - expand: unbound variable in module in: set-cdr! In-Reply-To: <489E10DA.1030103@optushome.com.au> References: <489E10DA.1030103@optushome.com.au> Message-ID: <716d3bd10808091840l7e34188cn12b232a858f92199@mail.gmail.com> set-cdr! and set-car! were banished to their own library. From what I understand, immutable pairs are the new default. Mutable pairs can still be created using such functions as mcons and mcar, and can be modified using the new set-mcar! and set-mcdr! For more information, look here: "Getting rid of set-car! and set-cdr!" http://blog.plt-scheme.org/2007/11/getting-rid-of-set-car-and-set-cdr.html On 8/9/08, LordGeoffrey wrote: > > Hi, > Is this something wrong with my drscheme configuration (which i always find > confusing) or incompatibilities with v4 > > Settings: > Language: Pretty Big (includes MrEd and Advanced Student); memory limit: > 128 megabytes. > > Used: > (require (planet "csv.ss" ("neil" "csv.plt" 1 1))) > > Thanks > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080809/3e71c341/attachment.html From skyo at ccs.neu.edu Sat Aug 9 23:19:26 2008 From: skyo at ccs.neu.edu (Sky O'Mara) Date: Thu Mar 26 02:25:20 2009 Subject: [plt-scheme] Text field font troubles In-Reply-To: <4acd8930808091837x45c5b842k23edd66c1edec90@mail.gmail.com> References: <27F3B47D-D660-435A-8915-D637F71CF85B@ccs.neu.edu> <932b2f1f0808071224s767f550bn1531392fe5f90273@mail.gmail.com> <4acd8930808081452u4a4371f7s5a14bc5c5788d633@mail.gmail.com> <5FC81EB3-54F0-4183-A270-91859ACAA434@ccs.neu.edu> <4acd8930808091837x45c5b842k23edd66c1edec90@mail.gmail.com> Message-ID: <9F3EE3D7-0683-4E03-B63A-494A1F0D24EE@ccs.neu.edu> You're right, thanks for that tip! I agree that snips are pretty confusing. It would be nice to see some examples of how to use them properly. - Sky O. On Aug 9, 2008, at 9:37 PM, praimon wrote: > Thanks, > It was helpful to see positions used here. > (btw, I think your final (send ed last-position) can be replaced > with 'end). > But...you too abandoned snips! I wonder what a snip-based version > would look like. > regards, > praimon > > On Sat, Aug 9, 2008 at 3:07 PM, Sky O'Mara wrote: >> This is what I came up with to make use of change-style: >> >> (define (insert-red-text str ed) >> (let ([red-delta (send (make-object style-delta%) set-delta- >> foreground >> "Red")] >> [end-before (send ed last-position)]) ;; the end of the text >> before >> inserting str >> (send ed insert str end-before) >> (send ed change-style red-delta end-before (send ed last- >> position)))) >> >> I hope this is a useful example. I agree that the documentation for >> the gui >> leaves much to be desired. >> >> - Sky O. >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From dyoo at cs.wpi.edu Sat Aug 9 23:45:26 2008 From: dyoo at cs.wpi.edu (Danny Yoo) Date: Thu Mar 26 02:25:20 2009 Subject: [plt-scheme] Trying to open up a beginner-level-sourced file in a text% Message-ID: I'm trying to open up a file created in beginner-level, such that what shows up in the text% is what shows up in DrScheme. However, I'm seeing the hidden content that DrScheme adds in (the module and the requires for the teachpacks.) Can I assume that the content of the file will always be three lines long? From robby at cs.uchicago.edu Sun Aug 10 01:22:51 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:20 2009 Subject: [plt-scheme] Text field font troubles In-Reply-To: <9F3EE3D7-0683-4E03-B63A-494A1F0D24EE@ccs.neu.edu> References: <27F3B47D-D660-435A-8915-D637F71CF85B@ccs.neu.edu> <932b2f1f0808071224s767f550bn1531392fe5f90273@mail.gmail.com> <4acd8930808081452u4a4371f7s5a14bc5c5788d633@mail.gmail.com> <5FC81EB3-54F0-4183-A270-91859ACAA434@ccs.neu.edu> <4acd8930808091837x45c5b842k23edd66c1edec90@mail.gmail.com> <9F3EE3D7-0683-4E03-B63A-494A1F0D24EE@ccs.neu.edu> Message-ID: <932b2f1f0808092222m7c40c708m16d31d3867a2a39a@mail.gmail.com> The right way to set a style on a snip is probably to insert it and then call change-style, rather than trying to use set-style. Styles on snips are more useful when you write your own snip% class and then have it draw differently by inspecting get-style. Robby On Sat, Aug 9, 2008 at 10:19 PM, Sky O'Mara wrote: > You're right, thanks for that tip! > > I agree that snips are pretty confusing. It would be nice to see some > examples of how to use them properly. > > - Sky O. > > On Aug 9, 2008, at 9:37 PM, praimon wrote: > >> Thanks, >> It was helpful to see positions used here. >> (btw, I think your final (send ed last-position) can be replaced with >> 'end). >> But...you too abandoned snips! I wonder what a snip-based version >> would look like. >> regards, >> praimon >> >> On Sat, Aug 9, 2008 at 3:07 PM, Sky O'Mara wrote: >>> >>> This is what I came up with to make use of change-style: >>> >>> (define (insert-red-text str ed) >>> (let ([red-delta (send (make-object style-delta%) set-delta-foreground >>> "Red")] >>> [end-before (send ed last-position)]) ;; the end of the text before >>> inserting str >>> (send ed insert str end-before) >>> (send ed change-style red-delta end-before (send ed last-position)))) >>> >>> I hope this is a useful example. I agree that the documentation for the >>> gui >>> leaves much to be desired. >>> >>> - Sky O. >>> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From wookiz at hotmail.com Sun Aug 10 05:00:33 2008 From: wookiz at hotmail.com (wooks) Date: Thu Mar 26 02:25:21 2009 Subject: [plt-scheme] More pedagogic stuff Message-ID: Hopefully I got the right link this time. http://www.bcs.org/server.php?show=ConWebDoc.18854 From pivanyi at freemail.hu Sun Aug 10 06:02:26 2008 From: pivanyi at freemail.hu (Ivanyi Peter) Date: Thu Mar 26 02:25:21 2009 Subject: [plt-scheme] MrEd tab-panel% Message-ID: Hi all, I try to add a feature to MrEd Designer where it can handle tab-panels correctly. However I have a problem. In MrEd Designer I create all sorts of widgets. In all widgets the on-subwindow event is overwritten with a special code. I do this with the tab-panel as well. However the tab-panel widget is unique, as it contains internal widgets which are not exposed to the world. The tab-panel% class contains a tab-group%. Now when I click on the panel the tab-panel% receives the event, but when I click on a tab (at the top of the panel) the tab-group% receives, which event I cannot handle. So I try to create a new tab-panel% class like in frtime/gui/mod-mrpanel.ss In this case the tab-panel% is a vertical-panel%, which contains a tab-group%, however I also create a panel:single% object inside which will do the switching. But I cannot add the panel:single% to tab-group% as tab-group% is not an internal container. So my question is: How can I make a tab-group% object which is also an internal container??? I include a working code below and I have marked the line where I cannot add panel:single% to tab-group%. At least I think that is the problem. Can someone help me with this? (Matthew, Robby ???) Thanks for any help, Peter Ivanyi ---------------------------------------------------------------------------------- (module tab-test mzscheme (require mzlib/class (prefix wx: (lib "kernel.ss" "mred" "private")) (lib "lock.ss" "mred" "private") (lib "const.ss" "mred" "private") (lib "check.ss" "mred" "private") (lib "helper.ss" "mred" "private") (lib "wx.ss" "mred" "private") (lib "kw.ss" "mred" "private") (lib "mrwindow.ss" "mred" "private") (lib "mrcontainer.ss" "mred" "private") (lib "mrtabgroup.ss" "mred" "private") (lib "mrgroupbox.ss" "mred" "private") (lib "mred.ss" "mred") (lib "framework.ss" "framework") ; for tab panels ) (define mred-frame% (class frame% ; id of the frame in the data list (init-field (mred-id #f) (preview-callback #f) ) (define/public (mred-id-set! id) (set! mred-id id)) (define/public (mred-id-get) mred-id) (define/override (on-subwindow-event w e) (let ((type (send e get-event-type))) (if (equal? type 'left-down) (let ((id (send w mred-id-get))) (if (and preview-callback (procedure? preview-callback)) (preview-callback id) ) ) ) #f ) ) (super-new) ) ) (define mred-tab-group% (class tab-group% (init-field (mred-id #f) (preview-callback #f) ) (define/public (mred-id-set! id) (set! mred-id id)) (define/public (mred-id-get) mred-id) (super-new) ) ) ; special class for tab-panel (define mred-tab-panel% (class vertical-panel% (init-field (mred-id #f) (preview-callback #f) (choices '()) ) (define/public (mred-id-set! id) (set! mred-id id)) (define/public (mred-id-get) mred-id) (super-new) (define panel-list '()) (define panel-name '()) (define tabs (new mred-tab-group% (label "") (choices choices) (parent this) (style '(border)) (callback (lambda (w e) (send (send this get-single) active-child (list-ref panel-list (send this get-selection))) ))) ) ;;;;;; PROBLEM ;;;;;;;;;; ;;;;;; 'this' should be tabs !!!! (define panel-single (new panel:single% (parent this))) (define/public (get-selection) (send (mred->wx tabs) get-selection) ) (define/public (get-tabs) tabs ) (define/public (get-single) panel-single ) (define/public (tab-add widget label) (send (mred->wx tabs) append label) (set! panel-list (append panel-list (list widget))) (set! panel-name (append panel-name (list label))) ) ) ) (define mred-tab% (class vertical-panel% (init-field (mred-id #f) (preview-callback #f) (label "") ) (define/public (mred-id-set! id) (set! mred-id id)) (define/public (mred-id-get) mred-id) (define/override (set-label text) (set! label text) ) (super-new) ; add this tab to parent as well (send (send (send this get-parent) get-parent) tab-add this label) ) ) (define w (new mred-frame% (label "Hello") (min-width 200) (min-height 200) )) (define panel-name '()) (define tab-panel (new mred-tab-panel% (parent w) (choices panel-name))) (define vert1 (new mred-tab% (parent (send tab-panel get-single)) (label "aa"))) (define b1 (new button% (label "11111") (parent vert1))) (define vert2 (new mred-tab% (parent (send tab-panel get-single)) (label "bb"))) (define b2 (new button% (label "22222") (parent vert2))) (send w show #t) ) ______________________________________________________________________ Eg?sz ny?ron szombat esti l?z! http://videa.hu/videok/zene/mtv-icon-tribute-to-lgt-balaton-cokeclub-coketv-YUxNbEgI5kzWjLjP From noelwelsh at gmail.com Sun Aug 10 06:34:12 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:21 2009 Subject: [plt-scheme] More pedagogic stuff In-Reply-To: References: Message-ID: The little research I've read (mostly BlueJ material) suggests object first is the way to go, but the programming environment needs to change to make this more accessible. I'm a bit disappointed that the linked article seems ignorant of this research. N. On Sun, Aug 10, 2008 at 10:00 AM, wooks wrote: > Hopefully I got the right link this time. > > http://www.bcs.org/server.php?show=ConWebDoc.18854 > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From sk at cs.brown.edu Sun Aug 10 08:52:58 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:25:21 2009 Subject: [plt-scheme] More pedagogic stuff In-Reply-To: References: Message-ID: Is there a point here beyond that this author seems to be hopelessly outdated in his understanding of CS? On Sun, Aug 10, 2008 at 5:00 AM, wooks wrote: > Hopefully I got the right link this time. > > http://www.bcs.org/server.php?show=ConWebDoc.18854 > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From skyo at ccs.neu.edu Sun Aug 10 10:27:33 2008 From: skyo at ccs.neu.edu (Sky O'Mara) Date: Thu Mar 26 02:25:21 2009 Subject: [plt-scheme] codeswarm In-Reply-To: References: Message-ID: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> I was curious, so I downloaded codeswarm and gave it a quick run on the plt subversion trunk. Here's the video: http://homepage.mac.com/skyboy/plt-codeswarm.avi It starts off a little weird, and not much happens for the first minute or so. Then Eli pulls a bunch of files in and the activity picks up. It's quite beautiful. -Sky O. On Aug 7, 2008, at 10:02 PM, Geoffrey S. Knauth wrote: > Some day I'd like to see code_swarm run on the PLT tree. > > http://vis.cs.ucdavis.edu/~ogawa/codeswarm/ > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From czhu at cs.utah.edu Sun Aug 10 11:17:55 2008 From: czhu at cs.utah.edu (Chongkai Zhu) Date: Thu Mar 26 02:25:22 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> Message-ID: <489F06A3.9030207@cs.utah.edu> The problem is that PLT switch from cvs to svn not too long ago. So your video only contains recent activity. Chongkai Sky O'Mara wrote: > I was curious, so I downloaded codeswarm and gave it a quick run on > the plt subversion trunk. Here's the video: > > http://homepage.mac.com/skyboy/plt-codeswarm.avi > > It starts off a little weird, and not much happens for the first > minute or so. Then Eli pulls a bunch of files in and the activity > picks up. It's quite beautiful. > > -Sky O. > > On Aug 7, 2008, at 10:02 PM, Geoffrey S. Knauth wrote: > >> Some day I'd like to see code_swarm run on the PLT tree. >> >> http://vis.cs.ucdavis.edu/~ogawa/codeswarm/ >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From grettke at acm.org Sun Aug 10 11:37:52 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:22 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <489F06A3.9030207@cs.utah.edu> References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> <489F06A3.9030207@cs.utah.edu> Message-ID: <756daca50808100837s5811ee7dlf72dded9453ae4c5@mail.gmail.com> On Sun, Aug 10, 2008 at 10:17 AM, Chongkai Zhu wrote: > The problem is that PLT switch from cvs to svn not too long ago. So your > video only contains recent activity. Didn't the CVS history get imported? From eli at barzilay.org Sun Aug 10 13:42:14 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:22 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> Message-ID: <18591.10358.317594.267819@arabic.ccs.neu.edu> On Aug 10, Sky O'Mara wrote: > I was curious, so I downloaded codeswarm and gave it a quick run on > the plt subversion trunk. Here's the video: > > http://homepage.mac.com/skyboy/plt-codeswarm.avi > > It starts off a little weird, and not much happens for the first > minute or so. Then Eli pulls a bunch of files in and the activity > picks up. It's quite beautiful. The reason for the weird first part is that when we imported the mztake code in it was taken with the commit history -- and since that history was earlier than the main tree moving to Subversion, you see it first. You then see me starting a hugh boom of files around me, only because I was the one who moved everything to subversion. More notes: * To get a more complete picture, you'll need to merge the cvs history with the svn history (the old cvs repository is still there, see the bottom of svn.plt-scheme.org) * The reason I have a very bright file next to me at all times is the nightly build updating the time-stamp file. It's probably better to ignore it. * It looks to me like you took the whole repository in -- there are some cases where it might be better to ignore activity in branches, and some where it's not. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From michael at schuerig.de Sun Aug 10 13:33:56 2008 From: michael at schuerig.de (Michael Schuerig) Date: Thu Mar 26 02:25:22 2009 Subject: [plt-scheme] Rationale of the object system? Message-ID: <200808101933.57094.michael@schuerig.de> I was introduced to "real" programming through SICP ages ago. Since then I've kept an eye on Lisp and Scheme, but never went further than reading several books for inspiration (Graham, PAIP, AMOP, Keene, Seibel). Meanwhile, my income has been coming from C++, Java, and, for the last few years, Ruby. The Ruby community has become a bit crowded recently and thus provided a good incentive to move onward. As I wanted a dynamic language, the choice was between Common Lisp and Scheme and for the time being, I've settled on (PLT) Scheme. If I have one regret, it is missing out on CLOS and the MOP. By comparison, the PLT Scheme object system looks rather conventional (at least from a Rubyist's point of view). Certainly the designers of this object system knew CLOS and going the other way must have been a conscious decision, I take it. If anyone remembers the tale, I'd be curious to hear it. I've found Swindle, of course, and I'm wondering whether it is practically possible to use it instead of the "native" object system. Or maybe mix the two systems without too much pain. Michael -- Michael Schuerig mailto:michael@schuerig.de http://www.schuerig.de/michael/ From eli at barzilay.org Sun Aug 10 13:44:57 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:22 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <756daca50808100837s5811ee7dlf72dded9453ae4c5@mail.gmail.com> References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> <489F06A3.9030207@cs.utah.edu> <756daca50808100837s5811ee7dlf72dded9453ae4c5@mail.gmail.com> Message-ID: <18591.10521.59785.325980@arabic.ccs.neu.edu> On Aug 10, Grant Rettke wrote: > On Sun, Aug 10, 2008 at 10:17 AM, Chongkai Zhu wrote: > > The problem is that PLT switch from cvs to svn not too long ago. So your > > video only contains recent activity. > > Didn't the CVS history get imported? No. I tried that first, and it was messy. This is partly because the conversion script was trying hard to make an exact reflection of cvs activity, which did things like expose tags that nobody ever used and similar kinds of messes. Overall, it seemed much healthier to start from just a snapshot of the tree, rather than converting the cvs and cleaning it up. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From eli at barzilay.org Sun Aug 10 14:46:31 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:22 2009 Subject: [plt-scheme] Rationale of the object system? In-Reply-To: <200808101933.57094.michael@schuerig.de> References: <200808101933.57094.michael@schuerig.de> Message-ID: <18591.14215.374850.726661@arabic.ccs.neu.edu> On Aug 10, Michael Schuerig wrote: > > If I have one regret, it is missing out on CLOS and the MOP. By > comparison, the PLT Scheme object system looks rather conventional > (at least from a Rubyist's point of view). Certainly the designers > of this object system knew CLOS and going the other way must have > been a conscious decision, I take it. If anyone remembers the tale, > I'd be curious to hear it. I don't know the tale, but having gone through implementing Swindle, I can tell why I wouldn't have chosen it as the OO model to use. The CLOS-style OO is extremely slow by default, there is a lot of place for improvements (which most serious CLOS implementations do, and swindle also does, to some degree), but it's still an order of magnitude away from non-OO code. (In comparison, I think that the PLT class system is very close to non-OO code. But it's hard to come up with numbers, since in both cases you'd me mixing things up.) In addition, such optimizations involve a lot of low-level hacking in the form of dynamic code generation and such, for example -- see how CLOS uses macros to define method combinations. Now, the fact that you have such a high price must come with some advantages -- in this case it's the extreme flexibility that you get because of the MOP. You can pretty much change the face of the system completely with the given hooks and make it do anything you want. However, in practice I've seen almost no use of these capabilities. In CLOS there's the standard example of persistent objects and very little beyond that. To make this point even stronger, with a language as flexible as PLT Scheme, where modules play nicely with macros, you can easily get such different behavior using macros. (The obvious question is which way is easier, I have no answer to that.) As a corollary, too much MOP-level games are close in spirit to too much macro-level games: you end up with a language that is very different from the original, which diminishes it's general usefulness (since the threshold of using it is much higher). So the bottom line so far is: you pay a heavy price; you get a lot for it; it's questionable if you actually need that kind of flexibility or if it's a good idea to use it. So far, it's still seems like a good thing to invest in, but the real killer is the side-effect that is inherent in defining new methods in CLOS. The result of this is a system that is "too open" due to the fact that you can always change behaviors by adding and overriding methods -- there's always a foot around that you can accidently shoot. You might know the "thieves and bums use C++ and nice people use CLOS" quote, which is (IMO) pretty misguided: if the only way to achieve a specific piece of functionality is by extending it in a way that is visible by all other code, then each such change can lead to potential debugging catastrophes. > I've found Swindle, of course, and I'm wondering whether it is > practically possible to use it instead of the "native" object > system. Or maybe mix the two systems without too much pain. That depends. Getting the two systems is easy -- all you need is require both and use a prefix to disambiguate. But it's still question if this will be too much pain for you or not. Another relevant question is whether you'll want to use existing code (usually GUI stuff) -- in that case it's probably better to avoid swindle. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From dyoo at cs.wpi.edu Sun Aug 10 15:05:03 2008 From: dyoo at cs.wpi.edu (Danny Yoo) Date: Thu Mar 26 02:25:23 2009 Subject: [plt-scheme] hitting a race in logging? Message-ID: I'm hitting slightly weird behavior when I'm logging events, but I don't yet see why. In DrScheme, the following program sometimes shows "hello" as expected. But sometimes it doesn't! ;;;;;; #lang scheme (define (start-up-debug-printing) (let ([receiver (make-log-receiver (current-logger) 'debug)]) (void (thread (lambda () (let loop () (let ([v (sync receiver)]) (display (vector-ref v 1)) (newline)) (loop))))))) (start-up-debug-printing) (log-warning "hello") ;;;;;; If I press Run three times, the third time does not show output. Am I using the logging system properly? From jkominek at miranda.org Sun Aug 10 17:54:23 2008 From: jkominek at miranda.org (Jay F Kominek) Date: Thu Mar 26 02:25:23 2009 Subject: [plt-scheme] one macro in another? Message-ID: <20080810215423.GK31535@miranda.org> This is roughly what I'm trying to accomplish: (define-syntax transaction (lambda (stx) (syntax-case stx () [(_ expr ...) #`(let ([final-proc #f]) #,(define-syntax finally (lambda (stx) (syntax-case stx () [(_ exp (... ...)) (syntax (set! final-proc (lambda () exp (... ...))))]))) (let ([v (begin expr ...)]) (when (procedure? final-proc) (final-proc) v)))]))) But you can't stick define-syntax in let. A pointer in the right direction would be appreciated. I have a feeling I need some kind of with-syntax or let-syntax thingy, but I havn't had the first bit of luck figuring that out. The goal, for what it is worth, is to be able to write something like (transaction (set-account-balance (+ 10 (read-account-balance))) (finally (printf "account balance updated~n"))) or even (transaction (let ([new-balance (+ 10 (read-account-balance))]) (set-account-balance new-balance) (finally (printf "new balance is: ~a~n" new-balance)))) and have some behind-the-scenes logic rerun the transaction body as necessary to deal with serialization or deadlock errors, and then at the very end just run the finally block. -- Jay Kominek From samth at ccs.neu.edu Sun Aug 10 18:56:41 2008 From: samth at ccs.neu.edu (Sam TH) Date: Thu Mar 26 02:25:23 2009 Subject: [plt-scheme] Rationale of the object system? In-Reply-To: <200808101933.57094.michael@schuerig.de> References: <200808101933.57094.michael@schuerig.de> Message-ID: <63bb19ae0808101556pf1c61a1s345a9cf9cb6ad12e@mail.gmail.com> I recommend looking at this paper: Scheme with Classes Mixins and Traits, from http://www.cs.utah.edu/~mflatt/publications/index.html in which the designers discuss many of these questions. sam th On Sun, Aug 10, 2008 at 12:33 PM, Michael Schuerig wrote: > > I was introduced to "real" programming through SICP ages ago. Since then > I've kept an eye on Lisp and Scheme, but never went further than > reading several books for inspiration (Graham, PAIP, AMOP, Keene, > Seibel). Meanwhile, my income has been coming from C++, Java, and, for > the last few years, Ruby. The Ruby community has become a bit crowded > recently and thus provided a good incentive to move onward. As I wanted > a dynamic language, the choice was between Common Lisp and Scheme and > for the time being, I've settled on (PLT) Scheme. > > If I have one regret, it is missing out on CLOS and the MOP. By > comparison, the PLT Scheme object system looks rather conventional (at > least from a Rubyist's point of view). Certainly the designers of this > object system knew CLOS and going the other way must have been a > conscious decision, I take it. If anyone remembers the tale, I'd be > curious to hear it. > > I've found Swindle, of course, and I'm wondering whether it is > practically possible to use it instead of the "native" object system. > Or maybe mix the two systems without too much pain. > > Michael > > -- > Michael Schuerig > mailto:michael@schuerig.de > http://www.schuerig.de/michael/ > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -- sam th samth@ccs.neu.edu From eli at barzilay.org Sun Aug 10 21:29:44 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:23 2009 Subject: [plt-scheme] one macro in another? In-Reply-To: <20080810215423.GK31535@miranda.org> References: <20080810215423.GK31535@miranda.org> Message-ID: <18591.38408.827839.121649@arabic.ccs.neu.edu> On Aug 10, Jay F Kominek wrote: > This is roughly what I'm trying to accomplish: > > (define-syntax transaction > (lambda (stx) > (syntax-case stx () > [(_ expr ...) > #`(let ([final-proc #f]) > #,(define-syntax finally > (lambda (stx) > (syntax-case stx () > [(_ exp (... ...)) > (syntax (set! final-proc (lambda () exp (... ...))))]))) > (let ([v (begin > expr ...)]) > (when (procedure? final-proc) > (final-proc) > v)))]))) I'm not sure what you're trying to do here, partially because `finally' is not used in your macro, so I think that you have some other confusion. > But you can't stick define-syntax in let. [...] More specifically, the bove code is trying to define `finally' at the wrong level -- in the macro body instead of something that is visible to the user of the macro. (That's also my guess based on what you explain below.) > The goal, for what it is worth, is to be able to write something like > (transaction > (set-account-balance (+ 10 (read-account-balance))) > (finally (printf "account balance updated~n"))) > or even > (transaction > (let ([new-balance (+ 10 (read-account-balance))]) > (set-account-balance new-balance) > (finally (printf "new balance is: ~a~n" new-balance)))) > and have some behind-the-scenes logic rerun the transaction body as > necessary to deal with serialization or deadlock errors, and then at > the very end just run the finally block. It looks like your goal is to capture `finally' unhygienicly by the transaction macro -- a better way to do that is to use syntax parameters, but in this case I don't think that even that is needed. As stated above, I don't see a need for anything beyond plain Scheme code: (let ([new-balance (+ 10 (read-account-balance))]) (set-account-balance new-balance) (printf "new balance is: ~a~n" new-balance)) where if `set-account-balance' throws an error, you never get to the printout. So I'll try to complicate things -- assuming that there is some `capture-checkpoint' and `restore-checkpoint' functions with the obvious meanings. In this case, I think that this is close to what you want: (let ([cp #f]) (dynamic-wind (lambda () (set! cp (capture-checkpoint))) (lambda () (let ([new-balance (+ 10 (read-account-balance))]) (set-account-balance new-balance) (set! cp #f) ; no errors => transaction successful (printf "new balance is: ~a~n" new-balance))) (lambda () (when cp (restore-checkpoint cp))))) Deriving a macro from this should be easy now. Alternatively, you might want to have `finally' clauses appear anywhere in the code, and that's easy to do too, here's a rough sketch: (define final-thunks (make-parameter #f)) (define-syntax finally (syntax-rules () [(finally expr ...) (let ([thunks (final-thunks)]) (if thunks (final-thunks (cons (lambda () expr ...) thunks)) (error 'finally "cannot be used outside of `transaction'")))])) (define-syntax transaction (syntax-rules () [(transaction expr ...) (if (final-thunks) (error 'transaction "no nested transactions") (parameterize ([final-thunks '()]) expr ... ;; get here only if there were no errors (for-each (lambda (t) (t)) (final-thunks))))])) -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From skyo at ccs.neu.edu Sun Aug 10 23:18:53 2008 From: skyo at ccs.neu.edu (Sky O'Mara) Date: Thu Mar 26 02:25:24 2009 Subject: [plt-scheme] codeswarm In-Reply-To: References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> Message-ID: I am able to play the original .avi file with VLC. I recommend it for watching .avi videos. But I just uploaded a higher-resolution version to vimeo. You should be able to watch it fine there: http://vimeo.com/1505564 Both of those videos were generated without applying much effort, so there are some obvious flaws (like the first minute of the video). All I did was run 'svn log -v' on the trunk to get the revision history. Some time soon I'll see if I can run it with the CVS history added to get a more complete history of PLT. - Sky O. On Aug 10, 2008, at 12:43 PM, Matthias Felleisen wrote: > > Sky, I could display the standard codeswarm movies on my Mac but not > yours. Any idea which component you have that could be missing from > mine? > > > On Aug 10, 2008, at 10:27 AM, Sky O'Mara wrote: > >> I was curious, so I downloaded codeswarm and gave it a quick run on >> the plt subversion trunk. Here's the video: >> >> http://homepage.mac.com/skyboy/plt-codeswarm.avi >> >> It starts off a little weird, and not much happens for the first >> minute or so. Then Eli pulls a bunch of files in and the activity >> picks up. It's quite beautiful. >> >> -Sky O. >> >> On Aug 7, 2008, at 10:02 PM, Geoffrey S. Knauth wrote: >> >>> Some day I'd like to see code_swarm run on the PLT tree. >>> >>> http://vis.cs.ucdavis.edu/~ogawa/codeswarm/ >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080810/5a6230c5/attachment.htm From sk at cs.brown.edu Sun Aug 10 23:35:45 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:25:24 2009 Subject: [plt-scheme] codeswarm In-Reply-To: References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> Message-ID: Awesome. This proves that Eli is the pole star of our firmament. A slightly drunk and lurching pole star, though. Shriram From eli at barzilay.org Mon Aug 11 00:15:32 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:24 2009 Subject: [plt-scheme] codeswarm In-Reply-To: References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> Message-ID: <18591.48356.602363.452603@arabic.ccs.neu.edu> On Aug 10, Shriram Krishnamurthi wrote: > Awesome. This proves that Eli is the pole star of our firmament. > > A slightly drunk and lurching pole star, though. :) Most of that jitter seems to be due to that timestamp file. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From DekuDekuplex at Yahoo.com Mon Aug 11 01:31:17 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:25:24 2009 Subject: [plt-scheme] Re: More pedagogic stuff References: Message-ID: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> On Sun, 10 Aug 2008 02:00:33 -0700 (PDT), wooks wrote: >Hopefully I got the right link this time. > >http://www.bcs.org/server.php?show=ConWebDoc.18854 Even in industry, not all programmers are in favor of object-orientedness. As a side topic, back in about 1992, I used to work temporarily part-time during the summer as a translator for a project leader/programmer at CadWare, in New Haven, CT, and this person told me that he actually preferred straight C to C++ because he found that the object-orientedness of C++ made programs much more difficult to trace in debugging when porting from one platform to another. While I was at college, we never covered object-oriented languages. We covered Scheme for Introduction to Computer Science as well as Data Structures & Programming Techniques, Haskell for functional programming, and C for Introduction to Systems Programming, but never any object-oriented language. -- Benjamin L. Russell From DekuDekuplex at Yahoo.com Mon Aug 11 01:57:20 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:25:25 2009 Subject: [plt-scheme] Re: More pedagogic stuff References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> Message-ID: On Mon, 11 Aug 2008 14:31:17 +0900, Benjamin L.Russell wrote: >While I was at college, we never covered object-oriented languages. We >covered Scheme for Introduction to Computer Science as well as Data >Structures & Programming Techniques, Haskell for functional >programming, and C for Introduction to Systems Programming, but never >any object-oriented language. I forgot to mention that this was back in 1990-1994, before Java came along. Nevertheless, even now, it is ML, not Java, that has replaced Scheme in Introduction to Computer Science, so the trend seems to be more toward functional programming in a first course, rather than object-oriented programming. -- Benjamin L. Russell From michael at schuerig.de Mon Aug 11 04:04:12 2008 From: michael at schuerig.de (Michael Schuerig) Date: Thu Mar 26 02:25:25 2009 Subject: [plt-scheme] Re: Rationale of the object system? In-Reply-To: <18591.14215.374850.726661@arabic.ccs.neu.edu> References: <200808101933.57094.michael@schuerig.de> <18591.14215.374850.726661@arabic.ccs.neu.edu> Message-ID: <200808111004.12458.michael@schuerig.de> Eli, thanks for your extensive reply. On Sunday 10 August 2008, Eli Barzilay wrote: > On Aug 10, Michael Schuerig wrote: > > If I have one regret, it is missing out on CLOS and the MOP. By > > comparison, the PLT Scheme object system looks rather conventional > > (at least from a Rubyist's point of view). Certainly the designers > > of this object system knew CLOS and going the other way must have > > been a conscious decision, I take it. If anyone remembers the tale, > > I'd be curious to hear it. > > I don't know the tale, but having gone through implementing Swindle, > I can tell why I wouldn't have chosen it as the OO model to use. The > CLOS-style OO is extremely slow by default, there is a lot of place > for improvements (which most serious CLOS implementations do, and > swindle also does, to some degree), but it's still an order of > magnitude away from non-OO code. [snip] > Now, the fact that you have such a high price must come with some > advantages -- in this case it's the extreme flexibility that you get > because of the MOP. You can pretty much change the face of the > system completely with the given hooks and make it do anything you > want. However, in practice I've seen almost no use of these > capabilities. It would be ideal if one only had to pay the performance price for the flexibility that is actually used in each instance. As you indicate, this at least involves a lot of low-level trickery, and may not be possible in general. > So the bottom line so far is: you pay a heavy price; you get a lot > for it; it's questionable if you actually need that kind of > flexibility or if it's a good idea to use it. > > So far, it's still seems like a good thing to invest in, but the real > killer is the side-effect that is inherent in defining new methods in > CLOS. The result of this is a system that is "too open" due to the > fact that you can always change behaviors by adding and overriding > methods -- there's always a foot around that you can accidently > shoot. I have to admit that this openness is part of what attracts me to CLOS-style (generic function-based) OO. As most of my dynamic language experience is with Ruby, I've come to appreciate and like the ability to add functionality to existing classes. Nonetheless, I'm aware of the utter non-modularity of it, and occassionally have been bitten. > You might know the "thieves and bums use C++ and nice people > use CLOS" quote, which is (IMO) pretty misguided: if the only way to > achieve a specific piece of functionality is by extending it in a way > that is visible by all other code, then each such change can lead to > potential debugging catastrophes. No, I didn't know that one, but another one involving value and cost came to my mind while reading your earlier paragraphs. > > I've found Swindle, of course, and I'm wondering whether it is > > practically possible to use it instead of the "native" object > > system. Or maybe mix the two systems without too much pain. > > That depends. Getting the two systems is easy -- all you need is > require both and use a prefix to disambiguate. But it's still > question if this will be too much pain for you or not. Another > relevant question is whether you'll want to use existing code > (usually GUI stuff) -- in that case it's probably better to avoid > swindle. That's as much as I expected. I feel a little like my anticipation for getting one kind of candy has been thwarted by receiving another kind, which may be just as sweet, but not what I was pining for. Michael -- Michael Schuerig mailto:michael@schuerig.de http://www.schuerig.de/michael/ From michael at schuerig.de Mon Aug 11 04:06:05 2008 From: michael at schuerig.de (Michael Schuerig) Date: Thu Mar 26 02:25:25 2009 Subject: [plt-scheme] Re: Rationale of the object system? In-Reply-To: <63bb19ae0808101556pf1c61a1s345a9cf9cb6ad12e@mail.gmail.com> References: <200808101933.57094.michael@schuerig.de> <63bb19ae0808101556pf1c61a1s345a9cf9cb6ad12e@mail.gmail.com> Message-ID: <200808111006.05673.michael@schuerig.de> On Monday 11 August 2008, Sam TH wrote: > I recommend looking at this paper: > > Scheme with Classes Mixins and Traits, from > http://www.cs.utah.edu/~mflatt/publications/index.html > > in which the designers discuss many of these questions. Sam, thanks for pointing out this paper, it was an interesting read and I found more stuff to read along the way. Michael -- Michael Schuerig mailto:michael@schuerig.de http://www.schuerig.de/michael/ From michael at schuerig.de Mon Aug 11 05:09:16 2008 From: michael at schuerig.de (Michael Schuerig) Date: Thu Mar 26 02:25:25 2009 Subject: [plt-scheme] Relation to r6rs? Message-ID: <200808111109.17111.michael@schuerig.de> I've been reading the PLT Scheme guide and r6rs more or less in parallel and at times I've been scratching my head. Specifically, I don't understand how libraries (r6rs), modules (plt) and units (plt) are related. Is there some general advice for writing/structuring code so that it is standard-conformant and portable and at the same time makes good use of what PLT Scheme provides on top or r6rs? Michael -- Michael Schuerig mailto:michael@schuerig.de http://www.schuerig.de/michael/ From jos.koot at telefonica.net Mon Aug 11 06:16:03 2008 From: jos.koot at telefonica.net (Jos Koot) Date: Thu Mar 26 02:25:25 2009 Subject: [plt-scheme] one macro in another? References: <20080810215423.GK31535@miranda.org> Message-ID: <000c01c8fb9b$42fdefa0$2101a8c0@uw2b2dff239c4d> In this case you should not use syntax-unquote, but you must introduce identifier "finally" by means of datum->syntax (or datum->syntax-object) in order to make it visible within the form that calls transaction. Jos ----- Original Message ----- From: "Jay F Kominek" To: Sent: Sunday, August 10, 2008 11:54 PM Subject: [plt-scheme] one macro in another? > This is roughly what I'm trying to accomplish: > > (define-syntax transaction > (lambda (stx) > (syntax-case stx () > [(_ expr ...) > #`(let ([final-proc #f]) > #,(define-syntax finally > (lambda (stx) > (syntax-case stx () > [(_ exp (... ...)) > (syntax (set! final-proc (lambda () exp (... > ...))))]))) > (let ([v (begin > expr ...)]) > (when (procedure? final-proc) > (final-proc) > v)))]))) > > But you can't stick define-syntax in let. > > A pointer in the right direction would be appreciated. I have a > feeling I need some kind of with-syntax or let-syntax thingy, but > I havn't had the first bit of luck figuring that out. > > > The goal, for what it is worth, is to be able to write something like > (transaction > (set-account-balance (+ 10 (read-account-balance))) > (finally (printf "account balance updated~n"))) > or even > (transaction > (let ([new-balance (+ 10 (read-account-balance))]) > (set-account-balance new-balance) > (finally (printf "new balance is: ~a~n" new-balance)))) > and have some behind-the-scenes logic rerun the transaction body as > necessary to deal with serialization or deadlock errors, and then at > the very end just run the finally block. > > -- > Jay Kominek > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From wookiz at hotmail.com Mon Aug 11 06:33:07 2008 From: wookiz at hotmail.com (wooks) Date: Thu Mar 26 02:25:25 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: Message-ID: <4f5cd174-0e03-428c-8cbb-3135b25e7ed8@c58g2000hsc.googlegroups.com> On Aug 10, 1:52 pm, "Shriram Krishnamurthi" wrote: > Is there a point here beyond that this author seems to be hopelessly > outdated in his understanding of CS? > Assuming this is true, what does it say about the organisation that gave him the platform to publish his view. From grettke at acm.org Mon Aug 11 08:14:36 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:25 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <4f5cd174-0e03-428c-8cbb-3135b25e7ed8@c58g2000hsc.googlegroups.com> References: <4f5cd174-0e03-428c-8cbb-3135b25e7ed8@c58g2000hsc.googlegroups.com> Message-ID: <756daca50808110514l27342b9sbee07d19301f23fe@mail.gmail.com> On Mon, Aug 11, 2008 at 5:33 AM, wooks wrote: > On Aug 10, 1:52 pm, "Shriram Krishnamurthi" wrote: >> Is there a point here beyond that this author seems to be hopelessly >> outdated in his understanding of CS? >> > > Assuming this is true, what does it say about the organisation that > gave him the platform to publish his view. It says that well-spoken people won't publish under that organization ;). From mflatt at cs.utah.edu Mon Aug 11 08:42:12 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:25:26 2009 Subject: [plt-scheme] Relation to r6rs? In-Reply-To: <200808111109.17111.michael@schuerig.de> References: <200808111109.17111.michael@schuerig.de> Message-ID: <20080811124214.561B3650094@mail-svr1.cs.utah.edu> At Mon, 11 Aug 2008 11:09:16 +0200, Michael Schuerig wrote: > I've been reading the PLT Scheme guide and r6rs more or less in parallel > and at times I've been scratching my head. Specifically, I don't > understand how libraries (r6rs), modules (plt) and units (plt) are > related. Libraries and modules are the same sort of thing. A unit is another layer of abstraction and indirection. The difference between a module and a unit is similar to the difference between (+ x 3) and (lambda (x) (+ x 3)) The former adds 3 to `x' in the context of a specific `x', while the latter gives you a function that lets you pick `x' later and that can be used multiple times in the same program with different `x's. A unit is similarly a kind of module that is parameterized over its imports, so someone can choose specific imports later, and the unit can be used multiple times with different imports in the same program. > Is there some general advice for writing/structuring code so that it is > standard-conformant and portable and at the same time makes good use of > what PLT Scheme provides on top or r6rs? I'll leave this question to others who have tried it. Matthew From skyo at ccs.neu.edu Mon Aug 11 10:00:47 2008 From: skyo at ccs.neu.edu (Sky O'Mara) Date: Thu Mar 26 02:25:26 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <18591.48356.602363.452603@arabic.ccs.neu.edu> References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> <18591.48356.602363.452603@arabic.ccs.neu.edu> Message-ID: I now have another video up, this time with the timestamp file removed and the CVS history added: http://www.vimeo.com/1508560 Hope you enjoy! - Sky O. On Aug 11, 2008, at 12:15 AM, Eli Barzilay wrote: > On Aug 10, Shriram Krishnamurthi wrote: >> Awesome. This proves that Eli is the pole star of our firmament. >> >> A slightly drunk and lurching pole star, though. > > :) > > Most of that jitter seems to be due to that timestamp file. > > -- > ((lambda (x) (x x)) (lambda (x) (x x))) Eli > Barzilay: > http://www.barzilay.org/ Maze is > Life! From grettke at acm.org Mon Aug 11 10:11:42 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:26 2009 Subject: [plt-scheme] codeswarm In-Reply-To: References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> <18591.48356.602363.452603@arabic.ccs.neu.edu> Message-ID: <756daca50808110711i18e8e28m631e52ca1112c9e@mail.gmail.com> On Mon, Aug 11, 2008 at 9:00 AM, Sky O'Mara wrote: > Hope you enjoy! Thank you, I did, that is very neat. From eli at barzilay.org Mon Aug 11 10:56:09 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:26 2009 Subject: [plt-scheme] codeswarm In-Reply-To: References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> <18591.48356.602363.452603@arabic.ccs.neu.edu> Message-ID: <18592.21257.379861.887332@arabic.ccs.neu.edu> On Aug 11, Sky O'Mara wrote: > I now have another video up, this time with the timestamp file removed > and the CVS history added: > > http://www.vimeo.com/1508560 > > Hope you enjoy! That's *much* better. Very nice. Now all that we need is a good soundtrack, and some titles mentioning major events. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From matthias at ccs.neu.edu Mon Aug 11 11:31:17 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:26 2009 Subject: [plt-scheme] Re: Rationale of the object system? In-Reply-To: <200808111006.05673.michael@schuerig.de> References: <200808101933.57094.michael@schuerig.de> <63bb19ae0808101556pf1c61a1s345a9cf9cb6ad12e@mail.gmail.com> <200808111006.05673.michael@schuerig.de> Message-ID: If you read the paper (and some of the references) you may realize that PLT Scheme's class library makes it easy to enter if you are a Java programmer (or C++ to some extent) but then there is lots more and that the extras aren't as conventional as you may have thought (based on your original email). Our class system grew up in parallel to our needs for a GUI system (wx), which came in C++. The key has always been to introduce abstractions THAT WE FIND USEFUL and to REDUCE COST where possible. For example, this suggested a switch from multiple inheritance to mixins. Your insight of "pay as you go" is correct but as you may also know, language designers and implementors have struggled with this guideline for as long as they have designed and implemented languages. Finally, coming from Ruby you may find that the warts are gone and the dynamic nature remains. Ask away when you need help and welcome aboard. -- Matthias On Aug 11, 2008, at 4:06 AM, Michael Schuerig wrote: > On Monday 11 August 2008, Sam TH wrote: >> I recommend looking at this paper: >> >> Scheme with Classes Mixins and Traits, from >> http://www.cs.utah.edu/~mflatt/publications/index.html >> >> in which the designers discuss many of these questions. > > Sam, thanks for pointing out this paper, it was an interesting read > and > I found more stuff to read along the way. > > Michael > > -- > Michael Schuerig > mailto:michael@schuerig.de > http://www.schuerig.de/michael/ > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From sk at cs.brown.edu Mon Aug 11 11:41:04 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:25:26 2009 Subject: [plt-scheme] More pedagogic stuff In-Reply-To: References: Message-ID: I was asked what I dislike about this article. Besides the simplistic reasoning, I am opposed to the whole idea of programming languages (or even much of programming) being organized around "paradigms". Here is a short and intentionally somewhat provocative article that I recently wrote about this: http://www.cs.brown.edu/~sk/Publications/Papers/Published/sk-teach-pl-post-linnaean/ S. From matthias at ccs.neu.edu Mon Aug 11 12:11:47 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:26 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> Message-ID: 1. Don't confuse elite research universities with institutions that use "University" in their name only because someone decided everyone should get a degree from a college/university. My hunch is that to this day, 90% of these places claim to teach OO early and first. (Reality: At least they use an OO language to teach Fortran.) 2. Last week, I had a private exchange with a person close to core PLT. The email basically said that during a consulting presentation with a major industrial software producer, one of the attendees got up and said "it is way to expensive to use object in (this) area of business. We use records and functions." I wouldn't be surprised if this is true and becomes more true so as companies that create networked software discover the cost of moving back and forth (serialize and unserialize). -- Matthias On Aug 11, 2008, at 1:57 AM, Benjamin L.Russell wrote: > On Mon, 11 Aug 2008 14:31:17 +0900, Benjamin L.Russell > wrote: > >> While I was at college, we never covered object-oriented >> languages. We >> covered Scheme for Introduction to Computer Science as well as Data >> Structures & Programming Techniques, Haskell for functional >> programming, and C for Introduction to Systems Programming, but never >> any object-oriented language. > > I forgot to mention that this was back in 1990-1994, before Java came > along. Nevertheless, even now, it is ML, not Java, that has replaced > Scheme in Introduction to Computer Science, so the trend seems to be > more toward functional programming in a first course, rather than > object-oriented programming. > > -- Benjamin L. Russell > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From martindemello at gmail.com Mon Aug 11 12:48:22 2008 From: martindemello at gmail.com (Martin DeMello) Date: Thu Mar 26 02:25:27 2009 Subject: [plt-scheme] codeswarm In-Reply-To: References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> <18591.48356.602363.452603@arabic.ccs.neu.edu> Message-ID: On Mon, Aug 11, 2008 at 7:00 AM, Sky O'Mara wrote: > I now have another video up, this time with the timestamp file removed and > the CVS history added: > > http://www.vimeo.com/1508560 > > Hope you enjoy! Fascinating. I was expecting a tipping point where development went from mostly-C to mostly-scheme, but there was a constant mix throughout. Is the apparent lack of documentation activity because docs are written inline and then generated rather than checked into svn in final form? martin From cce at ccs.neu.edu Mon Aug 11 13:13:48 2008 From: cce at ccs.neu.edu (Carl Eastlund) Date: Thu Mar 26 02:25:27 2009 Subject: [plt-scheme] codeswarm In-Reply-To: References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> <18591.48356.602363.452603@arabic.ccs.neu.edu> Message-ID: <990e0c030808111013p409c08ao5f5dcf5dcd76b6ce@mail.gmail.com> On Mon, Aug 11, 2008 at 12:48 PM, Martin DeMello wrote: > On Mon, Aug 11, 2008 at 7:00 AM, Sky O'Mara wrote: >> I now have another video up, this time with the timestamp file removed and >> the CVS history added: >> >> http://www.vimeo.com/1508560 >> >> Hope you enjoy! > > Fascinating. I was expecting a tipping point where development went > from mostly-C to mostly-scheme, but there was a constant mix > throughout. Is the apparent lack of documentation activity because > docs are written inline and then generated rather than checked into > svn in final form? > > martin I think the video is not actually detecting our main documentation files. I'll check with Sky to see what it's calling "documentation". -- Carl Eastlund From robby at cs.uchicago.edu Mon Aug 11 13:30:21 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:27 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <990e0c030808111013p409c08ao5f5dcf5dcd76b6ce@mail.gmail.com> References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> <18591.48356.602363.452603@arabic.ccs.neu.edu> <990e0c030808111013p409c08ao5f5dcf5dcd76b6ce@mail.gmail.com> Message-ID: <932b2f1f0808111030i3be4dea1q19f923b9990d225@mail.gmail.com> Our documentation only recently moved into a public portion of the SVN archive anyways. Robby On Mon, Aug 11, 2008 at 12:13 PM, Carl Eastlund wrote: > On Mon, Aug 11, 2008 at 12:48 PM, Martin DeMello > wrote: >> On Mon, Aug 11, 2008 at 7:00 AM, Sky O'Mara wrote: >>> I now have another video up, this time with the timestamp file removed and >>> the CVS history added: >>> >>> http://www.vimeo.com/1508560 >>> >>> Hope you enjoy! >> >> Fascinating. I was expecting a tipping point where development went >> from mostly-C to mostly-scheme, but there was a constant mix >> throughout. Is the apparent lack of documentation activity because >> docs are written inline and then generated rather than checked into >> svn in final form? >> >> martin > > I think the video is not actually detecting our main documentation > files. I'll check with Sky to see what it's calling "documentation". > > -- > Carl Eastlund > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From gregory.woodhouse at gmail.com Mon Aug 11 13:59:54 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:25:28 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> Message-ID: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> On Aug 11, 2008, at 9:11 AM, Matthias Felleisen wrote: > > 2. Last week, I had a private exchange with a person close to core > PLT. The email basically said that during a consulting presentation > with a major industrial software producer, one of the attendees got > up and said "it is way to expensive to use object in (this) area of > business. We use records and functions." I wouldn't be surprised if > this is true and becomes more true so as companies that create > networked software discover the cost of moving back and forth > (serialize and unserialize). That reminds me of a similar argument over whether or not XML is overly verbose. Many organizations are moving toward web services rather than Java RMI, and application servers offer built-in features for exposing EJBs through web services. So it's the same thing: cost of seralization/deserialization. Taking it a step further: middleware products often employ proprietary protocols internally (that is to say between network nodes running the same middleware producy) "In the human mind, one-sidedness has always been the rule and many-sidedness the exception. Hence, even in revolutions of thought, one part of the truth usually sets while another rises." --John Stuart Mill http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080811/b9622dea/attachment.html From matthias at ccs.neu.edu Mon Aug 11 14:05:21 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:28 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> Message-ID: <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> A while ago, Shriram and I wrote up a short essay on our perspective of why CS hasn't latched on in high school for some 25 years now and what we might wish to do about it: http://www.ccs.neu.edu/home/matthias/essays/not-matter.html This is a preliminary draft of an opinion column that will appear in CACM, ACM's "flagship" publication (whatever that's supposed to mean). -- Matthias From yarkun at gmail.com Mon Aug 11 14:22:29 2008 From: yarkun at gmail.com (Yavuz Arkun) Date: Thu Mar 26 02:25:28 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <932b2f1f0808111030i3be4dea1q19f923b9990d225@mail.gmail.com> References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> <18591.48356.602363.452603@arabic.ccs.neu.edu> <990e0c030808111013p409c08ao5f5dcf5dcd76b6ce@mail.gmail.com> <932b2f1f0808111030i3be4dea1q19f923b9990d225@mail.gmail.com> Message-ID: <2748b30b0808111122r7185c72eha30ef95e4f809da5@mail.gmail.com> "PLT Scheme: The Movie" VO: Just when you thought it was safe to commit..." Heartbeat soundtrack starts. VO: "...THEY came...from outermost recesses of long-forgotten hard drives..." Primal screams, coming nearer. VO: "...they swarmed their way into our PCs, Macs, files, directories..." A final, blood curdling, toe-curling scream. VO: "...the lambdas are among US. They are in our CODE. Are we ready?" (Sorry, couldn't resist. Now if I could only work in a drop-dead gorgeous love interest I think we have a saleble pitch.) --Yavuz From grettke at acm.org Mon Aug 11 14:57:43 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:28 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <2748b30b0808111122r7185c72eha30ef95e4f809da5@mail.gmail.com> References: <18591.48356.602363.452603@arabic.ccs.neu.edu> <990e0c030808111013p409c08ao5f5dcf5dcd76b6ce@mail.gmail.com> <932b2f1f0808111030i3be4dea1q19f923b9990d225@mail.gmail.com> <2748b30b0808111122r7185c72eha30ef95e4f809da5@mail.gmail.com> Message-ID: <756daca50808111157h18526a61m1a8a0a249cd0b747@mail.gmail.com> > (Sorry, couldn't resist.) Ditto. (Now if I could only work in a drop-dead gorgeous love interest I think we have a saleble pitch.) Reference the movie "Proof" :) From morazanm at gmail.com Mon Aug 11 14:57:59 2008 From: morazanm at gmail.com (Marco Morazan) Date: Thu Mar 26 02:25:28 2009 Subject: [plt-scheme] Benchmarks for HOFs Message-ID: <9b1fff280808111157u5960abcfr92b5a90d6c2a84ee@mail.gmail.com> Dear All, Is anyone aware of a standard set of benchmarks used to test the implementation of HOFs? Thanks, Marco From pivanyi at freemail.hu Mon Aug 11 16:37:31 2008 From: pivanyi at freemail.hu (Ivanyi Peter) Date: Thu Mar 26 02:25:28 2009 Subject: [plt-scheme] MrEd bug in tab-panel Message-ID: Hi, I think there is a bug (somewhere) in MrEd. In the following code the height should change and not the width. I think somewhere the stretchable-width and stretchable-height are "cross-wired". Best regards, Peter Ivanyi ------------------------------------------------------------------------- (module tab-test-2 mzscheme (require mzlib/class (lib "mred.ss" "mred") (lib "framework.ss" "framework") ) (define w (new frame% (label "Hello") (min-width 200) (min-height 200) )) (define tab-panel (new tab-panel% (parent w) (choices '("aa")))) (define single-panel (new panel:single% (parent tab-panel))) (define vert1 (new vertical-panel% (parent single-panel))) (define c1 (new canvas% (min-width 10) (min-height 10) (parent vert1))) ; this is the problem !!!!!!!!!!!!!!!!!!!!!! (send vert1 stretchable-height #f) (send w show #t) ) ______________________________________________________________________ Eg?sz ny?ron szombat esti l?z! http://videa.hu/videok/zene/mtv-icon-tribute-to-lgt-balaton-cokeclub-coketv-YUxNbEgI5kzWjLjP From mflatt at cs.utah.edu Mon Aug 11 18:15:26 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:25:28 2009 Subject: [plt-scheme] MrEd bug in tab-panel In-Reply-To: References: Message-ID: <20080811221527.F01406500A8@mail-svr1.cs.utah.edu> This was a bug in `panel:single%', now fixed in SVN. Thanks! Matthew At Mon, 11 Aug 2008 22:37:31 +0200 (CEST), Ivanyi Peter wrote: > Hi, > > I think there is a bug (somewhere) in MrEd. In the following > code the height should change and not the width. I think > somewhere the stretchable-width and stretchable-height > are "cross-wired". > > Best regards, > > Peter Ivanyi > > ------------------------------------------------------------------------- > > (module tab-test-2 mzscheme > (require mzlib/class > (lib "mred.ss" "mred") > (lib "framework.ss" "framework") > ) > > (define w (new frame% (label "Hello") > (min-width 200) > (min-height 200) > )) > > (define tab-panel (new tab-panel% (parent w) (choices > '("aa")))) > > (define single-panel (new panel:single% (parent tab-panel))) > > (define vert1 (new vertical-panel% (parent single-panel))) > (define c1 (new canvas% (min-width 10) (min-height 10) > (parent vert1))) > > ; this is the problem !!!!!!!!!!!!!!!!!!!!!! > (send vert1 stretchable-height #f) > > (send w show #t) > ) From deinst at gmail.com Mon Aug 11 20:37:07 2008 From: deinst at gmail.com (David Einstein) Date: Thu Mar 26 02:25:29 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> Message-ID: <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> I'm sure you have seen Alan Kay's tirades on the same subject.I do not think that the loss of the AP exam in CS is that great a loss. I tutored a friend's son for a few hours in preparation for it a few years ago, and felt increasingly like Harold Ramis teaching English as a second language in "Stripes". The test (or at least the things that I was asked to clarify) seemed to concentrate more on the syntactic and semantic filigree of java than on recognizing problem and decomposing them into digestible chunks. I was reminded of this passage from Polya's preface to 'How to Solve it' "It is foolish to answer a question that you do not understand. It is sad to work for and end that you do not desire. Such foolish and sad things often happen, in and out of school, but the teacher should try to prevent them from happening in his class." If it is of any consolation, though it shouldn't be, the situation is just as dire in mathematics and the sciences. Despite having been dragged through 'math' for over a decade, the average American is nearly innumerate. Judging from that track record, the average high school student is probably better served by learning things him/herself, even from 'Learn world domination in 21 days', than from his/her school. (I know where you stand on 'learn x in 21 days'). I do think that having things like HDTP and DrScheme available to anyone is a step towards a solution, all that needs to be done is to let the people who want to read it know where it is. On Mon, Aug 11, 2008 at 2:05 PM, Matthias Felleisen wrote: > > A while ago, Shriram and I wrote up a short essay on our perspective of why > CS hasn't latched on in high school for some 25 years now and what we might > wish to do about it: > > http://www.ccs.neu.edu/home/matthias/essays/not-matter.html > > This is a preliminary draft of an opinion column that will appear in CACM, > ACM's "flagship" publication (whatever that's supposed to mean). -- Matthias > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080811/5e9e9e88/attachment.htm From sk at cs.brown.edu Mon Aug 11 20:44:46 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:25:29 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> Message-ID: David, Working at a university that does not recognize the AP CS exams, I certainly agree with you about the exam. If *all* universities had the guts to take the same position, then the exam would quietly die away. What is sad is not that the exam got cancelled. It is that as a result the subject -- which as we all know is far more rich, interesting, etc. than the exam -- will invariably get dragged down a little along with the lost exam. It's the knock-on effects that bother Matthias and me. The exam itself, we toast its demise. Shriram From DekuDekuplex at Yahoo.com Mon Aug 11 22:54:15 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:25:29 2009 Subject: [plt-scheme] Re: More pedagogic stuff References: Message-ID: On Mon, 11 Aug 2008 11:41:04 -0400, "Shriram Krishnamurthi" wrote: >I was asked what I dislike about this article. Besides the simplistic >reasoning, I am opposed to the whole idea of programming languages (or >even much of programming) being organized around "paradigms". Here is >a short and intentionally somewhat provocative article that I recently >wrote about this: > >http://www.cs.brown.edu/~sk/Publications/Papers/Published/sk-teach-pl-post-linnaean/ Given that you consider languages as aggregations of features, rather than being defined by taxonomies, it would be interesting to learn your opinion on the multi-paradigm programming language Oz (and the associated programming system Mozart) (see http://www.mozart-oz.org/). This programming language accompanied the introductory computer science textbook _ Concepts, Techniques, and Models of Computer Programming_ (see http://www.info.ucl.ac.be/~pvr/book.html), by Peter Van Roy and Seif Haridi. Their premise is that "the conventional boundaries between paradigms are artificial and limiting," and attempt to "show programming as a unified discipline." However, because they used Erlang, Haskell, Java, and Prolog as representative members of separate paradigms, it would seem that they still fall into the fallacy, as you would probably put it, of definining languages by taxonomies, which is what you oppose. Am I correct in assuming that you would be opposed to their approach, and would rather dissect these languages into their constituent features? -- Benjamin L. Russell From sk at cs.brown.edu Mon Aug 11 23:27:43 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:25:30 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: Message-ID: I think at some fundamental level we do agree, and they do have a good book. But we do also have some points of real disagreement. For one thing, I think they somewhat conflate the line between *programming* and programming *languages*. Also, they have a huge agenda that is only mildly hidden, which is to promote Mozart/Oz as a canonical multi-paradigm or post-paradigm language. [The above two issues are related.] My book doesn't have such an agenda: I'm not out to push any particular language. Though I don't have a copy at my fingertips, I don't think their presentation of Erlang, etc., is a real problem. I believe they meant to show how to encode those languages, and used those languages as prototypical examples of disparate points in the design space. At the very least, those authors are sharp enough to not make as rudimentary a logical error as you suggest. That said, if a professor were to use their book instead of the crappy ones out there, that would be a great service to their students. Shriram From skyo at ccs.neu.edu Tue Aug 12 00:10:32 2008 From: skyo at ccs.neu.edu (Sky O'Mara) Date: Thu Mar 26 02:25:30 2009 Subject: [plt-scheme] codeswarm In-Reply-To: <990e0c030808111013p409c08ao5f5dcf5dcd76b6ce@mail.gmail.com> References: <49F615A1-F8CB-42D7-AC6D-F19E52669F82@ccs.neu.edu> <18591.48356.602363.452603@arabic.ccs.neu.edu> <990e0c030808111013p409c08ao5f5dcf5dcd76b6ce@mail.gmail.com> Message-ID: <85746701-FDD0-478C-A10A-11D78F05CDE3@ccs.neu.edu> I ran a little script to determine the most common file types encountered in the revision history, and these are the top 10: .ss 59874 .c 11565 .h 9323 .cxx 7055 .scrbl 6478 .cc 4954 .txt 2440 .inc 1894 .scm 1203 .xc 1014 (the number on the right corresponds to the number of times a file of that type was added or changed in the repository) My guess is that the yellow simply gets lost among the large quantity of blue, purple, and gray in the video. I configured codeswarm so that the Scheme color comes from from .ss and .scm files, the C/C++ color comes from .c, .h, .cxx, and .cc files, and Docs comes from .scrbl and .txt. That makes the total number for documentation files to be 11,432, which is about a fifth of the number of Scheme files, and almost a third of the number of C/C++ files. If there is any significant amount of documentation files other than scrbl and txt (and I presume there may be), then the files didn't show up in my svn log. Although it could always be a typo in the regex I used, or something. I don't see any, though... -Sky O. On Aug 11, 2008, at 1:13 PM, Carl Eastlund wrote: > On Mon, Aug 11, 2008 at 12:48 PM, Martin DeMello > wrote: >> On Mon, Aug 11, 2008 at 7:00 AM, Sky O'Mara wrote: >>> I now have another video up, this time with the timestamp file >>> removed and >>> the CVS history added: >>> >>> http://www.vimeo.com/1508560 >>> >>> Hope you enjoy! >> >> Fascinating. I was expecting a tipping point where development went >> from mostly-C to mostly-scheme, but there was a constant mix >> throughout. Is the apparent lack of documentation activity because >> docs are written inline and then generated rather than checked into >> svn in final form? >> >> martin > > I think the video is not actually detecting our main documentation > files. I'll check with Sky to see what it's calling "documentation". > > -- > Carl Eastlund > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From DekuDekuplex at Yahoo.com Tue Aug 12 02:15:59 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:25:30 2009 Subject: [plt-scheme] Re: More pedagogic stuff References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> Message-ID: On Mon, 11 Aug 2008 14:05:21 -0400, Matthias Felleisen wrote: > >A while ago, Shriram and I wrote up a short essay on our perspective >of why CS hasn't latched on in high school for some 25 years now and >what we might wish to do about it: > > http://www.ccs.neu.edu/home/matthias/essays/not-matter.html > >This is a preliminary draft of an opinion column that will appear in >CACM, ACM's "flagship" publication (whatever that's supposed to >mean). -- Matthias The idea of using interactive animation and games to motivate tying together mathematics and programming reminds me of the book _The Haskell School of Expression_ (see http://www.haskell.org/soe/), by Paul Hudak. There, "the author draws examples from multimedia applications, including graphics, animation, and computer music, thus rewarding the reader with working programs for inherently more interesting applications." In a course, Introduction to Computer Science, that I had audited under Hudak in college in 1994, the professor provided a very interesting project using Scheme, called "Schemetris," where students worked in pairs to code their graphical versions of Tetris in Scheme using libraries/modules supplied by the professor. My partner and I decided that my partner would decide which functions to write and provide their specifications, and that I would write the actual functions. Over 2-3 days, we got Schemetris working. It was hard work (I slept only 3 hours per day during this period), but was a fun programming experience, and dramatically increased my self-confidence at programming. Personally, I think that the key aspect of this exercise is that it was actually fun to do. This aspect too often seems to be belittled in schools, but students tend to learn best when they are having fun without explicitly realizing what they are learning. In my project, because it was fun to do, I was able to enter a so-called "flow state" while programming, and to become totally immersed in thinking about the project: For a while, there was only Scheme, Schemetris, and Emacs in my head; nothing else. (As a side note, for more information on a "flow state," see the following reference: Flow (psychology) - Wikipedia, the free encyclopedia: http://en.wikipedia.org/wiki/Flow_(psychology) ) During my entire college days, this was perhaps the only time that I entered a flow state while learning. I think that generating this flow state is very important in learning highly conceptual disciplines such as programming. It is very difficult, if not impossible, to enter this state if one does not enjoy the subject matter. This main difficulty seems to be that it is much harder to figure out how to teach the material in this kind of motivational manner than just to teach it straightforwardly. Overcoming this hurdle can require great creativity. Sometimes it seems that this creativity requires adopting the mind-set and academic level of the student. Paradoxically, when I was in college, one of the mathematics professors whose lectures I enjoyed most said that he wasn't sure if his style was best for teaching because he talked relatively slowly and clearly and repeated most of his main statements at least once (he joked once that he actually did this because the lecture started at 10 AM, and this was usually just before bedtime for him, because he usually stayed up all night in doing his research, and his mind just didn't work fast enough in the morning for him to lecture any more quickly). However, that helped immensely in allowing students to hear everything that he said clearly and to distinguish between key points and subordinate points. (He also often told jokes in class related to mathematics, which helped to keep the classes fun.) I earned my highest grades in mathematics in college under this professor. -- Benjamin L. Russell From michael at schuerig.de Tue Aug 12 03:31:33 2008 From: michael at schuerig.de (Michael Schuerig) Date: Thu Mar 26 02:25:30 2009 Subject: [plt-scheme] Re: Rationale of the object system? In-Reply-To: References: <200808101933.57094.michael@schuerig.de> <200808111006.05673.michael@schuerig.de> Message-ID: <200808120931.34084.michael@schuerig.de> On Monday 11 August 2008, Matthias Felleisen wrote: > If you read the paper (and some of the references) you may realize > that PLT Scheme's class library makes it easy to enter if you are a > Java programmer (or C++ to some extent) but then there is lots more > and that the extras aren't as conventional as you may have thought > (based on your original email). Conventional only in the sense of single-inheritance and based on message passing. It wasn't meant as derogatory, anyway. > Finally, coming from Ruby you may find that the warts are gone and > the dynamic nature remains. Yes, among other things that's what I came for. Michael -- Michael Schuerig mailto:michael@schuerig.de http://www.schuerig.de/michael/ From grettke at acm.org Tue Aug 12 06:38:00 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:30 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> Message-ID: <756daca50808120338h32217caelbedfb2d3e7e4f68a@mail.gmail.com> On Tue, Aug 12, 2008 at 1:15 AM, Benjamin L. Russell wrote: > when I was in college, one of the mathematics professors whose lectures I enjoyed > > allowing students to hear everything that he said clearly > and to distinguish between key points and subordinate points. (He > also often told jokes in class related to mathematics, which helped to > keep the classes fun.) I earned my highest grades in mathematics in > college under this professor. I had the very same experience (with a different professor though). I often wished that he had taught all of my math classes. From matthias at ccs.neu.edu Tue Aug 12 09:15:36 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:30 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> Message-ID: Fun is important but the claim of "fun" has been used for two or three decades to abuse students with Pascal, C/C+, and Java. Every organizer, APcrat, teacher asserted in no uncertain tone that programming in these languages was fun for the students (and implied that programming in something else wasn't). All we got out of this is that AP CS AB was cancelled, which I don't mind at all. The key is to make required, core subjects fun. Functional programming is mathematics and, if we stay as close as possible to algebra (conceptually), fun animations can teach algebra, geometry, pre-calc, mechanics, and possibly more. THAT is the powerful combination advertised in our column. -- Matthias P.S. Replace fun with a suitably popular word for "vocational motivation" and you get the same situation. From matthias at ccs.neu.edu Tue Aug 12 09:16:55 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:31 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> Message-ID: P.S. Yes, I have read Paul's book and I think Haskell has something to it. You may be surprised to learn, however, that world.ss animations are purely functional while Haskell animations (in Paul's book) are actually quasi-imperative. That is, they are using monads and carry the imperativeness on their sleeves. From deinst at gmail.com Tue Aug 12 09:55:46 2008 From: deinst at gmail.com (David Einstein) Date: Thu Mar 26 02:25:31 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> Message-ID: <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> On Mon, Aug 11, 2008 at 8:44 PM, Shriram Krishnamurthi wrote: > David, > > Working at a university that does not recognize the AP > CS exams, I certainly agree with you about the exam. > If *all* universities had the guts to take the same position, > then the exam would quietly die away. > > What is sad is not that the exam got cancelled. It is that > as a result the subject -- which as we all know is far more > rich, interesting, etc. than the exam -- will invariably get > dragged down a little along with the lost exam. I'm not sure that I agree. The classes that will be lost will be classes that are aimed at passing the test that are taught by people who, for the most part, know slightly more than their median student and considerably less than their best students. I am not sure that losing such classes hurts the dissemination of the rich, interesting stuff. I suspect that many high schools would not have even looked at HDTP because it did not come close to addressing the test. Schools are not judged on whether or not their students know anything useful or interesting, just whether they know that they need to to pass the test. (A month from now I am going to suffer the anual rant from my wife, who teaches freshman English, on how the MCAS is ruining what few skills her students might have had.) I think that the future lies in making things like HDTP, DrScheme, and Squeak available to students and/or schools, and letting them use then individually, or in groups. From my days in the Navy I know that computer aided self directed[*] learning can work, and if it could work in 1979 then it certainly should work now. Similar things happen with mathematics. Despite years of sitting in math classes, most people are not exposed to any of the rich, interesting, or even useful mathematics. I have yet to meet a high school math teacher, outside of a math conference, who has any interest or understanding of the beauty of mathematics > > > It's the knock-on effects that bother Matthias and me. The > exam itself, we toast its demise. Use the demise of the test to fix the system. I'm not sure that the ACM is the right venue for you to be ranting at, the MAA has been talking about reforming high school math for decades, but the people I know that teach undergraduates have not reported improvements. > > > Shriram > [*] Well, quasi self directed, the Navy did possess motivational techniqes that the average high school teacher or college professor can only dream of with the blackest part of his or her heart. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080812/0e7bbea6/attachment.html From sk at cs.brown.edu Tue Aug 12 10:33:55 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:25:31 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> Message-ID: Your navy footnote is amusing... You're right, the MAA is worth talking to. The ACM may be beyond hope. But we have to keep up at the ACM also, because ultimately outsiders (principals, parents, etc.) will look to the ACM when they need to make a decision. The problem w/ the demise of the courses is that it leaves schools free to label (as they have been doing already, even before the exam died) their computing literacy course (Excel, etc.) as "computer science". This in turn is going to have a serious effect on how students perceive the subject and whether they even try it in college. On the one hand, it's good: they'll come to college, see real CS, and say "Wow, this is totally different, and it's worth doing". But the loss is those who never try it out at all in college. Shriram From noelwelsh at gmail.com Tue Aug 12 10:55:54 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:32 2009 Subject: [plt-scheme] toString equivalent In-Reply-To: <6F6FCF17-9147-48C6-8DFD-E818370D7619@gmail.com> References: <6F6FCF17-9147-48C6-8DFD-E818370D7619@gmail.com> Message-ID: Hi Dave, As far as I know there is no equivalent to toString. I.e. no method that the printer will call to display an object. As you note, attaching a prop:custom-write property is the way to go about this, but I don't know how one can attach properties to objects. Objects are just structures, so it should be possible, but I don't think the class system exposes any way to do this. Perhaps Robby, who I believe develops the class system, can answer this. Cheers, Noel On Sat, Aug 9, 2008 at 2:05 PM, Dave Gurnell wrote: > Hi PLTers, > > I want a way to override the default way objects of a certain class get > printed. Is there any equivalent of Java's toString method in the PLT class > system? Alternatively, can I attach a prop:custom-write to a class, or is > there some way of customising the default printer? > > Cheers, > > -- Dave > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From noelwelsh at gmail.com Tue Aug 12 10:57:34 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:32 2009 Subject: [plt-scheme] csv.plt - expand: unbound variable in module in: set-cdr! In-Reply-To: <489E10DA.1030103@optushome.com.au> References: <489E10DA.1030103@optushome.com.au> Message-ID: Dear Lord Geoffrey, What you are seeing in an incompatibility between csv.plt and v4. Perhaps Neil can update csv.plt; I know he has received patches for this update. N. On Sat, Aug 9, 2008 at 10:49 PM, LordGeoffrey wrote: > Hi, > Is this something wrong with my drscheme configuration (which i always find > confusing) or incompatibilities with v4 > > Settings: > Language: Pretty Big (includes MrEd and Advanced Student); memory limit: 128 > megabytes. > > Used: > (require (planet "csv.ss" ("neil" "csv.plt" 1 1))) > > Thanks > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From matthias at ccs.neu.edu Tue Aug 12 11:06:10 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:33 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> Message-ID: [A couple of comments before I go off-line and do some real work.] On Aug 12, 2008, at 9:55 AM, David Einstein wrote: > A month from now I am going to suffer the anual rant from my wife, > who teaches freshman English, on how the MCAS is ruining what few > skills her students might have had. I find the complaining about tests like the MCAS and the TEKS plain bogus. It's another excuse from the teacher lobby. -- I grew up in a hard-core testing environment that makes SAT and MCAS and TEKS look like silly little distractions. My son has taken the MCAS and it is truly *minimal* competence. I recommend you buy your wife a copy of "Let's Kill Dick and Jane" -- it is the TeachScheme! story stretched over 35 years, started by a Chemical Engineer in the 1960s who just couldn't believe how bad US schools were back then. He had spent a year in Europe or Germany or somewhere with his wife and child. He then decided to use his money to improve K8 curricula with engineering methods. If I had read this history before, I would have never started this project (and would be poorer for it). ;; --- > I think that the future lies in making things like HDTP, DrScheme, > and Squeak available to students and/or schools, and letting them > use then individually, or in groups. This has been tried in many different settings and it doesn't work for the "average" child. Sure, we would like to attract the good ones and the brilliant, The goal though is to broaden the appeal of CS and to use it as a lever to get kids to understand plain math. > On Aug 12, 2008, at 10:33 AM, Shriram Krishnamurthi wrote: >> On the one hand, it's good: they'll come to college, see real CS, >> and say "Wow, this is totally different, and it's worth doing". >> But the loss is those who never try it out at all in college. Let me rephrase this. In a sense, we would all be better off if kids came w/ just a solid knowledge of English and Mathematics. Then again, look at Engineering disciplines. Students get very little exposure to this stuff, lack the Mathematics and English to go into these areas, don't even have any curiosity about them, and the result is a dearth of engineering students at the mid-range college levels. ;; --- > Well, quasi self directed, the Navy did possess motivational > techniqes that the average high school teacher or college professor > can only dream of with the blackest part of his or her heart. Right after I arrived at NU, some newspaper reported on an Australian swim coach's new trick for making his swimmers go faster. (I was a swim coach in Germany for a few years, so I was curious and read the article.) The coach added ... crocodiles to the those lanes where swimmers didn't live up to their potential. He taped up their snouts (mouths?) of the animals so that they wouldn't bite. While my wife thinks its animal abuse (because of the chlorine), my dean and I think that putting such animals into certain offices around here would be great, even if not legal :-) -- Matthias -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080812/f4e697b6/attachment.htm From deinst at gmail.com Tue Aug 12 11:17:37 2008 From: deinst at gmail.com (David Einstein) Date: Thu Mar 26 02:25:33 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> Message-ID: <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> I'm not sure that the MAA is the right place either. The people you need to get to are the students, and to a lesser extent, their parents and/or teachers, and you are not going to get to them via other academics. Today it is technically feasible as it never was before. The problem that remains is social/political, I'm not sure how to solve it, but I do not think that academia is where it will get solved. On Tue, Aug 12, 2008 at 10:33 AM, Shriram Krishnamurthi wrote: > Your navy footnote is amusing... > I cannot say that I thoroughly enjoyed the Navy schools, however, I learned more per unit time there than I did anywhere else in my life. > > You're right, the MAA is worth talking to. The ACM may be > beyond hope. But we have to keep up at the ACM also, > because ultimately outsiders (principals, parents, etc.) > will look to the ACM when they need to make a decision. > > The problem w/ the demise of the courses is that it leaves > schools free to label (as they have been doing already, even > before the exam died) their computing literacy course (Excel, > etc.) as "computer science". This is more depressing than I thought. > This in turn is going to have a > serious effect on how students perceive the subject and > whether they even try it in college. On the one hand, it's > good: they'll come to college, see real CS, and say "Wow, > this is totally different, and it's worth doing". But the loss is > those who never try it out at all in college. > > Shriram > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080812/9cc6c2b9/attachment.html From mflatt at cs.utah.edu Tue Aug 12 11:30:54 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:25:34 2009 Subject: [plt-scheme] hitting a race in logging? In-Reply-To: References: Message-ID: <20080812153054.C6C756500D9@mail-svr1.cs.utah.edu> This was a bug in the clean-up of GCed log readers. It's now fixed in SVN. Matthew At Sun, 10 Aug 2008 15:05:03 -0400, "Danny Yoo" wrote: > I'm hitting slightly weird behavior when I'm logging events, but I > don't yet see why. In DrScheme, the following program sometimes shows > "hello" as expected. But sometimes it doesn't! > > ;;;;;; > > #lang scheme > > (define (start-up-debug-printing) > (let ([receiver (make-log-receiver (current-logger) 'debug)]) > (void > (thread (lambda () > (let loop () > (let ([v (sync receiver)]) > (display (vector-ref v 1)) > (newline)) > (loop))))))) > (start-up-debug-printing) > > (log-warning "hello") > ;;;;;; > > > If I press Run three times, the third time does not show output. Am I > using the logging system properly? From mflatt at cs.utah.edu Tue Aug 12 11:40:41 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:25:34 2009 Subject: [plt-scheme] MrEd tab-panel% In-Reply-To: References: Message-ID: <20080812154041.71D6E6500AD@mail-svr1.cs.utah.edu> At Sun, 10 Aug 2008 12:02:26 +0200 (CEST), Ivanyi Peter wrote: > So I try to create a new tab-panel% class like in > frtime/gui/mod-mrpanel.ss > In this case the tab-panel% is a vertical-panel%, which contains > a tab-group%, however I also create a panel:single% object > inside which will do the switching. But I cannot add the > panel:single% > to tab-group% as tab-group% is not an internal container. > > So my question is: > How can I make a tab-group% object which is also an internal > container??? A tab-group% is a kind of (internal) control. A tab-panel% contains a hidden tab-group%, as you noted. So, it doesn't make sense to use a tab-group% as a parent. I think you do want to add to the panel containing the tab-group%. But I'm not clear on why the `on-subwindow-event' strategy doesn't work for tab-panel%. Isn't that method called with the tab-panel% object when it's clicked? Matthew From sk at cs.brown.edu Tue Aug 12 11:53:28 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:25:34 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> References: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> Message-ID: Nah, not depressing. Just an obstacle to overcome. People who were depressed about the state of HS education in the 90s -- before it became hot and fashionable to appear to do something -- sat around complaining about it but did nothing. We've always taken the opposite path. Shriram From neil at neilvandyke.org Tue Aug 12 11:38:27 2008 From: neil at neilvandyke.org (Neil Van Dyke) Date: Thu Mar 26 02:25:34 2009 Subject: [plt-scheme] csv.plt - expand: unbound variable in module in: set-cdr! In-Reply-To: References: <489E10DA.1030103@optushome.com.au> Message-ID: <48A1AE73.9080606@neilvandyke.org> I uploaded a new version, with a patch thanks to Doug Orleans. (require (planet "csv.ss" ("neil" "csv.plt" 1 2))) Peer pressure cannot get me to port HtmlPrag to PLT 4 until next week, however. Noel Welsh wrote at 08/12/2008 10:57 AM: > Dear Lord Geoffrey, > > What you are seeing in an incompatibility between csv.plt and v4. > Perhaps Neil can update csv.plt; I know he has received patches for > this update. > > N. > > On Sat, Aug 9, 2008 at 10:49 PM, LordGeoffrey > wrote: > >> Hi, >> Is this something wrong with my drscheme configuration (which i always find >> confusing) or incompatibilities with v4 >> >> Settings: >> Language: Pretty Big (includes MrEd and Advanced Student); memory limit: 128 >> megabytes. >> >> Used: >> (require (planet "csv.ss" ("neil" "csv.plt" 1 1))) >> >> Thanks >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> From deinst at gmail.com Tue Aug 12 12:05:20 2008 From: deinst at gmail.com (David Einstein) Date: Thu Mar 26 02:25:35 2009 Subject: Fwd: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> References: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> Message-ID: <56750b780808120905q3cee1cd2v572f5165e99dde3a@mail.gmail.com> ---------- Forwarded message ---------- From: David Einstein Date: Tue, Aug 12, 2008 at 11:17 AM Subject: Re: [plt-scheme] Re: More pedagogic stuff To: Shriram Krishnamurthi Cc: PLT List I'm not sure that the MAA is the right place either. The people you need to get to are the students, and to a lesser extent, their parents and/or teachers, and you are not going to get to them via other academics. Today it is technically feasible as it never was before. The problem that remains is social/political, I'm not sure how to solve it, but I do not think that academia is where it will get solved. On Tue, Aug 12, 2008 at 10:33 AM, Shriram Krishnamurthi wrote: > Your navy footnote is amusing... > I cannot say that I thoroughly enjoyed the Navy schools, however, I learned more per unit time there than I did anywhere else in my life. > > You're right, the MAA is worth talking to. The ACM may be > beyond hope. But we have to keep up at the ACM also, > because ultimately outsiders (principals, parents, etc.) > will look to the ACM when they need to make a decision. > > The problem w/ the demise of the courses is that it leaves > schools free to label (as they have been doing already, even > before the exam died) their computing literacy course (Excel, > etc.) as "computer science". This is more depressing than I thought. > This in turn is going to have a > serious effect on how students perceive the subject and > whether they even try it in college. On the one hand, it's > good: they'll come to college, see real CS, and say "Wow, > this is totally different, and it's worth doing". But the loss is > those who never try it out at all in college. > > Shriram > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080812/36067a08/attachment.htm From matthias at ccs.neu.edu Tue Aug 12 15:09:28 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:35 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> Message-ID: P.S. David, I appreciate your Navy experience. I was a paratrooper myself. What distinguishes this situation so much from the one in school and college is that your life depends on learning and performing well. (We lost 10-20% of the "students" in paratrooping school due to accidents, some really really bad. Nobody died.) From william.wood3 at comcast.net Tue Aug 12 15:25:22 2008 From: william.wood3 at comcast.net (Bill) Date: Thu Mar 26 02:25:35 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> Message-ID: <1218569122.11408.6.camel@localhost> On Tue, 2008-08-12 at 15:09 -0400, Matthias Felleisen wrote: > P.S. David, I appreciate your Navy experience. I was a paratrooper > myself. What distinguishes this situation so much from the one in > school and college is that your life depends on learning and > performing well. (We lost 10-20% of the "students" in paratrooping > school due to accidents, some really really bad. Nobody died.) I think the nature of the subject matter is relevant here. Matthias' point is valid when considering jumping out of "perfectly good" airplanes, but the sight of a manual presenting Ohm's Law with the preface "The material in this document conforms to Department of the Army doctrine" gives one pause -- suppose it didn't; would they repeal the laws of nature? My training as an electronics technician was fast and thorough in some sense, but it gave me first-hand experience of the difference between "education" and "training". From eli at barzilay.org Tue Aug 12 16:12:19 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:35 2009 Subject: [plt-scheme] PLT Scheme v4.1 Message-ID: <200808122012.m7CKCJGF020452@winooski.ccs.neu.edu> PLT Scheme version 4.1 is now available from http://plt-scheme.org/ * DrScheme changes: - The Module language now has an automatically inserted `#lang' declaration, so the interactions window is available right away for new windows. - Searching is now interactive (see the manual for details). - Memory limits are now enabled by default. * Typed Scheme supports a novel type checking mechanism for homogeneous and heterogeneous variable-arity function definitions and applications. * Redex (a domain-specific language for testing operational semantics) is now included in the distribution. See also http://redex.plt-scheme.org/. * Lots of improvement to the documentation, including: better searching, table-of-contents, and language-sensitive help (in the teaching languages). * The world.ss teachpack no longer supports `end-of-time', only `stop-when'. * MzScheme has now a logging facility, search the documentation for "logger" for more details. * Bug fixes: - `begin' in R5RS (and derived languages), - `#lang planet', - `eval' works with phases. Feedback Welcome, -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From marek at xivilization.net Tue Aug 12 18:15:22 2008 From: marek at xivilization.net (Marek Kubica) Date: Thu Mar 26 02:25:35 2009 Subject: [plt-scheme] PLT Scheme v4.1 In-Reply-To: <200808122012.m7CKCJGF020452@winooski.ccs.neu.edu> References: <200808122012.m7CKCJGF020452@winooski.ccs.neu.edu> Message-ID: <20080813001522.09302678@halmanfloyd.lan.local> On Tue, 12 Aug 2008 16:12:19 -0400 Eli Barzilay wrote: > PLT Scheme version 4.1 is now available from > > http://plt-scheme.org/ Great, it's nice to see the speed of the development, thank you to all involved! > Feedback Welcome, Se here is a bug report concerning the Fedora 7 x86_64 installer. I am running Debian Lenny on amd64 but the 4.0.2 installer used to work just fine. The output is attached: $ ./plt-4.1-bin-x86_64-linux-f7.sh This program will extract and install PLT Scheme v4.1. Note: the required diskspace for this installation is about 193M. Do you want a Unix-style distribution? In this distribution mode files go into different directories according to Unix conventions. A "plt-uninstall" script will be generated to make it possible to remove the installation. If say 'no', the whole PLT directory is kept as a single (movable and erasbale) unit, possibly with external links into it. Enter yes/no (default: no) > yes Where do you want to base your installation of PLT Scheme v4.1? (Use an existing directory. If you've done such an installation in the past, either use the same place, or manually run 'plt-uninstaller' now.) 1 - /usr/... [default] 2 - /usr/local/... 3 - $HOME/... (/home/marek/...) 4 - ./... (here) Or enter a different directory prefix to install in. > 4 Target Directories: [e] Executables /home/marek/plt/bin (will be created) [s] Scheme Code /home/marek/plt/lib/plt/collects (will be created) [d] Core Docs /home/marek/plt/share/plt/doc (will be created) [l] C Libraries /home/marek/plt/lib (will be created) [h] C headers /home/marek/plt/include/plt (will be created) [o] Extra C Objs /home/marek/plt/lib/plt (will be created) [m] Man Pages /home/marek/plt/man (will be created) Enter a new prefix, a letter to change an entry, enter to continue > Checking the integrity of the binary archive... ok. Unpacking into "/home/marek/plt/plt-tmp-install"... done. Moving bin -> /home/marek/plt/bin Moving collects -> /home/marek/plt/lib/plt/collects Moving doc -> /home/marek/plt/share/plt/doc Moving include -> /home/marek/plt/include/plt Moving lib -> /home/marek/plt/lib/plt Moving man -> /home/marek/plt/man Moving readme.txt -> /home/marek/plt/share/plt/doc/readme.txt Writing uninstaller at: /home/marek/plt/bin/plt-uninstall... Rewriting configuration file at: /home/marek/plt/lib/plt/collects/config/config.ss... *** Error: undoing changes... standard-module-name-resolver: collection not found: "scheme" in any of: (# #) Error: installation failed (Removing installation files in /home/marek/plt/plt-tmp-install) regards, Marek From lordgeoffrey at optushome.com.au Tue Aug 12 21:06:55 2008 From: lordgeoffrey at optushome.com.au (LordGeoffrey) Date: Thu Mar 26 02:25:36 2009 Subject: [plt-scheme] csv.plt - expand: unbound variable in module in: set-cdr! In-Reply-To: <48A1AE73.9080606@neilvandyke.org> References: <489E10DA.1030103@optushome.com.au> <48A1AE73.9080606@neilvandyke.org> Message-ID: <48A233AF.5040704@optushome.com.au> Neil - Much appreciated. Geoff. Neil Van Dyke wrote: > I uploaded a new version, with a patch thanks to Doug Orleans. > (require (planet "csv.ss" ("neil" "csv.plt" 1 2))) [snip] From simon at joyful.com Tue Aug 12 21:15:44 2008 From: simon at joyful.com (Simon Michael) Date: Thu Mar 26 02:25:36 2009 Subject: [plt-scheme] Re: PLT Scheme v4.1 In-Reply-To: <200808122012.m7CKCJGF020452@winooski.ccs.neu.edu> References: <200808122012.m7CKCJGF020452@winooski.ccs.neu.edu> Message-ID: Great! Thank you PLT. Installed and ran fine on mac intel OSX 10.5. From eli at barzilay.org Wed Aug 13 00:22:32 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:36 2009 Subject: [plt-scheme] PLT Scheme v4.1 In-Reply-To: <20080813001522.09302678@halmanfloyd.lan.local> References: <200808122012.m7CKCJGF020452@winooski.ccs.neu.edu> <20080813001522.09302678@halmanfloyd.lan.local> Message-ID: <18594.24968.944400.103134@arabic.ccs.neu.edu> On Aug 13, Marek Kubica wrote: > > [...] > Rewriting configuration file > at: /home/marek/plt/lib/plt/collects/config/config.ss... *** Error: > undoing changes... standard-module-name-resolver: collection not found: > "scheme" in any of: (# > #) Error: installation > failed (Removing installation files in /home/marek/plt/plt-tmp-install) I traced this problem to the part where the "unixstyle" installer wants to recompile a new config file -- it uses `make-base-namespace' to create a new namespace, but at this point the collection tree has already moved. The solution is simple -- create the namespace at the top level, before doing any directory moving. I committed that now (and if any 3rd-party packages run into this problem -- the relevant revision is 11213). But to make things work now without updating sources, I hacked the installers so they bypass the problem (they copy the `scheme' collection to a /tmp directory, then run mzscheme and make it look there for the `scheme' collection, so when the real one moved it continues to work off of the copy). It's not a good solution, of course, but it's fine to make things work for now. [Note that I updated the Northeaster files, so it might take a while to propagate.] -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From DekuDekuplex at Yahoo.com Wed Aug 13 01:17:19 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:25:36 2009 Subject: [plt-scheme] Re: PLT Scheme v4.1 References: <200808122012.m7CKCJGF020452@winooski.ccs.neu.edu> Message-ID: On Tue, 12 Aug 2008 16:12:19 -0400, Eli Barzilay wrote: >PLT Scheme version 4.1 is now available from > > http://plt-scheme.org/ It works fine in 32-bit Intel Windows XP Professional, Service Pack 2. While this change has probably been there from v4.0, in particular, I appreciate the inclusion of "R5RS" in the list of Legacy Languages. I have read various comments on comp.lang.scheme about certain users who do not appreciate some of the changes in R6RS, and it is nice to have R5RS available when needed. Thank you! -- Benjamin L. Russell From marek at xivilization.net Wed Aug 13 04:31:14 2008 From: marek at xivilization.net (Marek Kubica) Date: Thu Mar 26 02:25:36 2009 Subject: [plt-scheme] PLT Scheme v4.1 In-Reply-To: <18594.24968.944400.103134@arabic.ccs.neu.edu> References: <200808122012.m7CKCJGF020452@winooski.ccs.neu.edu> <20080813001522.09302678@halmanfloyd.lan.local> <18594.24968.944400.103134@arabic.ccs.neu.edu> Message-ID: <20080813103114.69c298dd@halmanfloyd.lan.local> Hi, On Wed, 13 Aug 2008 00:22:32 -0400 Eli Barzilay wrote: > But to make things work now without updating sources, I hacked the > installers so they bypass the problem (they copy the `scheme' > collection to a /tmp directory, then run mzscheme and make it look > there for the `scheme' collection, so when the real one moved it > continues to work off of the copy). It's not a good solution, of > course, but it's fine to make things work for now. Great, thanks for the fix; it is working fine for me now. regards, Marek From marek at xivilization.net Wed Aug 13 04:40:35 2008 From: marek at xivilization.net (Marek Kubica) Date: Thu Mar 26 02:25:36 2009 Subject: [plt-scheme] Usability: Collapse Menus Message-ID: <20080813104035.43717ed2@halmanfloyd.lan.local> Hi, I guess we all agree that DrScheme does not look really pretty (at least on Linux). Now, while this is not a big issue to rewrite the GUI at this point, which does not seem to be easily possible anyway we have to live with that. But, while I quite like how DrScheme works I am always a bit annoyed by the menus (File, Edit, View etc) which I can open by one single click but can't close again by a single click (like it works in about about any toolkit on Windows, GTK+ and Qt). Could you please change the behaviour so that these menus collapse when the user clicks on the menu entry name? It is really easier for users if they don't need to search where to click to get rid of the menus. Clicking outside of the menus is of course reasonable but I think for the usability consistency is key. regards, Marek From mflatt at cs.utah.edu Wed Aug 13 08:05:07 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:25:36 2009 Subject: [plt-scheme] Usability: Collapse Menus In-Reply-To: <20080813104035.43717ed2@halmanfloyd.lan.local> References: <20080813104035.43717ed2@halmanfloyd.lan.local> Message-ID: <20080813120509.1E9AB6500EA@mail-svr1.cs.utah.edu> At Wed, 13 Aug 2008 10:40:35 +0200, Marek Kubica wrote: > Could you please change the behaviour so that these menus collapse when > the user clicks on the menu entry name? Done in SVN. Matthew From marek at xivilization.net Wed Aug 13 08:39:50 2008 From: marek at xivilization.net (Marek Kubica) Date: Thu Mar 26 02:25:37 2009 Subject: [plt-scheme] Usability: Collapse Menus In-Reply-To: <20080813120509.1E9AB6500EA@mail-svr1.cs.utah.edu> References: <20080813104035.43717ed2@halmanfloyd.lan.local> <20080813120509.1E9AB6500EA@mail-svr1.cs.utah.edu> Message-ID: <20080813143950.720a353f@halmanfloyd.lan.local> On Wed, 13 Aug 2008 06:05:07 -0600 Matthew Flatt wrote: > At Wed, 13 Aug 2008 10:40:35 +0200, Marek Kubica wrote: > > Could you please change the behaviour so that these menus collapse > > when the user clicks on the menu entry name? > > Done in SVN. Thanks, PLT rocks :) regards, Marek From noelwelsh at gmail.com Wed Aug 13 08:50:05 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:37 2009 Subject: [plt-scheme] csv.plt - expand: unbound variable in module in: set-cdr! In-Reply-To: <48A1AE73.9080606@neilvandyke.org> References: <489E10DA.1030103@optushome.com.au> <48A1AE73.9080606@neilvandyke.org> Message-ID: On Tue, Aug 12, 2008 at 4:38 PM, Neil Van Dyke wrote: > Peer pressure cannot get me to port HtmlPrag to PLT 4 until next week, > however. Noted in my calendar :-D N. From wookiz at hotmail.com Wed Aug 13 09:57:03 2008 From: wookiz at hotmail.com (wooks) Date: Thu Mar 26 02:25:37 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <756daca50808110514l27342b9sbee07d19301f23fe@mail.gmail.com> References: <4f5cd174-0e03-428c-8cbb-3135b25e7ed8@c58g2000hsc.googlegroups.com> <756daca50808110514l27342b9sbee07d19301f23fe@mail.gmail.com> Message-ID: On Aug 11, 8:14?am, "Grant Rettke" wrote: > On Mon, Aug 11, 2008 at 5:33 AM, wooks wrote: > > On Aug 10, 1:52 pm, "Shriram Krishnamurthi" wrote: > >> Is there a point here beyond that this author seems to be hopelessly > >> outdated in his understanding of CS? > > > Assuming this is true, what does it say about the organisation that > > gave him the platform to publish his view. > > It says that well-spoken people won't publish under that organization. > The organisation is not some ragtag setup but the British Computer Society. It would be great to see them publish a rejoinder from someone in PLT. From matthias at ccs.neu.edu Wed Aug 13 10:17:21 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:37 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <4f5cd174-0e03-428c-8cbb-3135b25e7ed8@c58g2000hsc.googlegroups.com> <756daca50808110514l27342b9sbee07d19301f23fe@mail.gmail.com> Message-ID: On Aug 13, 2008, at 9:57 AM, wooks wrote: > On Aug 11, 8:14 am, "Grant Rettke" wrote: >> On Mon, Aug 11, 2008 at 5:33 AM, wooks wrote: >>> On Aug 10, 1:52 pm, "Shriram Krishnamurthi" >>> wrote: >>>> Is there a point here beyond that this author seems to be >>>> hopelessly >>>> outdated in his understanding of CS? >> >>> Assuming this is true, what does it say about the organisation that >>> gave him the platform to publish his view. >> >> It says that well-spoken people won't publish under that >> organization. >> > > The organisation is not some ragtag setup but the British Computer > Society. They just qualified themselves as such :-) And don't think ACM is any better. > It would be great to see them publish a rejoinder from someone in > PLT. Start by writing a reader's rebuttal that points to PLT. -- Matthias From wookiz at hotmail.com Wed Aug 13 10:42:39 2008 From: wookiz at hotmail.com (wooks) Date: Thu Mar 26 02:25:37 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <4f5cd174-0e03-428c-8cbb-3135b25e7ed8@c58g2000hsc.googlegroups.com> <756daca50808110514l27342b9sbee07d19301f23fe@mail.gmail.com> Message-ID: > > They just qualified themselves as such :-) And don't think ACM is any > better. > > > It would be great to see them publish a rejoinder from someone in > > PLT. > > Start by writing a reader's rebuttal that points to PLT. > So if I said I wasn't qualified to do so (as I had meant to) you lot would have said don't worry we'll help you. Ok point me to some papers/ materials. From wookiz at hotmail.com Wed Aug 13 10:40:15 2008 From: wookiz at hotmail.com (wooks) Date: Thu Mar 26 02:25:37 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> Message-ID: On Aug 11, 11:11 am, Matthias Felleisen wrote: > My hunch is that to > this day, 90% of these places claim to teach OO early and first. > (Reality: At least they use an OO language to teach Fortran.) > It is not dissimilar to the approach of some elite research universities. Teach imperative programming in Java/C++ as an introduction and move on to OO features in a subsequent course or latter part of the same course. From noelwelsh at gmail.com Wed Aug 13 11:58:22 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:37 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <4f5cd174-0e03-428c-8cbb-3135b25e7ed8@c58g2000hsc.googlegroups.com> <756daca50808110514l27342b9sbee07d19301f23fe@mail.gmail.com> Message-ID: On Wed, Aug 13, 2008 at 3:42 PM, wooks wrote: > So if I said I wasn't qualified to do so (as I had meant to) you lot > would have said don't worry we'll help you. Ok point me to some papers/ > materials. As I recall, the author's argument was: 1. Teaching Java with our curriculum and IDE is hard [Correct] 2. Therefore teaching OO is hard [Incorrect conclusion] 3. Therefore teach structured programming (in VB, but I think that is irrelevant) There are many problems with the author's argument. My main issues are: - They fit the curriculum to the technology, not vice versa. So they reject object-first because whatever IDE they are using doesn't support it well - They overgeneralize from a bad experience with a particular curriculum, language, and IDE, to all OO languages - They fail to consider other alternatives (e.g. functional programming) to OO languages Of the BlueJ papers (http://www.bluej.org/about/papers.html): "The Problem of Teaching Object-Oriented Programming", Part 1: Languages and Part 2: Environments argue you need to choose your language and environment well. "Guidelines for Teaching Object Orientation with Java" largely suggests the points the author makes are a result of poor choice of curriculum and IDE. "The BlueJ system and its pedagogy" shows you can do much better with a better environment. http://www.teach-scheme.org/Talks/ suggests you can do very well with an alternate curriculum. >From http://www.ccs.neu.edu/scheme/pubs/ I would look at: The Structure and Interpretation of the Computer Science Curriculum The TeachScheme! Project: Computing and Programming for Every Student DrScheme: A Programming Environment for Scheme N. From deinst at gmail.com Wed Aug 13 12:38:36 2008 From: deinst at gmail.com (David Einstein) Date: Thu Mar 26 02:25:38 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <1218569122.11408.6.camel@localhost> References: <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> <1218569122.11408.6.camel@localhost> Message-ID: <56750b780808130938w405a00aevc1072a5e304907e@mail.gmail.com> On Tue, Aug 12, 2008 at 3:25 PM, Bill wrote: > On Tue, 2008-08-12 at 15:09 -0400, Matthias Felleisen wrote: > > P.S. David, I appreciate your Navy experience. I was a paratrooper > > myself. What distinguishes this situation so much from the one in > > school and college is that your life depends on learning and > > performing well. (We lost 10-20% of the "students" in paratrooping > > school due to accidents, some really really bad. Nobody died.) > > I think the nature of the subject matter is relevant here. Matthias' > point is valid when considering jumping out of "perfectly good" > airplanes, but the sight of a manual presenting Ohm's Law with the > preface "The material in this document conforms to Department of the > Army doctrine" gives one pause -- suppose it didn't; would they repeal > the laws of nature? My training as an electronics technician was fast > and thorough in some sense, but it gave me first-hand experience of the > difference between "education" and "training". > > Of course, all the military wants is someone that can efficiently and reliably maintain and repair their ever growing pile of complicated toys. The important part of the basic electronics was not learning things like Ohm's law, or how waveguides worked[1], the important part was learning the process of 1) Recognizing and understanding the problem, 2) Collecting more detailed data to isolate the problem to the appropriate part. 3) Finally, whacking the appropriate part with a 12" crescent wrench. These steps pretty much reflect a HTDPish appraoch to writing programs which I will paraphrase as 1) Understanding and describing the problem, writing test cases, making an initial template of functions and classes. 2) Breaking the problem into more detailed classes and functions. 3) Writing the code to fill in the functions and classes. The problem that I see with K-12 computer education is that they concentrate on step 3 in silly overcomplicated languages like java, maybe occasionally touching on step 2, and totally ignoring step 1 (and then they wonder why their students are confused). Step 1 would be simple if students had an adequate mathematics education (see http://www.de.ufpe.br/~toom/articles/engeduc/index.htm [2]), but unfortunately they don't. I believe that if they want to change K-12 computer science education, they are more likely to succeed if they circumvent the educational establishment than if they try to confront it. The point that I was trying to make is that the military manages to teach precisely the problem solving skills that HTDP endeavors to with minimal human intervention. Whatever instructors we had were esentially equivalent to us, just four years or so older and hapless enough to reenlist. I do not think that programming per se is or needs to be a particularly difficult endeavor. With a scant few exceptions, we are not engineers or scientists, we are file clerks, heirs to the world of Bob Cratchit and Bartelby. There is nothing wrong with that. The job needs doing, and it deserves to be done well. Judging from the scope and nature of the software disasters we are lacking even in competent file clerks. [1] On the subject of waveguides we were all but lied to, but the knowlege we recieved was sufficient for us to muddle through. [2] These are by Andrei Toom of Toom-Cook fame. Yes, it sometimes appears that he has an axe to grind, but his points on the complete lack of problem solving in american K-12 education appear valid from where I sit. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080813/ca17548d/attachment.html From morazanm at gmail.com Wed Aug 13 13:03:01 2008 From: morazanm at gmail.com (Marco Morazan) Date: Thu Mar 26 02:25:38 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <56750b780808130938w405a00aevc1072a5e304907e@mail.gmail.com> References: <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> <1218569122.11408.6.camel@localhost> <56750b780808130938w405a00aevc1072a5e304907e@mail.gmail.com> Message-ID: <9b1fff280808131003t5e45aeb5lcd3924bc93f787@mail.gmail.com> On Wed, Aug 13, 2008 at 12:38 PM, David Einstein wrote: > I do not think that programming per se is or needs to be a particularly > difficult endeavor. With a scant few exceptions, we are not engineers or > scientists, But programming IS a difficult endeavor. It requires careful study and a disciplined approach to development. Furthermore, livelihoods and, sometimes, lives depend on the correct functioning of software. I would say that we are most certainly engineers AND scientists. Just like engineers and scientists, we must be reasonably sure that the fruits of our labor are sound, efficient, and get the job done. After all, no one wants a bridge that collapses, is made of gold, needs maintenance every week, or does not reach the other side of the river it is suppossed to cross. Likewise, no one wants software that crashes, that unnecessarily consumes too much memory or time, that needs to constantly be updated, or does not fully solve the problem it is intended to solve. Does not a textbook, like HtDP, clearly bring home the point that there is a disciplined and methodical approach to programming? To me that says science and engineering. Marco From geoff at knauth.org Wed Aug 13 13:12:40 2008 From: geoff at knauth.org (Geoff Knauth) Date: Thu Mar 26 02:25:39 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> Message-ID: <8E3B3680-2EE6-4983-8473-FDEAA77956B3@knauth.org> On Aug 11, 2008, at 09:11, Matthias Felleisen wrote: > 1. Don't confuse elite research universities with institutions that > use "University" in their name only because someone decided everyone > should get a degree from a college/university. My hunch is that to > this day, 90% of these places claim to teach OO early and first. > (Reality: At least they use an OO language to teach Fortran.) Yesterday at SIGGRAPH I was talking with educators from California. They bemoaned the fact the ubiquity of Java as a required language. We thought OO wasn't really the reason Java became so widespread. Rather, it was because it isn't as messy as C++, it's portable, and it has rich toolkits. I haven't run into any Schemers out here yet :-( , but I'll wear my TeachScheme! 2000 T-shirt at the big reception tomorrow night in Dodger Stadium. I have found some Smalltalk folks who love Seaside who think it blows away Ruby on Rails. I know RoR, I need to look at Seaside, and I'm curious what a DrScheme-based webkit along those lines would look like. There's a tension between "build it quickly" (RoR) and "build it well" (HtDP). More people need to understand that HtDP is a much bigger win in the long run. I wonder how we can illustrate the tradeoffs or the inflection point in a way anyone would understand (e.g., Ed Tufte's insights into visualization). I went to the scientific visualization BOF yesterday, and some of the massively parellel computations and filters they need just screamed Scheme to me. Has anyone ever run Scheme on a GPU? > 2. Last week, I had a private exchange with a person close to core > PLT. The email basically said that during a consulting presentation > with a major industrial software producer, one of the attendees got > up and said "it is way to expensive to use object in (this) area of > business. We use records and functions." I wouldn't be surprised if > this is true and becomes more true so as companies that create > networked software discover the cost of moving back and forth > (serialize and unserialize). Maybe Google should chime in and explain how MapReduce helps them minimize data traffic. Geoff From geoff at knauth.org Wed Aug 13 13:23:50 2008 From: geoff at knauth.org (Geoff Knauth) Date: Thu Mar 26 02:25:39 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> Message-ID: <5B1C87E3-B93E-495C-96AB-31B50333A53E@knauth.org> On Aug 12, 2008, at 06:15, Matthias Felleisen wrote: > Functional programming is mathematics and, if we stay as close as > possible to algebra (conceptually), fun animations can teach > algebra, geometry, pre-calc, mechanics, and possibly more. THAT is > the powerful combination advertised in our column. Reminds me of this cartoon: http://www.xkcd.com/435/ From deinst at gmail.com Wed Aug 13 13:27:11 2008 From: deinst at gmail.com (David Einstein) Date: Thu Mar 26 02:25:40 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <9b1fff280808131003t5e45aeb5lcd3924bc93f787@mail.gmail.com> References: <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> <1218569122.11408.6.camel@localhost> <56750b780808130938w405a00aevc1072a5e304907e@mail.gmail.com> <9b1fff280808131003t5e45aeb5lcd3924bc93f787@mail.gmail.com> Message-ID: <56750b780808131027r4e6988d9n125f21c4eda29081@mail.gmail.com> On Wed, Aug 13, 2008 at 1:03 PM, Marco Morazan wrote: > On Wed, Aug 13, 2008 at 12:38 PM, David Einstein wrote: > > I do not think that programming per se is or needs to be a particularly > > difficult endeavor. With a scant few exceptions, we are not engineers or > > scientists, > > But programming IS a difficult endeavor. It requires careful study and > a disciplined approach to development. Furthermore, livelihoods and, > sometimes, lives depend on the correct functioning of software. The same is true of the guy that does my brakes. One of the things that I see is that the probability that a programming effort fails is inversely proportional to its complexity. Piecing together genomes from millions of DNA fragments succeeds, while an accounting system for LA schools fails miserably. Yes there are exciting and interesting things in CS that are complicated and interesting that rise to the level of engineering or science, but most of what we do only takes an understanding of the problem, and an understanding of the tools at hand. > I > would say that we are most certainly engineers AND scientists. Just > like engineers and scientists, we must be reasonably sure that the > fruits of our labor are sound, efficient, and get the job done. After > all, no one wants a bridge that collapses, is made of gold, needs > maintenance every week, or does not reach the other side of the river > it is suppossed to cross. Likewise, no one wants software that > crashes, that unnecessarily consumes too much memory or time, that > needs to constantly be updated, or does not fully solve the problem it > is intended to solve. > > > > Does not a textbook, like HtDP, clearly bring home the point that > there is a disciplined and methodical approach to programming? To me > that says science and engineering. > > Marco > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080813/648e0a8f/attachment.htm From michael at schuerig.de Wed Aug 13 14:14:50 2008 From: michael at schuerig.de (Michael Schuerig) Date: Thu Mar 26 02:25:40 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <56750b780808131027r4e6988d9n125f21c4eda29081@mail.gmail.com> References: <9b1fff280808131003t5e45aeb5lcd3924bc93f787@mail.gmail.com> <56750b780808131027r4e6988d9n125f21c4eda29081@mail.gmail.com> Message-ID: <200808132014.50398.michael@schuerig.de> On Wednesday 13 August 2008, David Einstein wrote: > One of the things that I see is that the probability that a > programming effort fails is inversely proportional to its > complexity.? Piecing together genomes from millions of DNA fragments > succeeds, while an accounting system for LA schools fails miserably.? You're only taking into account complexity in a very narrowly technical sense. That's rarerly what makes or breaks a project. Look at "political" complexity, too, such as number and abilities of project participants, funding, intrigues. Then there a projects that are just too big to fail, or perceived that way at any rate. Consider: NASA has put men on the moon some 40 years ago, why is it taking them so incredibly long to repeat that feat? Wouldn't you rather expect to be able to book a weekend holiday at the edge of crater Tycho by this time? Michael -- Michael Schuerig mailto:michael@schuerig.de http://www.schuerig.de/michael/ From matthias at ccs.neu.edu Wed Aug 13 14:27:11 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:40 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <8E3B3680-2EE6-4983-8473-FDEAA77956B3@knauth.org> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <8E3B3680-2EE6-4983-8473-FDEAA77956B3@knauth.org> Message-ID: <84792BE3-3145-4D11-BBA3-E6BDCE23813C@ccs.neu.edu> On Aug 13, 2008, at 1:12 PM, Geoff Knauth wrote: > I haven't run into any Schemers out here yet :-( , but I'll wear my > TeachScheme! 2000 T-shirt at the big reception tomorrow night in > Dodger Stadium. I have found some Smalltalk folks who love Seaside > who think it blows away Ruby on Rails. I know RoR, I need to look > at Seaside, and I'm curious what a DrScheme-based webkit along > those lines would look like. We were there first. At least as far as continuation-based web servers and systematic design of web (server side) scripts is concerned. Shriram and I wrote various paper with various co-authors on this topic from 98 thru 2003. SK resumed later and continued the trend. (Okay silly puns; find out what they mean.) See http://www.ccs.neu.edu/scheme/pubs/ for details. We blew it when it came to turning all this into a plain old, quick prototyping framework. (Well I had the vision but I didn't go to the doctor ...) > There's a tension between "build it quickly" (RoR) and "build it > well" (HtDP). Yes and no. On the surface there is a tension. But if you follow HtDP to its extreme (not in print) you will naturally build abstractions (aka frameworks and libraries and friends) that make it possible to build even faster than the "quick guys" and at least as well. -- Matthias From vkp at ccs.neu.edu Wed Aug 13 14:47:11 2008 From: vkp at ccs.neu.edu (Viera Proulx) Date: Thu Mar 26 02:25:40 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <56750b780808131027r4e6988d9n125f21c4eda29081@mail.gmail.com> References: <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> <1218569122.11408.6.camel@localhost> <56750b780808130938w405a00aevc1072a5e304907e@mail.gmail.com> <9b1fff280808131003t5e45aeb5lcd3924bc93f787@mail.gmail.com> <56750b780808131027r4e6988d9n125f21c4eda29081@mail.gmail.com> Message-ID: <2E4A1F96-CD34-47F6-8F61-2814FCCFBB16@ccs.neu.edu> > On Wed, Aug 13, 2008 at 1:03 PM, Marco Morazan > wrote: > On Wed, Aug 13, 2008 at 12:38 PM, David Einstein > wrote: > > I do not think that programming per se is or needs to be a > particularly > > difficult endeavor. With a scant few exceptions, we are not > engineers or > > scientists, > > But programming IS a difficult endeavor. It requires careful study and > a disciplined approach to development. Furthermore, livelihoods and, > sometimes, lives depend on the correct functioning of software. > > The same is true of the guy that does my brakes. > Now that my students dutifully test every method in Java - because I gave them a tool that does not increase the difficulty of program design beyond what they already are doing --- I looked to see what the others do. Out of 20 popular Java textbooks not one asks for anything that resembles tests the way we know them. Maybe some println statements. They all include a two page sections where they explain that testing is important and people do it in real life. Our students learn from designing examples and tests. (And it also makes them write smaller methods, delegate more - because it is very hard to test a monster method that does twenty different things.) It may not be science, but it is a disciplined practice. -- Viera -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080813/1b5c307a/attachment.html From vkp at ccs.neu.edu Wed Aug 13 15:07:33 2008 From: vkp at ccs.neu.edu (Viera Proulx) Date: Thu Mar 26 02:25:41 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <200808132014.50398.michael@schuerig.de> References: <9b1fff280808131003t5e45aeb5lcd3924bc93f787@mail.gmail.com> <56750b780808131027r4e6988d9n125f21c4eda29081@mail.gmail.com> <200808132014.50398.michael@schuerig.de> Message-ID: <0F185D73-21D2-4524-A623-B4748C602F89@ccs.neu.edu> On Aug 13, 2008, at 2:14 PM, Michael Schuerig wrote: > Then there a projects that are just too big to fail, or perceived that > way at any rate. Consider: NASA has put men on the moon some 40 years > ago, why is it taking them so incredibly long to repeat that feat? > Wouldn't you rather expect to be able to book a weekend holiday at the > edge of crater Tycho by this time? The people who put men on the moon were hackers in the best sense of the term. Today these people are bogged down by bureaucracy. I heard a Navy guy at a conference last year reminiscing about some fix for some project that they accomplished in one day - to the amazement of the Air Force where that would have taken six months - before the next bug fix could be approved and committed. Of course, these hackers knew that people's lives depended on them doing their work right (just like the paratroopers know that they better learn what to do if they want to live). -- Viera From grettke at acm.org Wed Aug 13 16:54:59 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:25:41 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <56750b780808131027r4e6988d9n125f21c4eda29081@mail.gmail.com> References: <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> <1218569122.11408.6.camel@localhost> <56750b780808130938w405a00aevc1072a5e304907e@mail.gmail.com> <9b1fff280808131003t5e45aeb5lcd3924bc93f787@mail.gmail.com> <56750b780808131027r4e6988d9n125f21c4eda29081@mail.gmail.com> Message-ID: <756daca50808131354u5f71bf03y5d334ade46bdacb7@mail.gmail.com> On Wed, Aug 13, 2008 at 12:27 PM, David Einstein wrote: > One of the things that I see is that the probability that a programming > effort fails is inversely proportional to its complexity. One of the things that *I* see is that the probability that a programming effort fails is inversely proportional to its budget! From morazanm at gmail.com Wed Aug 13 17:38:53 2008 From: morazanm at gmail.com (Marco Morazan) Date: Thu Mar 26 02:25:41 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <2E4A1F96-CD34-47F6-8F61-2814FCCFBB16@ccs.neu.edu> References: <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> <1218569122.11408.6.camel@localhost> <56750b780808130938w405a00aevc1072a5e304907e@mail.gmail.com> <9b1fff280808131003t5e45aeb5lcd3924bc93f787@mail.gmail.com> <56750b780808131027r4e6988d9n125f21c4eda29081@mail.gmail.com> <2E4A1F96-CD34-47F6-8F61-2814FCCFBB16@ccs.neu.edu> Message-ID: <9b1fff280808131438s654ab9fdg25b322efe71c39d2@mail.gmail.com> On Wed, Aug 13, 2008 at 2:47 PM, Viera Proulx wrote: > > Now that my students dutifully test every method in Java - because I gave > them a tool that does not increase the difficulty of program design beyond > what they already are doing --- I looked to see what the others do. Out of > 20 popular Java textbooks not one asks for anything that resembles tests the > way we know them. Maybe some println statements. They all include a two page > sections where they explain that testing is important and people do it in > real life. Yes, we can certainly put in the trash all those Java books that unnecessarily saturate the shelfs in bookstores. There is no doubt in my mind that the development of tests and the practice of testing give programmers insight into the problem they are solving and into the design of their programs. > It may not be science, but it is a disciplined practice. I would argue it is on the verge of being a formal method and it is certainly science. Specify a problem, design an experiment (the program), run experiments (the testing), and draw conclusions (arguments for program correctness). Is this not science? Collectively, we are just a few steps away from program verification in the UG curriculum. Quite exciting! :-) Cheers, Marco From matthias at ccs.neu.edu Wed Aug 13 17:56:16 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:41 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <9b1fff280808131438s654ab9fdg25b322efe71c39d2@mail.gmail.com> References: <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> <1218569122.11408.6.camel@localhost> <56750b780808130938w405a00aevc1072a5e304907e@mail.gmail.com> <9b1fff280808131003t5e45aeb5lcd3924bc93f787@mail.gmail.com> <56750b780808131027r4e6988d9n125f21c4eda29081@mail.gmail.com> <2E4A1F96-CD34-47F6-8F61-2814FCCFBB16@ccs.neu.edu> <9b1fff280808131438s654ab9fdg25b322efe71c39d2@mail.gmail.com> Message-ID: On Aug 13, 2008, at 5:38 PM, Marco Morazan wrote: > I would argue it is on the verge of being a formal method and it is > certainly science. We need to distinguish what a programmer does vs what we, the developers of the discipline, do. 1. Good programming (especially agile) uses the scientific method: [a] develop a model (called prototype) [b] measure it wrt to the client and user (who could be different) [c] start over at [a] based on input from [b] [d] the process stops when the client believes the model is good enough to conquer a good share of the market w/o making users hate it and wish for someone to replace it In addition, programs are extremely abstract artifacts. Because of very few people are good at working with abstract constructions and because very few people have good (self) discipline, I consider even ordinary programming way beyond the expertise of car mechanics or even average engineers with a BS degree. Sadly that doesn't prevent them from doing it anyway, because bad programming can be done by everyone and can reach [d] too. The equally sad part is that average programmers lack expertise in "domains." Because programming is abstract, it applies everywhere. But good applications demand good understanding of the domain. So the fault for bad programming and software construction is both with overconfident non-trained engineers and others who pretend they can program and with programmers who pretend they understand all and every application domain. 2. We, the creators of the discipline, mix tools from many different disciplines, even if you restrict your view to PL: -- mathematics and logic -- engineering -- psychology -- sociology -- art -- Matthias From hendrik at topoi.pooq.com Wed Aug 13 22:44:11 2008 From: hendrik at topoi.pooq.com (hendrik@topoi.pooq.com) Date: Thu Mar 26 02:25:41 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <56750b780808130938w405a00aevc1072a5e304907e@mail.gmail.com> References: <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <56750b780808111737l560f05dbpf586095110b3a2ed@mail.gmail.com> <56750b780808120655x26864eb1m9a55b2e0d1934fca@mail.gmail.com> <56750b780808120817h492f62f2m647ad8e62980c614@mail.gmail.com> <1218569122.11408.6.camel@localhost> <56750b780808130938w405a00aevc1072a5e304907e@mail.gmail.com> Message-ID: <20080814024411.GA4652@topoi.pooq.com> On Wed, Aug 13, 2008 at 12:38:36PM -0400, David Einstein wrote: > [2] These are by Andrei Toom of Toom-Cook fame. Yes, it sometimes appears > that he has an axe to grind, but his points on the complete lack of problem > solving in american K-12 education appear valid from where I sit. That's why I like the first few years of math education here in Quebec. The first few years are devoted almost entirely to problem-solving. And here's a nice point -- when they do well in other areas, and end up with time left over, the teacher will *permit* them to spend extra time on problem-solving. -- hendrik From geoff at knauth.org Thu Aug 14 03:40:36 2008 From: geoff at knauth.org (Geoff Knauth) Date: Thu Mar 26 02:25:41 2009 Subject: [plt-scheme] Re: More pedagogic stuff In-Reply-To: <84792BE3-3145-4D11-BBA3-E6BDCE23813C@ccs.neu.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <8E3B3680-2EE6-4983-8473-FDEAA77956B3@knauth.org> <84792BE3-3145-4D11-BBA3-E6BDCE23813C@ccs.neu.edu> Message-ID: <0B53055F-D965-4E14-ACE1-9BE2DC04502A@knauth.org> On Aug 13, 2008, at 11:27, Matthias Felleisen wrote: > But if you follow HtDP to its extreme (not in print) you will > naturally build abstractions (aka frameworks and libraries and > friends) that make it possible to build even faster than the "quick > guys" and at least as well. Just thinking out loud, since I'm at SIGGRAPH, and graphics and movies are all around. I'm trying to figure out a way to make a DrScheme viral video. To demo HtDP in the extreme, I wonder if we could make a short movie of an application growing and following the design recipe? The screen would show source code as it grows from something really small to something that accomplishes a goal. The narrator would represent the programmer's thoughts. It would be like watching over the shoulder of someone who knew what he was doing. I've seen a video demo on this list: fluxus [1]. I remember music and flashing colors. It reminded me of a little of Processing [2] (they have an MIT Press book out now), and a little of Gooze [3]. I would suggest making it less flashy, though, to keep focus on the code, and state the goal up front. I like what Benjamin Russell wrote about getting in a "flow state." We can help people visualize themselves being that good. Geoff [1] http://www.pawfal.org/fluxus/ [2] http://www.processing.org/ [3] http://people.csail.mit.edu/jrb/Projects/gooze.htm From dave at pawfal.org Thu Aug 14 05:09:22 2008 From: dave at pawfal.org (Dave Griffiths) Date: Thu Mar 26 02:25:41 2009 Subject: Livecoding HtDP (was Re: [plt-scheme] Re: More pedagogic stuff) Message-ID: <47987.217.18.21.2.1218704962.squirrel@webmail.pawfal.org> > On Aug 13, 2008, at 11:27, Matthias Felleisen wrote: >> But if you follow HtDP to its extreme (not in print) you will >> naturally build abstractions (aka frameworks and libraries and >> friends) that make it possible to build even faster than the "quick >> guys" and at least as well. > > Just thinking out loud, since I'm at SIGGRAPH, and graphics and movies > are all around. I'm trying to figure out a way to make a DrScheme > viral video. > > To demo HtDP in the extreme, I wonder if we could make a short movie > of an application growing and following the design recipe? The screen > would show source code as it grows from something really small to > something that accomplishes a goal. The narrator would represent the > programmer's thoughts. It would be like watching over the shoulder of > someone who knew what he was doing. This is the essence of livecoding - the narrator is an interesting addition though, I don't think any livecoding performances have featured one yet (normally comments are a way to explain what you are doing to the audience). > I've seen a video demo on this list: fluxus [1]. I remember music > and flashing colors. There is a video of a visuals performance I did quite recently with fluxus here: http://blip.tv/file/921513 It was livecoding from scratch (i.e. starting with nothing), but the video shows extracts of the gig. There is also a really nice video here of budapest's 'no copy paste' livecoding mzscheme/fluxus and pure data: http://www.vimeo.com/694298 A more goal orientated example of livecoding HtDP would be interesting to see. As you are saying, the impression I hear sometimes after gigs is that you can tell a lot more about the thought process involved with programming by following someone doing it live, this is often from people who previously had little experience of programming, and found it difficult to understand. Livecoding can be interesting to them, as it underlines the human element in the process. cheers, dave From s.degabrielle at cs.ucl.ac.uk Thu Aug 14 08:24:08 2008 From: s.degabrielle at cs.ucl.ac.uk (Stephen De Gabrielle) Date: Thu Mar 26 02:25:42 2009 Subject: [plt-scheme] make install looping Message-ID: <595b9ab20808140524o521f923dwf41a481e0fdcbbd7@mail.gmail.com> Hi, I'm building from source, and make goes into a endless loop about the install xform support bit. Does anyone have any idea how I should approach resolving this? Cheers, Stephen -- Stephen De Gabrielle s.degabrielle@cs.ucl.ac.uk Telephone +44 (0)20 7679 0693 (x30693) Mobile 079 851 890 45 Project: Making Sense of Information (MaSI) Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html Home:http://www.degabrielle.name/stephen UCL Interaction Centre MPEB 8th floor University College London Gower Street London WC1E 6BT From spdegabrielle at gmail.com Thu Aug 14 08:25:09 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:25:42 2009 Subject: [plt-scheme] make looping Message-ID: <595b9ab20808140525h54d60d8l6bb02b69cd8c5cdd@mail.gmail.com> Hi, I'm building from source, and make goes into a endless loop about the install xform support bit. Does anyone have any idea how I should approach resolving this? Cheers, Stephen From spdegabrielle at gmail.com Thu Aug 14 08:55:36 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:25:42 2009 Subject: [plt-scheme] Re: make looping In-Reply-To: <595b9ab20808140525h54d60d8l6bb02b69cd8c5cdd@mail.gmail.com> References: <595b9ab20808140525h54d60d8l6bb02b69cd8c5cdd@mail.gmail.com> Message-ID: <595b9ab20808140555w3ce47decl1079ac7e434c141a@mail.gmail.com> Sorry, I need to be clear- its happing in make; svn update; cd src; ./configure --prefix=/home/user/MMC-SD/sd4gb/local/plt --enable-shared; sudo rm -r /home/user/MMC-SD/sd4gb/local/plt ;make clean ; make I clear the destination dir and run make clean first; but I still get the following in an endless loop; -- Compiling xform support... Done making xform-collects. /home/user/MMC-SD/sd4gb/plt/src/lt/libtool --mode=compile --tag=CC gcc -g -O2 -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB -I./.. -I./../include -Wall -c xsrc/env.c -o env.lo gcc -g -O2 -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB -I./.. -I./../include -Wall -c xsrc/env.c -fPIC -DPIC -o .libs/env.o env XFORM_USE_PRECOMP=xsrc/precomp.h ../mzschemecgc -cqu ./xform.ss --setup . --cpp "gcc -E -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB -I./.. -I./../include" -o xsrc/error.c ./../src/error.c Removing old xform-collects tree... Copying tree... Copying /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/./xform-mod.ss to xform-collects/xform/xform-mod.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/mzscheme.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/mzscheme.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/more-scheme.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/more-scheme.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stx.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stx.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/small-scheme.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/small-scheme.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/qq-and-or.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/qq-and-or.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/cond.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/cond.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define-et-al.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/define-et-al.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxcase-scheme.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stxcase-scheme.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxcase.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stxcase.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/sc.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/sc.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/ellipses.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/ellipses.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/with-stx.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/with-stx.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxloc.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stxloc.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/qqstx.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/qqstx.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/define.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/letstx-scheme.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/letstx-scheme.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/norm-define.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/norm-define.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/misc.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/misc.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxmz-body.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stxmz-body.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-ds.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old-ds.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define-struct.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/define-struct.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/struct-info.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/struct-info.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../stxparam.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/stxparam.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../stxparam-exptime.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/stxparam-exptime.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../private/stxparamkey.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stxparamkey.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-rp.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old-rp.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-if.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old-if.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-procs.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old-procs.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/promise.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/promise.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/tcp.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/tcp.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/udp.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/udp.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzscheme/main.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzscheme/main.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/xform.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/compiler/private/xform.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/list.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/list.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/base.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/base.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/pre-base.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/pre-base.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/kw.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/kw.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/name.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/name.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/sort.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/sort.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/reqprov.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/reqprov.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../require-transform.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/require-transform.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../provide-transform.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/provide-transform.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/modbeg.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/modbeg.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/for.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/for.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/list.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/list.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/string.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/string.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/kw-file.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/kw-file.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/namespace.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/namespace.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/list.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/list.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/etc.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/etc.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/kerncase.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/kerncase.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/stx.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/stx.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/name.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/name.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/main-collects.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/main-collects.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/dirs.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/dirs.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/config/main.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/config/main.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/config/config.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/config/config.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/configtab.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/configtab.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/winutf16.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/compiler/private/winutf16.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/mach-o.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/compiler/private/mach-o.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/path-relativize.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/path-relativize.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/stxset.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/stxset.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/context.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/context.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/local.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/local.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/bool.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/bool.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/kw.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/kw.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/process.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/process.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/port.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/port.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/contract.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/contract.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arrow.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/contract-arrow.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-opt-guts.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-opt-guts.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-guts.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-guts.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-helpers.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-helpers.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/pretty.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/pretty.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/pretty.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/pretty.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/port.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/port.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/private/boundmap.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/private/boundmap.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arr-obj-helpers.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/contract-arr-obj-helpers.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arr-checks.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/contract-arr-checks.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-opt.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-opt.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-object.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/contract-object.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/class-internal.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/class-internal.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/define.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/define.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/stxparam.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/stxparam.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/classidmap.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/classidmap.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/class-events.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/class-events.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/serialize-structs.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/serialize-structs.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/struct-info.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/struct-info.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-arrow.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-arrow.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-ds.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-ds.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-ds-helpers.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-ds-helpers.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-basic-opters.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-basic-opters.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/cmdline.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/cmdline.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/cmdline.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/cmdline.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/cm-ctime.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/cm-ctime.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzscheme/lang/reader.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzscheme/lang/reader.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/module-reader.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/module-reader.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/base/lang/reader.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/base/lang/reader.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/lang/reader.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/lang/reader.ss Compiling xform support... Done making xform-collects. /home/user/MMC-SD/sd4gb/plt/src/lt/libtool --mode=compile --tag=CC gcc -g -O2 -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB -I./.. -I./../include -Wall -c xsrc/error.c -o error.lo gcc -g -O2 -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB -I./.. -I./../include -Wall -c xsrc/error.c -fPIC -DPIC -o .libs/error.o env XFORM_USE_PRECOMP=xsrc/precomp.h ../mzschemecgc -cqu ./xform.ss --setup . --cpp "gcc -E -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB -I./.. -I./../include" -o xsrc/eval.c ./../src/eval.c Removing old xform-collects tree... Copying tree... ^ACopying /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/./xform-mod.ss to xform-collects/xform/xform-mod.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/mzscheme.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/mzscheme.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/more-scheme.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/more-scheme.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stx.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stx.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/small-scheme.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/small-scheme.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/qq-and-or.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/qq-and-or.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/cond.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/cond.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define-et-al.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/define-et-al.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxcase-scheme.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stxcase-scheme.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxcase.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stxcase.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/sc.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/sc.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/ellipses.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/ellipses.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/with-stx.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/with-stx.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxloc.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stxloc.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/qqstx.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/qqstx.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/define.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/letstx-scheme.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/letstx-scheme.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/norm-define.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/norm-define.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/misc.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/misc.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxmz-body.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stxmz-body.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-ds.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old-ds.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define-struct.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/define-struct.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/struct-info.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/struct-info.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../stxparam.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/stxparam.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../stxparam-exptime.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/stxparam-exptime.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../private/stxparamkey.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stxparamkey.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-rp.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old-rp.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-if.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old-if.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-procs.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old-procs.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/promise.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/promise.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/tcp.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/tcp.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/udp.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/udp.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzscheme/main.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzscheme/main.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/xform.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/compiler/private/xform.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/list.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/list.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/base.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/base.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/pre-base.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/pre-base.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/kw.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/kw.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/name.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/name.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/sort.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/sort.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/reqprov.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/reqprov.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../require-transform.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/require-transform.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../provide-transform.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/provide-transform.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/modbeg.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/modbeg.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/for.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/for.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/list.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/list.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/string.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/string.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/kw-file.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/kw-file.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/namespace.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/namespace.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/list.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/list.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/etc.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/etc.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/kerncase.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/kerncase.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/stx.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/stx.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/name.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/name.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/main-collects.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/main-collects.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/dirs.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/dirs.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/config/main.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/config/main.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/config/config.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/config/config.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/configtab.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/configtab.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/winutf16.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/compiler/private/winutf16.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/mach-o.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/compiler/private/mach-o.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/path-relativize.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/path-relativize.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/stxset.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/stxset.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/context.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/context.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/local.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/local.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/bool.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/bool.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/kw.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/kw.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/process.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/process.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/port.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/port.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/contract.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/contract.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arrow.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/contract-arrow.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-opt-guts.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-opt-guts.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-guts.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-guts.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-helpers.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-helpers.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/pretty.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/pretty.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/pretty.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/pretty.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/port.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/port.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/private/boundmap.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/private/boundmap.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arr-obj-helpers.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/contract-arr-obj-helpers.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arr-checks.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/contract-arr-checks.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-opt.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-opt.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-object.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/contract-object.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/class-internal.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/class-internal.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/define.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/define.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/stxparam.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/stxparam.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/classidmap.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/classidmap.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/class-events.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/class-events.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/serialize-structs.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/serialize-structs.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/struct-info.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/struct-info.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-arrow.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-arrow.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-ds.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-ds.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-ds-helpers.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-ds-helpers.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-basic-opters.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/contract-basic-opters.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/cmdline.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/cmdline.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/cmdline.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/cmdline.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/cm-ctime.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/cm-ctime.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/mzscheme/lang/reader.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzscheme/lang/reader.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/module-reader.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/module-reader.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/base/lang/reader.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/base/lang/reader.ss Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/lang/reader.ss to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/lang/reader.ss Compiling xform support... --- From mflatt at cs.utah.edu Thu Aug 14 09:03:48 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:25:42 2009 Subject: [plt-scheme] Re: make looping In-Reply-To: <595b9ab20808140555w3ce47decl1079ac7e434c141a@mail.gmail.com> References: <595b9ab20808140525h54d60d8l6bb02b69cd8c5cdd@mail.gmail.com> <595b9ab20808140555w3ce47decl1079ac7e434c141a@mail.gmail.com> Message-ID: <20080814130349.D8B4E65008C@mail-svr1.cs.utah.edu> Do any files have timestamps that correspond to the future? It looks like the xform code is being compiled once for every source C file, perhaps because a file with a future timestamp makes the compiled xform code always appear to be out of date. Matthew At Thu, 14 Aug 2008 13:55:36 +0100, "Stephen De Gabrielle" wrote: > Sorry, I need to be clear- its happing in make; > > svn update; cd src; ./configure > --prefix=/home/user/MMC-SD/sd4gb/local/plt --enable-shared; sudo rm -r > /home/user/MMC-SD/sd4gb/local/plt ;make clean ; make > > I clear the destination dir and run make clean first; but I still get > the following in an endless loop; > -- > Compiling xform support... > Done making xform-collects. > /home/user/MMC-SD/sd4gb/plt/src/lt/libtool --mode=compile --tag=CC gcc > -g -O2 -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB -I./.. -I./../include > -Wall -c xsrc/env.c -o env.lo > gcc -g -O2 -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB -I./.. > -I./../include -Wall -c xsrc/env.c -fPIC -DPIC -o .libs/env.o > env XFORM_USE_PRECOMP=xsrc/precomp.h ../mzschemecgc -cqu ./xform.ss > --setup . --cpp "gcc -E -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB > -I./.. -I./../include" -o xsrc/error.c ./../src/error.c > Removing old xform-collects tree... > Copying tree... > Copying /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/./xform-mod.ss to > xform-collects/xform/xform-mod.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/mzscheme.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/mzscheme.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/more-scheme.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/more- > scheme.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stx.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stx.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/small-scheme.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/small-scheme.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/qq-and-or.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/qq- > and-or.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/cond.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/cond.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define-et-al.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/define-et-al.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxcase-scheme.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/stxcase-scheme.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxcase.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/stxcase.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/sc.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/sc.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/ellipses.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/ellipses.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/with-stx.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/with- > stx.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxloc.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/stxloc.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/qqstx.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/qqstx.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/define.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/letstx-scheme.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/letstx-scheme.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/norm-define.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/norm- > define.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/misc.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/misc.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxmz-body.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/stxmz-body.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-ds.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old- > ds.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define-struct.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/define-struct.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/struct-info.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/struct-info.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../stxparam.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/stxparam.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../stxparam- > exptime.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/stxparam- > exptime.ss > Copying /home/user/MMC- > SD/sd4gb/plt/collects/scheme/private/../private/stxparamkey.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/stxparamkey.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-rp.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old- > rp.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-if.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old- > if.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-procs.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old- > procs.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/promise.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/promise.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/tcp.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/tcp.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/udp.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/udp.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzscheme/main.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzscheme/main.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/xform.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/compiler/private/xform.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/list.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/list.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/base.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/base.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/pre-base.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/pre- > base.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/kw.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/kw.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/name.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/name.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/sort.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/sort.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/reqprov.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/reqprov.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../require- > transform.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/require- > transform.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../provide- > transform.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/provide- > transform.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/modbeg.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/modbeg.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/for.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/for.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/list.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/list.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/string.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/string.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/kw-file.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/kw- > file.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/namespace.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/namespace.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/list.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/list.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/etc.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/etc.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/kerncase.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/kerncase.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/stx.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/stx.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/name.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/name.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/main-collects.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/main-collects.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/dirs.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/dirs.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/config/main.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/config/main.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/config/config.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/config/config.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/configtab.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/configtab.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/winutf16.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/compiler/private/winutf16.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/mach-o.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/compiler/private/mach-o.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/path-relativize.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/path- > relativize.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/stxset.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzlib/private/stxset.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/context.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/context.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/local.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/local.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/bool.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/bool.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/kw.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/kw.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/process.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/process.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/port.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/port.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/contract.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/contract.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arrow.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzlib/private/contract-arrow.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-opt- > guts.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-opt-guts.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-guts.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-guts.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-helpers.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-helpers.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/pretty.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/pretty.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/pretty.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/pretty.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/port.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/port.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/private/boundmap.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/syntax/private/boundmap.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arr-obj- > helpers.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzlib/private/contract-arr-obj-helpers.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arr- > checks.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzlib/private/contract-arr-checks.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-opt.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-opt.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-object.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzlib/private/contract-object.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/class-internal.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/class-internal.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/define.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/define.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/stxparam.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/stxparam.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/classidmap.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/classidmap.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/class-events.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/class-events.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/serialize- > structs.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/serialize-structs.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/struct-info.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/struct-info.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-arrow.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-arrow.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-ds.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-ds.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-ds- > helpers.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-ds-helpers.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-basic- > opters.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-basic-opters.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/cmdline.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/cmdline.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/cmdline.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/cmdline.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/cm-ctime.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/cm- > ctime.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzscheme/lang/reader.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzscheme/lang/reader.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/module-reader.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/module- > reader.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/base/lang/reader.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/base/lang/reader.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/lang/reader.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/lang/reader.ss > Compiling xform support... > Done making xform-collects. > /home/user/MMC-SD/sd4gb/plt/src/lt/libtool --mode=compile --tag=CC gcc > -g -O2 -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB -I./.. -I./../include > -Wall -c xsrc/error.c -o error.lo > gcc -g -O2 -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB -I./.. > -I./../include -Wall -c xsrc/error.c -fPIC -DPIC -o .libs/error.o > env XFORM_USE_PRECOMP=xsrc/precomp.h ../mzschemecgc -cqu ./xform.ss > --setup . --cpp "gcc -E -DNEWGC_BTC_ACCOUNT -DMZ_USES_SHARED_LIB > -I./.. -I./../include" -o xsrc/eval.c ./../src/eval.c > Removing old xform-collects tree... > Copying tree... > ^ACopying /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/./xform-mod.ss to > xform-collects/xform/xform-mod.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/mzscheme.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/mzscheme.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/more-scheme.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/more- > scheme.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stx.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/stx.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/small-scheme.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/small-scheme.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/qq-and-or.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/qq- > and-or.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/cond.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/cond.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define-et-al.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/define-et-al.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxcase-scheme.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/stxcase-scheme.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxcase.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/stxcase.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/sc.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/sc.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/ellipses.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/ellipses.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/with-stx.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/with- > stx.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxloc.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/stxloc.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/qqstx.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/qqstx.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/define.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/letstx-scheme.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/letstx-scheme.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/norm-define.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/norm- > define.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/misc.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/misc.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/stxmz-body.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/stxmz-body.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-ds.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old- > ds.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/define-struct.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/define-struct.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/struct-info.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/struct-info.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../stxparam.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/stxparam.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../stxparam- > exptime.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/stxparam- > exptime.ss > Copying /home/user/MMC- > SD/sd4gb/plt/collects/scheme/private/../private/stxparamkey.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/stxparamkey.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-rp.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old- > rp.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-if.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old- > if.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/old-procs.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/old- > procs.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/promise.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/promise.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/tcp.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/tcp.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/udp.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/udp.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzscheme/main.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzscheme/main.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/xform.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/compiler/private/xform.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/list.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/list.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/base.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/base.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/pre-base.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/pre- > base.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/kw.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/kw.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/name.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/name.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/sort.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/sort.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/reqprov.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/reqprov.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../require- > transform.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/require- > transform.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/../provide- > transform.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/provide- > transform.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/modbeg.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/modbeg.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/for.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/for.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/list.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/list.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/string.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/string.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/kw-file.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/private/kw- > file.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/namespace.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/namespace.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/list.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/list.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/etc.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/etc.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/kerncase.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/kerncase.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/stx.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/stx.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/name.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/name.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/main-collects.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/main-collects.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/dirs.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/dirs.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/config/main.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/config/main.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/config/config.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/config/config.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/configtab.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/configtab.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/winutf16.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/compiler/private/winutf16.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/compiler/private/mach-o.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/compiler/private/mach-o.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/setup/path-relativize.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/setup/path- > relativize.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/stxset.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzlib/private/stxset.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/context.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/context.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/local.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/local.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/bool.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/bool.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/kw.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/kw.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/process.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/process.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/port.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/port.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/contract.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/contract.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arrow.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzlib/private/contract-arrow.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-opt- > guts.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-opt-guts.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-guts.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-guts.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-helpers.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-helpers.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/pretty.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/pretty.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/pretty.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/pretty.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/port.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/port.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/private/boundmap.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/syntax/private/boundmap.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arr-obj- > helpers.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzlib/private/contract-arr-obj-helpers.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-arr- > checks.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzlib/private/contract-arr-checks.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-opt.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-opt.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/contract-object.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzlib/private/contract-object.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/class-internal.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/class-internal.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/define.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/define.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/stxparam.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/stxparam.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/classidmap.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/classidmap.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/class-events.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/class-events.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/serialize- > structs.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/serialize-structs.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/struct-info.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/struct-info.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-arrow.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-arrow.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-ds.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-ds.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-ds- > helpers.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-ds-helpers.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/private/contract-basic- > opters.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/private/contract-basic-opters.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/cmdline.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/cmdline.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/cmdline.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/cmdline.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzlib/private/cm-ctime.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/mzlib/private/cm- > ctime.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/mzscheme/lang/reader.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/mzscheme/lang/reader.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/syntax/module-reader.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/syntax/module- > reader.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/base/lang/reader.ss > to /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform- > collects/scheme/base/lang/reader.ss > Copying /home/user/MMC-SD/sd4gb/plt/collects/scheme/lang/reader.ss to > /media/MMC-SD/sd4gb/plt/src/mzscheme/gc2/xform-collects/scheme/lang/reader.ss > Compiling xform support... > --- > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From matthias at ccs.neu.edu Thu Aug 14 09:49:34 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:42 2009 Subject: Livecoding HtDP (was Re: [plt-scheme] Re: More pedagogic stuff) In-Reply-To: <47987.217.18.21.2.1218704962.squirrel@webmail.pawfal.org> References: <47987.217.18.21.2.1218704962.squirrel@webmail.pawfal.org> Message-ID: <369B6B46-70B2-4B03-A3F9-40E1FBA2562B@ccs.neu.edu> Thanks! Wonderful idea. We'll think about it. -- Matthias On Aug 14, 2008, at 5:09 AM, Dave Griffiths wrote: > >> On Aug 13, 2008, at 11:27, Matthias Felleisen wrote: >>> But if you follow HtDP to its extreme (not in print) you will >>> naturally build abstractions (aka frameworks and libraries and >>> friends) that make it possible to build even faster than the "quick >>> guys" and at least as well. >> >> Just thinking out loud, since I'm at SIGGRAPH, and graphics and >> movies >> are all around. I'm trying to figure out a way to make a DrScheme >> viral video. >> >> To demo HtDP in the extreme, I wonder if we could make a short movie >> of an application growing and following the design recipe? The >> screen >> would show source code as it grows from something really small to >> something that accomplishes a goal. The narrator would represent the >> programmer's thoughts. It would be like watching over the >> shoulder of >> someone who knew what he was doing. > > This is the essence of livecoding - the narrator is an interesting > addition though, I don't think any livecoding performances have > featured > one yet (normally comments are a way to explain what you are doing > to the > audience). > >> I've seen a video demo on this list: fluxus [1]. I remember music >> and flashing colors. > > There is a video of a visuals performance I did quite recently with > fluxus > here: http://blip.tv/file/921513 It was livecoding from scratch (i.e. > starting with nothing), but the video shows extracts of the gig. > There is also a really nice video here of budapest's 'no copy paste' > livecoding mzscheme/fluxus and pure data: http://www.vimeo.com/694298 > > A more goal orientated example of livecoding HtDP would be > interesting to > see. As you are saying, the impression I hear sometimes after gigs > is that > you can tell a lot more about the thought process involved with > programming by following someone doing it live, this is often from > people > who previously had little experience of programming, and found it > difficult to understand. Livecoding can be interesting to them, as it > underlines the human element in the process. > > cheers, > > dave > > From robert.matovinovic at web.de Thu Aug 14 12:08:48 2008 From: robert.matovinovic at web.de (Robert Matovinovic) Date: Thu Mar 26 02:25:43 2009 Subject: [plt-scheme] Replace & Find in v4.1 Message-ID: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> Hi, I run DrScheme, version 4.1 [3m] on Windows XP and wonder where to activate Replace & Find. The button in the search dialog doesn't react and the menu items in the edit menu are grey. I looked up Preferences ... and Help Desk but I couldn't find any hint. What am I missing? If it is not a bug the switch should be in a more obvious place. Robert _________________________________________ Robert Matovinovic Wintererstr. 61 79104 Freiburg Germany Tel: +49 (0)761 51 93 544 Cell: +49 (0)171 56 32 330 email: robert.matovinovic@web.de From morazanm at gmail.com Thu Aug 14 12:10:14 2008 From: morazanm at gmail.com (Marco Morazan) Date: Thu Mar 26 02:25:43 2009 Subject: [plt-scheme] Proper Citation Message-ID: <9b1fff280808140910i6bd86ed6h250c5d02778eccfe@mail.gmail.com> Dear All, What is the proper way to cite the PLT Guide? Does a bibtex entry exist somewhere? Thanks, Marco From matthias at ccs.neu.edu Thu Aug 14 12:16:08 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:43 2009 Subject: [plt-scheme] Proper Citation In-Reply-To: <9b1fff280808140910i6bd86ed6h250c5d02778eccfe@mail.gmail.com> References: <9b1fff280808140910i6bd86ed6h250c5d02778eccfe@mail.gmail.com> Message-ID: Use one of these three for now: http://www.plt-scheme.org/techreports/ 1. Our web site needs a better organization still. 2. These documents should be listed separately. -- Matthias On Aug 14, 2008, at 12:10 PM, Marco Morazan wrote: > Dear All, > > What is the proper way to cite the PLT Guide? Does a bibtex entry > exist somewhere? > > Thanks, > > Marco > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From sbloch at adelphi.edu Thu Aug 14 13:14:37 2008 From: sbloch at adelphi.edu (Stephen Bloch) Date: Thu Mar 26 02:25:43 2009 Subject: [plt-scheme] Re: how do you include documentation with a teachpack or planet collection? In-Reply-To: References: <932b2f1f0708260542p64f0e44cr1c9ef2189f9809c5@mail.gmail.com> <932b2f1f0708270508x583c0f22w63ce2af1c392b670@mail.gmail.com> Message-ID: <47C62BE3-A51E-42E0-87D0-759DB5B22010@adelphi.edu> On Aug 26, 2007, I wrote: >> Here's my goal: create a file (presumably a .plt) that my English- >> major students can install, in one easy step (preferably without >> needing to specify WHERE to install it; it should know by itself), >> after which >> (a) the "tiles.ss" teachpack will appear on the list of available >> teachpacks in the teaching languages (I don't care whether it's on >> the left side or the right), and >> (b) when they add that teachpack, they get a properly compiled >> version (presumably .zo), and >> (c) when they add that teachpack and type the name of one of its >> functions into the Help Desk, they'll see the documentation. (If >> they could also see the documentation WITHOUT adding the teachpack >> first, that would be nice but not required.) >> Is that possible? I've written up some Scribble documentation, and I gather it (and the corresponding teachpack) are supposed to be installed with setup-plt, but I must be missing some very basic assumptions about collection, modules, and PLaneT, and I haven't found them explained anywhere in the documentation. I've set up a directory named "tiles" which contains info.ss functions.scrbl tiles.ss and an empty directory named "doc" I typed "scribble --html --dest doc functions.scrbl" and it seems to have compiled the Scribble correctly to HTML. (I was hoping to include the documentation for "image.ss" in this documentation, since my teachpack provides all-from image.ss, but I haven't gotten that to work yet.) At least this confirms that the .scrbl and (to some extent) the .ss files are syntactically reasonable. But I gather that to actually install the teachpack and its associated documentation, I need to use "setup-plt". So I typed "setup-plt -l tiles ." and got the error message "bad collection path: ." So I tried the same thing from the containing directory, with the same result. What do I do to install a teachpack and its documentation? Once I've got that and tested it locally, the next question is... What do I do to make it easily available on PLaneT? Stephen Bloch sbloch@adelphi.edu From robby at cs.uchicago.edu Thu Aug 14 13:22:11 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:43 2009 Subject: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> References: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> Message-ID: <932b2f1f0808141022u786189d5l20eaac3d240fb251@mail.gmail.com> Did you put some text into the replace field? Robby On Thu, Aug 14, 2008 at 11:08 AM, Robert Matovinovic wrote: > Hi, > I run DrScheme, version 4.1 [3m] on Windows XP and wonder where to activate > Replace & Find. The button in the search dialog doesn't react and the menu > items in the edit menu are grey. I looked up Preferences ... and Help Desk > but I couldn't find any hint. What am I missing? If it is not a bug the > switch should be in a more obvious place. > Robert > > _________________________________________ > Robert Matovinovic > Wintererstr. 61 > 79104 Freiburg > Germany > > Tel: +49 (0)761 51 93 544 > Cell: +49 (0)171 56 32 330 > email: robert.matovinovic@web.de > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From noelwelsh at gmail.com Thu Aug 14 13:32:36 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:43 2009 Subject: [plt-scheme] Re: how do you include documentation with a teachpack or planet collection? In-Reply-To: <47C62BE3-A51E-42E0-87D0-759DB5B22010@adelphi.edu> References: <932b2f1f0708260542p64f0e44cr1c9ef2189f9809c5@mail.gmail.com> <932b2f1f0708270508x583c0f22w63ce2af1c392b670@mail.gmail.com> <47C62BE3-A51E-42E0-87D0-759DB5B22010@adelphi.edu> Message-ID: I'm rushing out, so in brief, to create a PLaneT package: - put your docs in a directory called scribblings (doesn't really matter, but this is the convention) - see the Planet docs for details of what to put in your info.ss, or read, say, the SchemeUnit info.ss which you see on planet.plt-scheme.org - use planet create to create a PLT To put it on PLaneT you just need to create an account and upload your .plt N. On Thu, Aug 14, 2008 at 6:14 PM, Stephen Bloch wrote: > I've set up a directory named "tiles" which contains > info.ss > functions.scrbl > tiles.ss > and an empty directory named "doc" > ... > Once I've got that and tested it locally, the next question is... > What do I do to make it easily available on PLaneT? From robert.matovinovic at web.de Thu Aug 14 14:41:05 2008 From: robert.matovinovic at web.de (Robert Matovinovic) Date: Thu Mar 26 02:25:43 2009 Subject: [plt-scheme] Completions from distinct manuals Message-ID: Hi, I'm also lost on another issue. Up to the current version 4.1 of DrScheme I don't get the completions only from the manual of my DrScheme language extension if I use the function below. What drives me crazy is that if I put 'mysterx instead of 'mycollect in the function, then I only get completions from MysterX. I get all words if I put #f instead of the list. That means it works. (define get-manual-keywords (let ([words #f]) (lambda () (unless words (set! words (text:get-completions/manuals (list 'mycollect)))) words))) I checked the info.ss and installer files for mysterx, but didn't find anything different to mine concerning scribblings or compilation. I assume I have to do something stupid but for me not obvious when my documentation is compiled. I can use F1 and get to the right place in the manual. I see my manual on the first page in Help Desk. But I don't get the completions. There must be a place where I have to tweak the docs. Any ideas? Help appreciated. Robert _________________________________________ Robert Matovinovic Wintererstr. 61 79104 Freiburg Germany Tel: +49 (0)761 51 93 544 Cell: +49 (0)171 56 32 330 email: robert.matovinovic@web.de From robert.matovinovic at web.de Thu Aug 14 14:43:32 2008 From: robert.matovinovic at web.de (Robert Matovinovic) Date: Thu Mar 26 02:25:44 2009 Subject: [plt-scheme] completions from distinct manuals Message-ID: <2053F319D5E641F5A145994A80135B89@IBMI> Hi, I'm also lost on another issue. Up to the current version 4.1 of DrScheme I don't get the completions only from the manual of my DrScheme language extension if I use the function below. What drives me crazy is that if I put 'mysterx instead of 'mycollect in the function, then I only get completions from MysterX. I get all words if I put #f instead of the list. That means it works. (define get-manual-keywords (let ([words #f]) (lambda () (unless words (set! words (text:get-completions/manuals (list 'mycollect)))) words))) I checked the info.ss and installer files for mysterx, but didn't find anything different to mine concerning scribblings or compilation. I assume I have to do something stupid but for me not obvious when my documentation is compiled. I can use F1 and get to the right place in the manual. I see my manual on the first page in Help Desk. But I don't get the completions. There must be a place where I have to tweak the docs. Any ideas? Help appreciated. Robert _________________________________________ Robert Matovinovic Wintererstr. 61 79104 Freiburg Germany Tel: +49 (0)761 51 93 544 Cell: +49 (0)171 56 32 330 email: robert.matovinovic@web.de From robby at cs.uchicago.edu Thu Aug 14 14:47:24 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:44 2009 Subject: [plt-scheme] Completions from distinct manuals In-Reply-To: References: Message-ID: <932b2f1f0808141147u16c00e5btf7ddb57e399deb91@mail.gmail.com> I'm not able to tell from just that much. Maybe if you were to just make a small example mycollect that exhibited the problem, tar it up and send it that would help? You might also try putting some printf's in get-completions/manuals in framework/private/text.ss to see where things are failing. That might also be a clue. Robby On Thu, Aug 14, 2008 at 1:41 PM, Robert Matovinovic wrote: > Hi, > I'm also lost on another issue. Up to the current version 4.1 of DrScheme I > don't get the completions only from the manual of my DrScheme language > extension if I use the function below. What drives me crazy is that if I put > 'mysterx instead of 'mycollect in the function, then I only get completions > from MysterX. I get all words if I put #f instead of the list. That means it > works. > > (define get-manual-keywords > (let ([words #f]) > (lambda () > (unless words > (set! words (text:get-completions/manuals (list 'mycollect)))) > words))) > > I checked the info.ss and installer files for mysterx, but didn't find > anything different to mine concerning scribblings or compilation. > > I assume I have to do something stupid but for me not obvious when my > documentation is compiled. I can use F1 and get to the right place in the > manual. I see my manual on the first page in Help Desk. But I don't get the > completions. There must be a place where I have to tweak the docs. Any > ideas? Help appreciated. > Robert > > _________________________________________ > Robert Matovinovic > Wintererstr. 61 > 79104 Freiburg > Germany > > Tel: +49 (0)761 51 93 544 > Cell: +49 (0)171 56 32 330 > email: robert.matovinovic@web.de > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From goetter at mazama.net Thu Aug 14 15:04:53 2008 From: goetter at mazama.net (Ben Goetter) Date: Thu Mar 26 02:25:44 2009 Subject: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <932b2f1f0808141022u786189d5l20eaac3d240fb251@mail.gmail.com> References: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> <932b2f1f0808141022u786189d5l20eaac3d240fb251@mail.gmail.com> Message-ID: <48A481D5.5020701@mazama.net> On the same platform, I am observing the same behavior. Start DrScheme, then type a little searchable gibberish into the Defs and Ints panes, then make the Find and Replace fields appear with Ctrl+f or Ctrl+r. If you have no text in the Find field, the Replace menu items are enabled. Clicking the "Replace and Find" button will then append the contents of the Replace field to the Definitions or Interactions pane, whichever last had focus. Once text goes into the Find field, occurrences of that text will be highlighted in one of the panes, and the Replace items under the Edit menu will be disabled. Clicking the Replace and Find button then does nothing. Robby Findler wrote: > Did you put some text into the replace field? > > Robby > > On Thu, Aug 14, 2008 at 11:08 AM, Robert Matovinovic > wrote: > >> Hi, >> I run DrScheme, version 4.1 [3m] on Windows XP and wonder where to activate >> Replace & Find. The button in the search dialog doesn't react and the menu >> items in the edit menu are grey. I looked up Preferences ... and Help Desk >> but I couldn't find any hint. What am I missing? If it is not a bug the >> switch should be in a more obvious place. >> Robert >> >> _________________________________________ >> Robert Matovinovic >> Wintererstr. 61 >> 79104 Freiburg >> Germany >> >> Tel: +49 (0)761 51 93 544 >> Cell: +49 (0)171 56 32 330 >> email: robert.matovinovic@web.de >> From robby at cs.uchicago.edu Thu Aug 14 15:08:25 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:44 2009 Subject: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <48A481D5.5020701@mazama.net> References: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> <932b2f1f0808141022u786189d5l20eaac3d240fb251@mail.gmail.com> <48A481D5.5020701@mazama.net> Message-ID: <932b2f1f0808141208w5677de4dy20733b872b8087cd@mail.gmail.com> The (perhaps only slightly) more sensical generalization of those rules is that when the selection matches the search string, you can replace & find (so when the search string is empty and you don't have any thing selected, it will replace nothing with the replace string). Did you try the anchor'd search? Do you find that to be more intuitive? Robby On Thu, Aug 14, 2008 at 2:04 PM, Ben Goetter wrote: > On the same platform, I am observing the same behavior. Start DrScheme, > then type a little searchable gibberish into the Defs and Ints panes, then > make the Find and Replace fields appear with Ctrl+f or Ctrl+r. > > If you have no text in the Find field, the Replace menu items are enabled. > Clicking the "Replace and Find" button will then append the contents of the > Replace field to the Definitions or Interactions pane, whichever last had > focus. > > Once text goes into the Find field, occurrences of that text will be > highlighted in one of the panes, and the Replace items under the Edit menu > will be disabled. Clicking the Replace and Find button then does nothing. > > > Robby Findler wrote: >> >> Did you put some text into the replace field? >> >> Robby >> >> On Thu, Aug 14, 2008 at 11:08 AM, Robert Matovinovic >> wrote: >> >>> >>> Hi, >>> I run DrScheme, version 4.1 [3m] on Windows XP and wonder where to >>> activate >>> Replace & Find. The button in the search dialog doesn't react and the >>> menu >>> items in the edit menu are grey. I looked up Preferences ... and Help >>> Desk >>> but I couldn't find any hint. What am I missing? If it is not a bug the >>> switch should be in a more obvious place. >>> Robert >>> >>> _________________________________________ >>> Robert Matovinovic >>> Wintererstr. 61 >>> 79104 Freiburg >>> Germany >>> >>> Tel: +49 (0)761 51 93 544 >>> Cell: +49 (0)171 56 32 330 >>> email: robert.matovinovic@web.de >>> > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From goetter at mazama.net Thu Aug 14 15:34:16 2008 From: goetter at mazama.net (Ben Goetter) Date: Thu Mar 26 02:25:44 2009 Subject: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <932b2f1f0808141208w5677de4dy20733b872b8087cd@mail.gmail.com> References: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> <932b2f1f0808141022u786189d5l20eaac3d240fb251@mail.gmail.com> <48A481D5.5020701@mazama.net> <932b2f1f0808141208w5677de4dy20733b872b8087cd@mail.gmail.com> Message-ID: <48A488B8.5010102@mazama.net> I have tried it, and I'm afraid it doesn't make much more sense to me. The behavior - both with anchors enabled and disabled - seems inconsistent: sometimes the Replace commands I want are available, and sometimes they aren't. I am having a very difficult time deducing the desired behavior here. Robby Findler wrote: > The (perhaps only slightly) more sensical generalization of those > rules is that when the selection matches the search string, you can > replace & find (so when the search string is empty and you don't have > any thing selected, it will replace nothing with the replace string). > > Did you try the anchor'd search? Do you find that to be more intuitive? > > Robby > > On Thu, Aug 14, 2008 at 2:04 PM, Ben Goetter wrote: > >> On the same platform, I am observing the same behavior. Start DrScheme, >> then type a little searchable gibberish into the Defs and Ints panes, then >> make the Find and Replace fields appear with Ctrl+f or Ctrl+r. >> >> If you have no text in the Find field, the Replace menu items are enabled. >> Clicking the "Replace and Find" button will then append the contents of the >> Replace field to the Definitions or Interactions pane, whichever last had >> focus. >> >> Once text goes into the Find field, occurrences of that text will be >> highlighted in one of the panes, and the Replace items under the Edit menu >> will be disabled. Clicking the Replace and Find button then does nothing. >> >> >> Robby Findler wrote: >> >>> Did you put some text into the replace field? >>> >>> Robby >>> >>> On Thu, Aug 14, 2008 at 11:08 AM, Robert Matovinovic >>> wrote: >>> >>> >>>> Hi, >>>> I run DrScheme, version 4.1 [3m] on Windows XP and wonder where to >>>> activate >>>> Replace & Find. The button in the search dialog doesn't react and the >>>> menu >>>> items in the edit menu are grey. I looked up Preferences ... and Help >>>> Desk >>>> but I couldn't find any hint. What am I missing? If it is not a bug the >>>> switch should be in a more obvious place. >>>> Robert >>>> From yinso.chen at gmail.com Thu Aug 14 15:37:07 2008 From: yinso.chen at gmail.com (YC) Date: Thu Mar 26 02:25:45 2009 Subject: [plt-scheme] recovering the read input? Message-ID: <779bf2730808141237p5994d44etd72482abb33041da@mail.gmail.com> Hi - is there a way to get back the read inputs from `(read)`? Basically, both strings "(foo a b)" and "(foo a b)" produces the same list by `read`, but they are diferent inputs. Is there a way to get the original input after the data have been consumed by `read`? Thanks, yc -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080814/3742a681/attachment.htm From robby at cs.uchicago.edu Thu Aug 14 15:53:51 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:45 2009 Subject: [plt-scheme] recovering the read input? In-Reply-To: <779bf2730808141237p5994d44etd72482abb33041da@mail.gmail.com> References: <779bf2730808141237p5994d44etd72482abb33041da@mail.gmail.com> Message-ID: <932b2f1f0808141253q7ac92a1ag65d87e591a519d60@mail.gmail.com> No, but read-syntax still has source location information in the syntax objects (along with lots of other information). Robby On Thu, Aug 14, 2008 at 2:37 PM, YC wrote: > Hi - > > is there a way to get back the read inputs from `(read)`? Basically, both > strings "(foo a b)" and "(foo a b)" produces the same list by > `read`, but they are diferent inputs. Is there a way to get the original > input after the data have been consumed by `read`? > > Thanks, > yc > > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From robby at cs.uchicago.edu Thu Aug 14 15:54:45 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:45 2009 Subject: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <48A488B8.5010102@mazama.net> References: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> <932b2f1f0808141022u786189d5l20eaac3d240fb251@mail.gmail.com> <48A481D5.5020701@mazama.net> <932b2f1f0808141208w5677de4dy20733b872b8087cd@mail.gmail.com> <48A488B8.5010102@mazama.net> Message-ID: <932b2f1f0808141254ta9b39bbq79100a8f0202eea0@mail.gmail.com> The replace is always available when the selection (in the window where you'd be replacing) matches what you are searching for. Otherwise, it is not available. Does that help? Robby On Thu, Aug 14, 2008 at 2:34 PM, Ben Goetter wrote: > I have tried it, and I'm afraid it doesn't make much more sense to me. The > behavior - both with anchors enabled and disabled - seems inconsistent: > sometimes the Replace commands I want are available, and sometimes they > aren't. I am having a very difficult time deducing the desired behavior > here. > > Robby Findler wrote: >> >> The (perhaps only slightly) more sensical generalization of those >> rules is that when the selection matches the search string, you can >> replace & find (so when the search string is empty and you don't have >> any thing selected, it will replace nothing with the replace string). >> >> Did you try the anchor'd search? Do you find that to be more intuitive? >> >> Robby >> >> On Thu, Aug 14, 2008 at 2:04 PM, Ben Goetter wrote: >> >>> >>> On the same platform, I am observing the same behavior. Start DrScheme, >>> then type a little searchable gibberish into the Defs and Ints panes, >>> then >>> make the Find and Replace fields appear with Ctrl+f or Ctrl+r. >>> >>> If you have no text in the Find field, the Replace menu items are >>> enabled. >>> Clicking the "Replace and Find" button will then append the contents of >>> the >>> Replace field to the Definitions or Interactions pane, whichever last had >>> focus. >>> >>> Once text goes into the Find field, occurrences of that text will be >>> highlighted in one of the panes, and the Replace items under the Edit >>> menu >>> will be disabled. Clicking the Replace and Find button then does >>> nothing. >>> >>> >>> Robby Findler wrote: >>> >>>> >>>> Did you put some text into the replace field? >>>> >>>> Robby >>>> >>>> On Thu, Aug 14, 2008 at 11:08 AM, Robert Matovinovic >>>> wrote: >>>> >>>> >>>>> >>>>> Hi, >>>>> I run DrScheme, version 4.1 [3m] on Windows XP and wonder where to >>>>> activate >>>>> Replace & Find. The button in the search dialog doesn't react and the >>>>> menu >>>>> items in the edit menu are grey. I looked up Preferences ... and Help >>>>> Desk >>>>> but I couldn't find any hint. What am I missing? If it is not a bug the >>>>> switch should be in a more obvious place. >>>>> Robert >>>>> > > > From goetter at mazama.net Thu Aug 14 16:36:29 2008 From: goetter at mazama.net (Ben Goetter) Date: Thu Mar 26 02:25:45 2009 Subject: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <932b2f1f0808141254ta9b39bbq79100a8f0202eea0@mail.gmail.com> References: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> <932b2f1f0808141022u786189d5l20eaac3d240fb251@mail.gmail.com> <48A481D5.5020701@mazama.net> <932b2f1f0808141208w5677de4dy20733b872b8087cd@mail.gmail.com> <48A488B8.5010102@mazama.net> <932b2f1f0808141254ta9b39bbq79100a8f0202eea0@mail.gmail.com> Message-ID: <48A4974D.3070309@mazama.net> Thank you, your explanation does indeed help. So Edit/Find defines a sequence of matches in a pane, and then Edit/Find Again iterates through that sequence, selecting the text of a particular match. And Edit/ReplaceXxx is only operative with a text selection (and a matching selection, at that), not just a match sequence. I see. Sorry to be obtuse. And this explains the problem! The "Find" button in the search pane is really performing Edit/Find Again. However, when performing this task via button click, there is no highlight drawn in the pane corresponding to the selected match. Thus also with the "Replace & Find" button. It is only operative with a text selection. However, text selections made via the "Find" button (as opposed to the Edit/Find Again menu item) are not highlighted visibly; and the subsequent selection of the next match by "Replace & Find" is not visibly highlighted, either. I will file a bug about the lack of text highlights. Thanks for your clarifications. Ben Robby Findler wrote: > The replace is always available when the selection (in the window > where you'd be replacing) matches what you are searching for. > Otherwise, it is not available. > > Does that help? > > Robby > > On Thu, Aug 14, 2008 at 2:34 PM, Ben Goetter wrote: > >> I have tried it, and I'm afraid it doesn't make much more sense to me. The >> behavior - both with anchors enabled and disabled - seems inconsistent: >> sometimes the Replace commands I want are available, and sometimes they >> aren't. I am having a very difficult time deducing the desired behavior >> here. >> >> Robby Findler wrote: >> >>> The (perhaps only slightly) more sensical generalization of those >>> rules is that when the selection matches the search string, you can >>> replace & find (so when the search string is empty and you don't have >>> any thing selected, it will replace nothing with the replace string). >>> >>> Did you try the anchor'd search? Do you find that to be more intuitive? >>> >>> Robby >>> >>> On Thu, Aug 14, 2008 at 2:04 PM, Ben Goetter wrote: >>> >>> >>>> On the same platform, I am observing the same behavior. Start DrScheme, >>>> then type a little searchable gibberish into the Defs and Ints panes, >>>> then >>>> make the Find and Replace fields appear with Ctrl+f or Ctrl+r. >>>> >>>> If you have no text in the Find field, the Replace menu items are >>>> enabled. >>>> Clicking the "Replace and Find" button will then append the contents of >>>> the >>>> Replace field to the Definitions or Interactions pane, whichever last had >>>> focus. >>>> >>>> Once text goes into the Find field, occurrences of that text will be >>>> highlighted in one of the panes, and the Replace items under the Edit >>>> menu >>>> will be disabled. Clicking the Replace and Find button then does >>>> nothing. >>>> >>>> >>>> Robby Findler wrote: >>>> >>>> >>>>> Did you put some text into the replace field? >>>>> >>>>> Robby >>>>> >>>>> On Thu, Aug 14, 2008 at 11:08 AM, Robert Matovinovic >>>>> wrote: >>>>> >>>>> >>>>> >>>>>> Hi, >>>>>> I run DrScheme, version 4.1 [3m] on Windows XP and wonder where to >>>>>> activate >>>>>> Replace & Find. The button in the search dialog doesn't react and the >>>>>> menu >>>>>> items in the edit menu are grey. I looked up Preferences ... and Help >>>>>> Desk >>>>>> but I couldn't find any hint. What am I missing? If it is not a bug the >>>>>> switch should be in a more obvious place. >>>>>> Robert >>>>>> >>>>>> From robby at cs.uchicago.edu Thu Aug 14 16:42:25 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:46 2009 Subject: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <48A4974D.3070309@mazama.net> References: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> <932b2f1f0808141022u786189d5l20eaac3d240fb251@mail.gmail.com> <48A481D5.5020701@mazama.net> <932b2f1f0808141208w5677de4dy20733b872b8087cd@mail.gmail.com> <48A488B8.5010102@mazama.net> <932b2f1f0808141254ta9b39bbq79100a8f0202eea0@mail.gmail.com> <48A4974D.3070309@mazama.net> Message-ID: <932b2f1f0808141342o67f3a102rbe86b97f45fc7279@mail.gmail.com> On Thu, Aug 14, 2008 at 3:36 PM, Ben Goetter wrote: > Thank you, your explanation does indeed help. So Edit/Find defines a > sequence of matches in a pane, and then Edit/Find Again iterates through > that sequence, selecting the text of a particular match. And > Edit/ReplaceXxx is only operative with a text selection (and a matching > selection, at that), not just a match sequence. I see. Sorry to be obtuse. Not at all. I think that this find and replace implementation is better than what we had before, but it is still rough in a few ways. I've struggled to find the right balance of keybindings/operations to keep it both simple and useful. > And this explains the problem! The "Find" button in the search pane is > really performing Edit/Find Again. Right. Gee, that's confusing. Duh. I should make that say "Find Again". > However, when performing this task via > button click, there is no highlight drawn in the pane corresponding to the > selected match. Thus also with the "Replace & Find" button. It is only > operative with a text selection. However, text selections made via the > "Find" button (as opposed to the Edit/Find Again menu item) are not > highlighted visibly; and the subsequent selection of the next match by > "Replace & Find" is not visibly highlighted, either. There should be. If the focus is in the window where you're searching, you should see the selection move. If the focus is in the search window, you should see a tan circle moving around inside the purple circles. Maybe that is just too light somehow? Robby > Ben > > Robby Findler wrote: >> >> The replace is always available when the selection (in the window >> where you'd be replacing) matches what you are searching for. >> Otherwise, it is not available. >> >> Does that help? >> >> Robby >> >> On Thu, Aug 14, 2008 at 2:34 PM, Ben Goetter wrote: >> >>> >>> I have tried it, and I'm afraid it doesn't make much more sense to me. >>> The >>> behavior - both with anchors enabled and disabled - seems inconsistent: >>> sometimes the Replace commands I want are available, and sometimes they >>> aren't. I am having a very difficult time deducing the desired behavior >>> here. >>> >>> Robby Findler wrote: >>> >>>> >>>> The (perhaps only slightly) more sensical generalization of those >>>> rules is that when the selection matches the search string, you can >>>> replace & find (so when the search string is empty and you don't have >>>> any thing selected, it will replace nothing with the replace string). >>>> >>>> Did you try the anchor'd search? Do you find that to be more intuitive? >>>> >>>> Robby >>>> >>>> On Thu, Aug 14, 2008 at 2:04 PM, Ben Goetter wrote: >>>> >>>> >>>>> >>>>> On the same platform, I am observing the same behavior. Start >>>>> DrScheme, >>>>> then type a little searchable gibberish into the Defs and Ints panes, >>>>> then >>>>> make the Find and Replace fields appear with Ctrl+f or Ctrl+r. >>>>> >>>>> If you have no text in the Find field, the Replace menu items are >>>>> enabled. >>>>> Clicking the "Replace and Find" button will then append the contents of >>>>> the >>>>> Replace field to the Definitions or Interactions pane, whichever last >>>>> had >>>>> focus. >>>>> >>>>> Once text goes into the Find field, occurrences of that text will be >>>>> highlighted in one of the panes, and the Replace items under the Edit >>>>> menu >>>>> will be disabled. Clicking the Replace and Find button then does >>>>> nothing. >>>>> >>>>> >>>>> Robby Findler wrote: >>>>> >>>>> >>>>>> >>>>>> Did you put some text into the replace field? >>>>>> >>>>>> Robby >>>>>> >>>>>> On Thu, Aug 14, 2008 at 11:08 AM, Robert Matovinovic >>>>>> wrote: >>>>>> >>>>>> >>>>>> >>>>>>> >>>>>>> Hi, >>>>>>> I run DrScheme, version 4.1 [3m] on Windows XP and wonder where to >>>>>>> activate >>>>>>> Replace & Find. The button in the search dialog doesn't react and the >>>>>>> menu >>>>>>> items in the edit menu are grey. I looked up Preferences ... and Help >>>>>>> Desk >>>>>>> but I couldn't find any hint. What am I missing? If it is not a bug >>>>>>> the >>>>>>> switch should be in a more obvious place. >>>>>>> Robert >>>>>>> >>>>>>> > > From goetter at mazama.net Thu Aug 14 16:53:15 2008 From: goetter at mazama.net (Ben Goetter) Date: Thu Mar 26 02:25:46 2009 Subject: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <932b2f1f0808141342o67f3a102rbe86b97f45fc7279@mail.gmail.com> References: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> <932b2f1f0808141022u786189d5l20eaac3d240fb251@mail.gmail.com> <48A481D5.5020701@mazama.net> <932b2f1f0808141208w5677de4dy20733b872b8087cd@mail.gmail.com> <48A488B8.5010102@mazama.net> <932b2f1f0808141254ta9b39bbq79100a8f0202eea0@mail.gmail.com> <48A4974D.3070309@mazama.net> <932b2f1f0808141342o67f3a102rbe86b97f45fc7279@mail.gmail.com> Message-ID: <48A49B3B.1070406@mazama.net> Robby Findler wrote: >> However, text selections made via the >> "Find" button (as opposed to the Edit/Find Again menu item) are not >> highlighted visibly; and the subsequent selection of the next match by >> "Replace & Find" is not visibly highlighted, either. >> > There should be. If the focus is in the window where you're searching, > you should see the selection move. If the focus is in the search > window, you should see a tan circle moving around inside the purple > circles. Maybe that is just too light somehow? > > No, it really isn't being drawn in response to Find Again via button. Find Again via keyboard menuitem accelerator works as expected. To repro: 1. Start a fresh DrScheme. (Win XP SP2) 2. In the defns pane, type "one two three four five six seven" 3. Ctrl+f to go to the Find field 4. Type "three" - you'll see the proper purple oval appear in the defns pane 5. Without keyboard focus leaving rhe Find field, type Ctrl+g. You'll see the light tan, indicative of selection in a text control that doesn't have focus. 6. Click with mouse back into the defns pane to clear the selection and give the pane focus 7. Now click the Find button. It won't draw any text selection, either light tan or blue. 8. Pull down the Edit menu. All the Replace menu items are enabled, because in fact the text is selected -- just invisibly so. 9. You can prove the selection by mousing into the Replace field, typing "baz" or some such, and pressing the Replace button. The invisibly selected "three" will be replaced with "baz." Invisible selections is the only confusing thing. Once you can see the selections, it'll be easy to figure out what the controls do. From robby at cs.uchicago.edu Thu Aug 14 16:55:49 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:46 2009 Subject: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <48A49B3B.1070406@mazama.net> References: <6232A0F831DC4A9382B22C086E9CAACC@IBMI> <932b2f1f0808141022u786189d5l20eaac3d240fb251@mail.gmail.com> <48A481D5.5020701@mazama.net> <932b2f1f0808141208w5677de4dy20733b872b8087cd@mail.gmail.com> <48A488B8.5010102@mazama.net> <932b2f1f0808141254ta9b39bbq79100a8f0202eea0@mail.gmail.com> <48A4974D.3070309@mazama.net> <932b2f1f0808141342o67f3a102rbe86b97f45fc7279@mail.gmail.com> <48A49B3B.1070406@mazama.net> Message-ID: <932b2f1f0808141355t7e0f85efy8b2ead98ce08acfa@mail.gmail.com> Oh, yes. I see. Very helpful. Technically, the tan oval is part of searching (which is the root of the problem). Thanks, Robby On Thu, Aug 14, 2008 at 3:53 PM, Ben Goetter wrote: > Robby Findler wrote: >>> >>> However, text selections made via the >>> "Find" button (as opposed to the Edit/Find Again menu item) are not >>> highlighted visibly; and the subsequent selection of the next match by >>> "Replace & Find" is not visibly highlighted, either. >>> >> >> There should be. If the focus is in the window where you're searching, >> you should see the selection move. If the focus is in the search >> window, you should see a tan circle moving around inside the purple >> circles. Maybe that is just too light somehow? >> >> > > No, it really isn't being drawn in response to Find Again via button. Find > Again via keyboard menuitem accelerator works as expected. > > To repro: > 1. Start a fresh DrScheme. (Win XP SP2) > 2. In the defns pane, type "one two three four five six seven" > 3. Ctrl+f to go to the Find field > 4. Type "three" - you'll see the proper purple oval appear in the defns pane > 5. Without keyboard focus leaving rhe Find field, type Ctrl+g. You'll see > the light tan, indicative of selection in a text control that doesn't have > focus. > 6. Click with mouse back into the defns pane to clear the selection and give > the pane focus > 7. Now click the Find button. It won't draw any text selection, either > light tan or blue. > 8. Pull down the Edit menu. All the Replace menu items are enabled, because > in fact the text is selected -- just invisibly so. > 9. You can prove the selection by mousing into the Replace field, typing > "baz" or some such, and pressing the Replace button. The invisibly selected > "three" will be replaced with "baz." > > Invisible selections is the only confusing thing. Once you can see the > selections, it'll be easy to figure out what the controls do. > > > From clklein at cs.uchicago.edu Thu Aug 14 19:43:17 2008 From: clklein at cs.uchicago.edu (Casey Klein) Date: Thu Mar 26 02:25:46 2009 Subject: [plt-scheme] `match' weirdness Message-ID: The expression (match 1 [2 3] [_ (values 4 5)]) reduces to (values 4 5) but (match 1 [(or 2) 3] [_ (values 4 5)]) produces "context expected 1 value, received 2 values: 4 5." Is this a bug in `match'? From sk at cs.brown.edu Thu Aug 14 20:03:01 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:25:46 2009 Subject: [plt-scheme] new interactive programming material for beginners Message-ID: Dear PLT Users, As some of you know, we have been working on a new way of writing interactive applications, such as games, using just pure functional programming. We call this the World style, and it is embodied in the world.ss Teachpack included in the DrScheme distribution. In response to demand, we are creating extended materials on this style of programming: http://world.cs.brown.edu/ There you will find a small booklet introducing the World through an extended example. You will also find four more exercises, including animations showing the different versions of the programs in action. To support people engaged in self-study, the solutions to some exercises have no password protection. Over time we hope to maintain parity between unprotected and protected material. Very special thanks to Danny Yoo (WPI) and Zhe Zhang (Brown) for their work in preparing the solutions and generating the videos, etc. ----- Do write if you have questions or comments. If you are writing off-list, please CC your message to Kathi Fisler (kfisler@cs.wpi.edu) and Matthias Felleisen (matthias@ccs.neu.edu) as I will have very limited email access for the rest of the month. Enjoy, and welcome to our World! Shriram From samth at ccs.neu.edu Thu Aug 14 22:27:51 2008 From: samth at ccs.neu.edu (Sam TH) Date: Thu Mar 26 02:25:47 2009 Subject: [plt-scheme] `match' weirdness In-Reply-To: References: Message-ID: <63bb19ae0808141927x6c3e38e3o9455296ea269be43@mail.gmail.com> Yes, this is a bug. Please file a bug report about this. Thanks for finding this. sam th On Thu, Aug 14, 2008 at 7:43 PM, Casey Klein wrote: > The expression > > (match 1 > [2 3] > [_ (values 4 5)]) > > reduces to (values 4 5) but > > (match 1 > [(or 2) 3] > [_ (values 4 5)]) > > produces "context expected 1 value, received 2 values: 4 5." Is this a > bug in `match'? > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -- sam th samth@ccs.neu.edu From sbloch at adelphi.edu Thu Aug 14 22:53:58 2008 From: sbloch at adelphi.edu (Stephen Bloch) Date: Thu Mar 26 02:25:47 2009 Subject: [plt-scheme] Re: how do you include documentation with a teachpack or planet collection? In-Reply-To: References: <932b2f1f0708260542p64f0e44cr1c9ef2189f9809c5@mail.gmail.com> <932b2f1f0708270508x583c0f22w63ce2af1c392b670@mail.gmail.com> <47C62BE3-A51E-42E0-87D0-759DB5B22010@adelphi.edu> Message-ID: On Aug 14, 2008, at 1:32 PM, Noel Welsh wrote: > I'm rushing out, so in brief, to create a PLaneT package: > > - put your docs in a directory called scribblings (doesn't really > matter, but this is the convention) > - see the Planet docs for details of what to put in your info.ss, or > read, say, the SchemeUnit info.ss which you see on > planet.plt-scheme.org > - use > planet create > to create a PLT Thanks. I've found and read some more documentation, and both it and the above message are helping. In particular, I've created a .plt package, installed it, and the Help Desk can now find my documentation. Yay! Is there a way to control WHERE the package gets unpacked? Ideally, I'd like it to show up in the "installed-teachpacks" directory, rather than (or in addition to) the PLaneT cache directory, so my students only have to type the "(require ...)" thing once, after which they can just use "Add Teachpack". I tried putting a few lines at the end of the module that check in the "installed-teachpacks" directory for a file with the same name as (this-expression-file-name), and if it's not there, copies the current source file to that directory... but there MUST be a better way than that! Stephen Bloch sbloch@adelphi.edu From robby at cs.uchicago.edu Thu Aug 14 23:26:18 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:47 2009 Subject: [plt-scheme] Re: how do you include documentation with a teachpack or planet collection? In-Reply-To: References: <932b2f1f0708260542p64f0e44cr1c9ef2189f9809c5@mail.gmail.com> <932b2f1f0708270508x583c0f22w63ce2af1c392b670@mail.gmail.com> <47C62BE3-A51E-42E0-87D0-759DB5B22010@adelphi.edu> Message-ID: <932b2f1f0808142026h7ae49480j268ad6e89d2c6325@mail.gmail.com> No, there isn't a better way than that, I'm sorry to say. And your script should probably make sure it has permissions to write to that directory or else it will fail for some folks. We do plan to go back to something more like the standard file dialog for teachpacks and also to emphasize using `require' directly, but that's not something we've done yet. Robby On Thu, Aug 14, 2008 at 9:53 PM, Stephen Bloch wrote: > > On Aug 14, 2008, at 1:32 PM, Noel Welsh wrote: > >> I'm rushing out, so in brief, to create a PLaneT package: >> >> - put your docs in a directory called scribblings (doesn't really >> matter, but this is the convention) >> - see the Planet docs for details of what to put in your info.ss, or >> read, say, the SchemeUnit info.ss which you see on >> planet.plt-scheme.org >> - use >> planet create >> to create a PLT > > Thanks. I've found and read some more documentation, and both it and the > above message are helping. In particular, I've created a .plt package, > installed it, and the Help Desk can now find my documentation. Yay! > > Is there a way to control WHERE the package gets unpacked? Ideally, I'd > like it to show up in the "installed-teachpacks" directory, rather than (or > in addition to) the PLaneT cache directory, so my students only have to type > the "(require ...)" thing once, after which they can just use "Add > Teachpack". > > I tried putting a few lines at the end of the module that check in the > "installed-teachpacks" directory for a file with the same name as > (this-expression-file-name), and if it's not there, copies the current > source file to that directory... but there MUST be a better way than that! > > Stephen Bloch > sbloch@adelphi.edu > > > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From robert.matovinovic at web.de Fri Aug 15 01:00:34 2008 From: robert.matovinovic at web.de (Robert Matovinovic) Date: Thu Mar 26 02:25:47 2009 Subject: AW: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <932b2f1f0808141355t7e0f85efy8b2ead98ce08acfa@mail.gmail.com> Message-ID: Thanks to you both, Ben and Robby. It was exactly what I wanted to write about the issue today, because after a long day I needed some rest and food. Robert > -----Urspr?ngliche Nachricht----- > Von: robby.findler@gmail.com [mailto:robby.findler@gmail.com] > Im Auftrag von Robby Findler > Gesendet: Donnerstag, 14. August 2008 22:56 > An: Ben Goetter > Cc: Robert Matovinovic; plt-scheme@list.cs.brown.edu > Betreff: Re: [plt-scheme] Replace & Find in v4.1 > > > Oh, yes. I see. Very helpful. > > Technically, the tan oval is part of searching (which is the > root of the problem). > > Thanks, > Robby > > On Thu, Aug 14, 2008 at 3:53 PM, Ben Goetter > wrote: > > Robby Findler wrote: > >>> > >>> However, text selections made via the > >>> "Find" button (as opposed to the Edit/Find Again menu > item) are not > >>> highlighted visibly; and the subsequent selection of the > next match > >>> by "Replace & Find" is not visibly highlighted, either. > >>> > >> > >> There should be. If the focus is in the window where you're > >> searching, you should see the selection move. If the focus > is in the > >> search window, you should see a tan circle moving around > inside the > >> purple circles. Maybe that is just too light somehow? > >> > >> > > > > No, it really isn't being drawn in response to Find Again > via button. > > Find Again via keyboard menuitem accelerator works as expected. > > > > To repro: > > 1. Start a fresh DrScheme. (Win XP SP2) > > 2. In the defns pane, type "one two three four five six seven" 3. > > Ctrl+f to go to the Find field 4. Type "three" - you'll see > the proper > > purple oval appear in the defns pane 5. Without keyboard > focus leaving > > rhe Find field, type Ctrl+g. You'll see the light tan, > indicative of > > selection in a text control that doesn't have focus. > > 6. Click with mouse back into the defns pane to clear the > selection and give > > the pane focus > > 7. Now click the Find button. It won't draw any text > selection, either > > light tan or blue. > > 8. Pull down the Edit menu. All the Replace menu items are > enabled, because > > in fact the text is selected -- just invisibly so. > > 9. You can prove the selection by mousing into the Replace > field, typing > > "baz" or some such, and pressing the Replace button. The > invisibly selected > > "three" will be replaced with "baz." > > > > Invisible selections is the only confusing thing. Once you can see > > the selections, it'll be easy to figure out what the controls do. > > > > > > > From eli at barzilay.org Fri Aug 15 01:11:51 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:47 2009 Subject: [plt-scheme] Re: how do you include documentation with a teachpack or planet collection? In-Reply-To: <932b2f1f0808142026h7ae49480j268ad6e89d2c6325@mail.gmail.com> References: <932b2f1f0708260542p64f0e44cr1c9ef2189f9809c5@mail.gmail.com> <932b2f1f0708270508x583c0f22w63ce2af1c392b670@mail.gmail.com> <47C62BE3-A51E-42E0-87D0-759DB5B22010@adelphi.edu> <932b2f1f0808142026h7ae49480j268ad6e89d2c6325@mail.gmail.com> Message-ID: <18597.4119.916172.762905@arabic.ccs.neu.edu> Actually, there might be a way to get what you want (it wasn't clear if this is what you tried so apologies if you already did). The first step is to create a post-installer hook -- add a line like this to your "info.ss": (define post-install-collection "post-installer.ss") Then, the real work happens in that hook -- in the "post-installer.ss" put something like the following (warning: completely untested skeleton code...), which creates a stub file that reprovides the teachpack from planet: -------------------------------------------------------------------- #lang scheme/base (provide post-installer) ;; the filename for your teachpack (define tp-name "my-teachpack.ss") ;; the require spec for your package (define tp-req '(planet foo/bar)) (require scheme/path) (define tp-dir (build-path (find-system-path 'addon-dir) (version) "collects" "installed-teachpacks")) (define tp-path (build-path tp-dir tp-name)) (define (post-installer plt-home) ;; a stub file that provides everything from the planet package (define stub-file (format ";; stub for ~s\n#lang scheme/base\n(require ~s)\n" tp-req tp-req)) ;; create the directory if it's not there (make-directory* tp-dir) (let ([existing (and (file-exists? tp-path) (with-input-from-file tp-path (lambda () (read-string (string-length stub-file)))))]) (cond [(not existing) ;; the file is not there, write it (with-output-to-file tp-path (lambda () (display stub-file)))] [(not (equal? stub-file existing)) ;; the file is there, but has different contents (some-gui-warning "The ~a teachpack was not added because blah blah blah" tp-name)] ;; otherwise there is nothing to do -- the file is there, ;; and has our contents, probably from a previous install ))) -------------------------------------------------------------------- Note that this does not check for permissions -- this code happens after the planet package was installed, so you should be able to write to the user-specific collection tree. On Aug 14, Robby Findler wrote: > No, there isn't a better way than that, I'm sorry to say. And your > script should probably make sure it has permissions to write to that > directory or else it will fail for some folks. > > We do plan to go back to something more like the standard file > dialog for teachpacks and also to emphasize using `require' > directly, but that's not something we've done yet. > > Robby > > On Thu, Aug 14, 2008 at 9:53 PM, Stephen Bloch wrote: > > > > Is there a way to control WHERE the package gets unpacked? > > Ideally, I'd like it to show up in the "installed-teachpacks" > > directory, rather than (or in addition to) the PLaneT cache > > directory, so my students only have to type the "(require ...)" > > thing once, after which they can just use "Add Teachpack". > > > > I tried putting a few lines at the end of the module that check in > > the "installed-teachpacks" directory for a file with the same name > > as (this-expression-file-name), and if it's not there, copies the > > current source file to that directory... but there MUST be a > > better way than that! -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From DekuDekuplex at Yahoo.com Fri Aug 15 04:49:09 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:25:47 2009 Subject: [plt-scheme] Re: new interactive programming material for beginners References: Message-ID: On Thu, 14 Aug 2008 20:03:01 -0400, "Shriram Krishnamurthi" wrote: >Dear PLT Users, > >As some of you know, we have been working on a new way of writing >interactive applications, such as games, using just pure functional >programming. We call this the World style, and it is embodied in the >world.ss Teachpack included in the DrScheme distribution. > >In response to demand, we are creating extended materials on this >style of programming: > > http://world.cs.brown.edu/ Fascinating! The following sentence on page 1 of Chapter 1: >DrScheme treats images just like numbers, symbols, and other Scheme values, which means you can >write functions that consume and produce them. reminded me of the treatment of images as parameters to functions in the following essay: 1 Why Computer Science Doesn't Matter http://www.ccs.neu.edu/home/matthias/essays/not-matter.html which was recently introduced in this forum by Matthias Felleisen in the following thread: [plt-scheme] Re: More pedagogic stuff: http://list.cs.brown.edu/pipermail/plt-scheme/2008-August/026430.html Correct me if I am wrong, but is this a continuation? ;-) -- Benjamin L. Russell From sbloch at adelphi.edu Fri Aug 15 06:48:02 2008 From: sbloch at adelphi.edu (Stephen Bloch) Date: Thu Mar 26 02:25:48 2009 Subject: [plt-scheme] Re: how do you include documentation with a teachpack or planet collection? In-Reply-To: <18597.4119.916172.762905@arabic.ccs.neu.edu> References: <932b2f1f0708260542p64f0e44cr1c9ef2189f9809c5@mail.gmail.com> <932b2f1f0708270508x583c0f22w63ce2af1c392b670@mail.gmail.com> <47C62BE3-A51E-42E0-87D0-759DB5B22010@adelphi.edu> <932b2f1f0808142026h7ae49480j268ad6e89d2c6325@mail.gmail.com> <18597.4119.916172.762905@arabic.ccs.neu.edu> Message-ID: On Aug 15, 2008, at 1:11 AM, Eli Barzilay wrote: > Actually, there might be a way to get what you want (it wasn't clear > if this is what you tried so apologies if you already did). > > The first step is to create a post-installer hook ... Ah! I didn't know about that. I was doing roughly the same thing at the end of the module itself. A minor problem is that it currently copies EVERYTHING from the PLaneT cache subdirectory, including "info.ss" which then shows up in the "Add Teachpack" dialogue as though it were a teachpack; I need to experiment to figure out exactly what needs to be copied. In the long run, it would be nice to have an info.ss field that decides where to put the thing, e.g. (define destination-finder (lambda () (build-path (find-system-path 'addon-dir) (string->path (version)) (string->path "collects") (string->path "installed-teachpacks")))) Or maybe (more flexible and more complex) several such hooks, one specifying where to put the .plt file, one specifying where to put the documentation, one specifying where to put the compiled code.... Stephen Bloch sbloch@adelphi.edu From atmamta at gmail.com Fri Aug 15 07:58:32 2008 From: atmamta at gmail.com (Atmam Ta) Date: Thu Mar 26 02:25:49 2009 Subject: [plt-scheme] missing gsl scientific libraries Message-ID: Hi, when I chose the language for my current project a few months ago I had some "must have" requirements in mind, like the language should have basic scientific computing support (matrix and linear algebra, fft, least squares fitting and some statistics packages). After scanning the Planet repository, I thought plt-scheme passes as it had an interface to the Gnu Scientific Library listed. Now I am very surprised to see that the mzgsl library contains only an interface to the random number generation sublibrary of GSL, and the science collection has less than half of the GSL functionality. Does anyone know of plt-scheme interace code to fft, linear algebra, least-squares fitting, and non-basic statistics? I can see that there is a "fit" function in the plot library for least squares fitting... Cheers, Atmam -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080815/15427292/attachment.html From sk at cs.brown.edu Fri Aug 15 08:52:45 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:25:49 2009 Subject: [plt-scheme] Re: new interactive programming material for beginners In-Reply-To: References: Message-ID: Yep. But you should read beyond page 1 before responding. The rest may be even more fascinating, or it may prove to not be fascinating at all. (-: From noelwelsh at gmail.com Fri Aug 15 09:04:21 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:25:49 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: References: Message-ID: On Fri, Aug 15, 2008 at 12:58 PM, Atmam Ta wrote: > Does anyone know of plt-scheme interace code to fft, linear algebra, > least-squares fitting, and non-basic statistics? I can see that there is a > "fit" function in the plot library for least squares fitting... plt-linalg has basic linear algebra. Don't know about fft, or least-squares, or what you mean by non-basic statistics. Basically, if you want libraries I'd recommend R, Octave, Matlab etc. If you want a better language then look at PLT Scheme, but be prepared to build more of the infrastructure (but this is fairly quick in my experience). N. From robert.matovinovic at web.de Fri Aug 15 09:17:11 2008 From: robert.matovinovic at web.de (Robert Matovinovic) Date: Thu Mar 26 02:25:49 2009 Subject: AW: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <932b2f1f0808141342o67f3a102rbe86b97f45fc7279@mail.gmail.com> Message-ID: <1D732610F2204CD6890642ADE593F3E0@IBMI> What I also found right now is that if words are not wrapped in editor buffer and you are somewhere in a long line where you don't see the next selection ctrl+g doesn't bring you there only the cursor jumps, which is confusing because you see in the find dialog editor there are matches but you don't get there. I checked out anchor search and find that I'm personally used to jump between selections which I have to work on mostly. So I don't see the advantage of the anchor without selection, but you might give me a hint. Feature request: What I like about the new find dialog is the count of matches. I had to use find extensively yesterday and noticed, what would be in addition very helpful, if you work on big files with a lot of matches, would be the number of the current match beneath it. Robert From m.douglas.williams at gmail.com Fri Aug 15 09:33:19 2008 From: m.douglas.williams at gmail.com (Doug Williams) Date: Thu Mar 26 02:25:50 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: References: Message-ID: In the science collection I have only 'ported' the parts of the GSL that I've needed for my own simulation and analysis work. Quite honestly, it's all I've had the bandwidth to do. I definitely agree that it would be nice to have more of it. Doug On Fri, Aug 15, 2008 at 7:04 AM, Noel Welsh wrote: > On Fri, Aug 15, 2008 at 12:58 PM, Atmam Ta wrote: > > Does anyone know of plt-scheme interace code to fft, linear algebra, > > least-squares fitting, and non-basic statistics? I can see that there is > a > > "fit" function in the plot library for least squares fitting... > > plt-linalg has basic linear algebra. Don't know about fft, or > least-squares, or what you mean by non-basic statistics. Basically, > if you want libraries I'd recommend R, Octave, Matlab etc. If you > want a better language then look at PLT Scheme, but be prepared to > build more of the infrastructure (but this is fairly quick in my > experience). > > N. > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080815/9c7d48c3/attachment.htm From robby at cs.uchicago.edu Fri Aug 15 10:02:35 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:25:50 2009 Subject: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <1D732610F2204CD6890642ADE593F3E0@IBMI> References: <932b2f1f0808141342o67f3a102rbe86b97f45fc7279@mail.gmail.com> <1D732610F2204CD6890642ADE593F3E0@IBMI> Message-ID: <932b2f1f0808150702t1bbf52f5xdddb6f33287e63a0@mail.gmail.com> On Fri, Aug 15, 2008 at 8:17 AM, Robert Matovinovic wrote: > What I also found right now is that if words are not wrapped in editor > buffer and you are somewhere in a long line where you don't see the next > selection ctrl+g doesn't bring you there only the cursor jumps, which is > confusing because you see in the find dialog editor there are matches but > you don't get there. Are you saying that you hit "control-g", there are matches, but you do not jump to the next match? That sounds like a bug. > I checked out anchor search and find that I'm personally used to jump > between selections which I have to work on mostly. So I don't see the > advantage of the anchor without selection, but you might give me a hint. I'm not quite getting this part. I think you might be suggesting a way to improve the search -- perhaps you can elaborate a little? > Feature request: > What I like about the new find dialog is the count of matches. I had to use > find extensively yesterday and noticed, what would be in addition very > helpful, if you work on big files with a lot of matches, would be the number > of the current match beneath it. You mean how many matches before and how many after the insertion point, as in "there are 5 matches after the insertion point"? Or do you mean the count, as in "the current section is the 3rd match" (which might not always be relevant, if nothing is selected). Robby From farr at MIT.EDU Fri Aug 15 10:18:43 2008 From: farr at MIT.EDU (Will Farr) Date: Thu Mar 26 02:25:50 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: References: Message-ID: <5C8609B1-70DA-48AB-8EC8-166BD90DAA38@mit.edu> Atmam, I wrote the mzgsl package, and, as Doug said with the science collection, I only wrapped the functionality I needed at the time. It was my hope that people who needed more from the GSL would add to the package as necessary. For linear algebra (i.e. bindings to LAPACK and BLAS), Noel encouraged you to take a look at the plt-linalg package, and I second that (I wrote that one, too, with some help from Noel and others). If you would like to wrap the GSL functionality you need, I would encourage you to add to the current mzgsl package. If you would like, I'd be happy to give you my Darcs repository for that code and pull patches back from you to add to PLaneT (i.e. if you don't want to be bothered with the details of releasing the code). PLT's foreign function interface is really easy to use (the existing mzgsl code should give you a good idea how it works, and, of course, the help- desk documentation is excellent); writing the initial version of the mzgsl package, which contained all the current functionality, took me about two hours. Will On Aug 15, 2008, at 7:58 AM, Atmam Ta wrote: > Hi, > > when I chose the language for my current project a few months ago I > had some "must have" requirements in mind, like the language should > have basic scientific computing support (matrix and linear algebra, > fft, least squares fitting and some statistics packages). > After scanning the Planet repository, I thought plt-scheme passes as > it had an interface to the Gnu Scientific Library listed. Now I am > very surprised to see that the mzgsl library contains only an > interface to the random number generation sublibrary of GSL, and the > science collection has less than half of the GSL functionality. > > Does anyone know of plt-scheme interace code to fft, linear algebra, > least-squares fitting, and non-basic statistics? I can see that > there is a "fit" function in the plot library for least squares > fitting... > > Cheers, > > Atmam > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From m.douglas.williams at gmail.com Fri Aug 15 10:48:24 2008 From: m.douglas.williams at gmail.com (Doug Williams) Date: Thu Mar 26 02:25:51 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: <5C8609B1-70DA-48AB-8EC8-166BD90DAA38@mit.edu> References: <5C8609B1-70DA-48AB-8EC8-166BD90DAA38@mit.edu> Message-ID: I took a different approach in the science collection. I actually reimplemented the code entirely in PLT Scheme. This is almost certainly slower than an FFI interface to the C code - but it is much faster in V4 where the JIT compiler deals with floating point directly. [Matthew can correct me if I got the details wrong there.] But, it allows me to better integrate with the (PLT) Scheme numerical hierarchy, error handling, etc. So, it takes me more on the order of a week to port a moderately complex unit of functionality. I avoided porting the linear algebra routines until I get a better underlying array abstraction implemented. I've already prototyped one that sits on top of SRFI 4 homogeneous vector types. [Basically a homogeneous array is mapped onto an appropriate vector type; array references can include various slicing operations, effecient reuse of underlying vectors (avoids copying), and array operations can also return slices, etc.] I also need to interface it with the new iterators in V4. But, I haven't been able to devote as much time to it as I'd like. Anyway, adding the appropriate FFI interfaces to Will's code base would be much quicker. If you, or anyone else, wants to add to the science collection, it is hosted on the Schematics project at Sourceforge. [Or, of course, the code is on PLaneT.] Doug On Fri, Aug 15, 2008 at 8:18 AM, Will Farr wrote: > Atmam, > > I wrote the mzgsl package, and, as Doug said with the science collection, I > only wrapped the functionality I needed at the time. It was my hope that > people who needed more from the GSL would add to the package as necessary. > > For linear algebra (i.e. bindings to LAPACK and BLAS), Noel encouraged you > to take a look at the plt-linalg package, and I second that (I wrote that > one, too, with some help from Noel and others). > > If you would like to wrap the GSL functionality you need, I would encourage > you to add to the current mzgsl package. If you would like, I'd be happy to > give you my Darcs repository for that code and pull patches back from you to > add to PLaneT (i.e. if you don't want to be bothered with the details of > releasing the code). PLT's foreign function interface is really easy to use > (the existing mzgsl code should give you a good idea how it works, and, of > course, the help-desk documentation is excellent); writing the initial > version of the mzgsl package, which contained all the current functionality, > took me about two hours. > > Will > > > > On Aug 15, 2008, at 7:58 AM, Atmam Ta wrote: > > Hi, >> >> when I chose the language for my current project a few months ago I had >> some "must have" requirements in mind, like the language should have basic >> scientific computing support (matrix and linear algebra, fft, least squares >> fitting and some statistics packages). >> After scanning the Planet repository, I thought plt-scheme passes as it >> had an interface to the Gnu Scientific Library listed. Now I am very >> surprised to see that the mzgsl library contains only an interface to the >> random number generation sublibrary of GSL, and the science collection has >> less than half of the GSL functionality. >> >> Does anyone know of plt-scheme interace code to fft, linear algebra, >> least-squares fitting, and non-basic statistics? I can see that there is a >> "fit" function in the plot library for least squares fitting... >> >> Cheers, >> >> Atmam >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080815/c4d7385e/attachment.html From matthias at ccs.neu.edu Fri Aug 15 10:50:58 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:51 2009 Subject: [plt-scheme] Re: new interactive programming material for beginners In-Reply-To: References: Message-ID: <297BCE29-2816-4BCA-ACE5-F0C48D285E9C@ccs.neu.edu> It's more like a resumption: http://www.ccs.neu.edu/home/matthias/HtDP/Prologue/book.html We have been teaching with world for 3+ years now. -- Matthias On Aug 15, 2008, at 4:49 AM, Benjamin L.Russell wrote: > On Thu, 14 Aug 2008 20:03:01 -0400, "Shriram Krishnamurthi" > wrote: > >> Dear PLT Users, >> >> As some of you know, we have been working on a new way of writing >> interactive applications, such as games, using just pure functional >> programming. We call this the World style, and it is embodied in the >> world.ss Teachpack included in the DrScheme distribution. >> >> In response to demand, we are creating extended materials on this >> style of programming: >> >> http://world.cs.brown.edu/ > > Fascinating! The following sentence on page 1 of Chapter 1: > >> DrScheme treats images just like numbers, symbols, and other >> Scheme values, which means you can >> write functions that consume and produce them. > > reminded me of the treatment of images as parameters to functions in > the following essay: > > 1 Why Computer Science Doesn't Matter > http://www.ccs.neu.edu/home/matthias/essays/not-matter.html > > which was recently introduced in this forum by Matthias Felleisen in > the following thread: > > [plt-scheme] Re: More pedagogic stuff: > http://list.cs.brown.edu/pipermail/plt-scheme/2008-August/026430.html > > Correct me if I am wrong, but is this a continuation? ;-) > > -- Benjamin L. Russell > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From atmamta at gmail.com Fri Aug 15 11:20:40 2008 From: atmamta at gmail.com (Atmam Ta) Date: Thu Mar 26 02:25:52 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: References: <5C8609B1-70DA-48AB-8EC8-166BD90DAA38@mit.edu> Message-ID: thanks for the replies, and the packages that you contributed. sorry for airing my temporary frustration - I should have paid more attention to what was in that gsl port back in the day. I would have chosen plt-scheme anyway - I hardly consider octave, matlab, c, etc. languages... If I end up expanding plt, I will definitely post the result to Planet. On Fri, Aug 15, 2008 at 4:48 PM, Doug Williams wrote: > I took a different approach in the science collection. I actually > reimplemented the code entirely in PLT Scheme. This is almost certainly > slower than an FFI interface to the C code - but it is much faster in V4 > where the JIT compiler deals with floating point directly. [Matthew can > correct me if I got the details wrong there.] But, it allows me to better > integrate with the (PLT) Scheme numerical hierarchy, error handling, etc. > So, it takes me more on the order of a week to port a moderately complex > unit of functionality. > > I avoided porting the linear algebra routines until I get a better > underlying array abstraction implemented. I've already prototyped one that > sits on top of SRFI 4 homogeneous vector types. [Basically a homogeneous > array is mapped onto an appropriate vector type; array references can > include various slicing operations, effecient reuse of underlying vectors > (avoids copying), and array operations can also return slices, etc.] I also > need to interface it with the new iterators in V4. But, I haven't been able > to devote as much time to it as I'd like. > > Anyway, adding the appropriate FFI interfaces to Will's code base would be > much quicker. > > If you, or anyone else, wants to add to the science collection, it is > hosted on the Schematics project at Sourceforge. [Or, of course, the code > is on PLaneT.] > > Doug > > > On Fri, Aug 15, 2008 at 8:18 AM, Will Farr wrote: > >> Atmam, >> >> I wrote the mzgsl package, and, as Doug said with the science collection, >> I only wrapped the functionality I needed at the time. It was my hope that >> people who needed more from the GSL would add to the package as necessary. >> >> For linear algebra (i.e. bindings to LAPACK and BLAS), Noel encouraged you >> to take a look at the plt-linalg package, and I second that (I wrote that >> one, too, with some help from Noel and others). >> >> If you would like to wrap the GSL functionality you need, I would >> encourage you to add to the current mzgsl package. If you would like, I'd >> be happy to give you my Darcs repository for that code and pull patches back >> from you to add to PLaneT (i.e. if you don't want to be bothered with the >> details of releasing the code). PLT's foreign function interface is really >> easy to use (the existing mzgsl code should give you a good idea how it >> works, and, of course, the help-desk documentation is excellent); writing >> the initial version of the mzgsl package, which contained all the current >> functionality, took me about two hours. >> >> Will >> >> >> >> On Aug 15, 2008, at 7:58 AM, Atmam Ta wrote: >> >> Hi, >>> >>> when I chose the language for my current project a few months ago I had >>> some "must have" requirements in mind, like the language should have basic >>> scientific computing support (matrix and linear algebra, fft, least squares >>> fitting and some statistics packages). >>> After scanning the Planet repository, I thought plt-scheme passes as it >>> had an interface to the Gnu Scientific Library listed. Now I am very >>> surprised to see that the mzgsl library contains only an interface to the >>> random number generation sublibrary of GSL, and the science collection has >>> less than half of the GSL functionality. >>> >>> Does anyone know of plt-scheme interace code to fft, linear algebra, >>> least-squares fitting, and non-basic statistics? I can see that there is a >>> "fit" function in the plot library for least squares fitting... >>> >>> Cheers, >>> >>> Atmam >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>> >> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080815/145d950b/attachment.htm From matthias at ccs.neu.edu Fri Aug 15 11:25:03 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:25:52 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: References: <5C8609B1-70DA-48AB-8EC8-166BD90DAA38@mit.edu> Message-ID: <0D599712-C925-41B9-A739-88DEE0317C8D@ccs.neu.edu> On Aug 15, 2008, at 11:20 AM, Atmam Ta wrote: > If I end up expanding plt, I will definitely post the result to > Planet. Thanks! This is exactly how you improve your favorite tools. -- Matthias -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080815/77089472/attachment.html From dvanhorn at ccs.neu.edu Fri Aug 15 12:59:40 2008 From: dvanhorn at ccs.neu.edu (David Van Horn) Date: Thu Mar 26 02:25:52 2009 Subject: [plt-scheme] compiling from svn: undef'd symbol Message-ID: <48A5B5FC.9060506@ccs.neu.edu> I just did an svn up; cd src; make, and got the following error: make mzschemecgc mkdir -p PLT_MzScheme.framework/Versions/4.1.0.1 gcc -o PLT_MzScheme.framework/Versions/4.1.0.1/PLT_MzScheme -framework CoreFoundation -dynamiclib -all_load libmzscheme.a libmzgc.a -ldl -lm -liconv ld: Undefined symbols: _scheme_init_place /usr/bin/libtool: internal link edit command failed make[4]: *** [PLT_MzScheme.framework/Versions/4.1.0.1/PLT_MzScheme] Error 1 Indeed it looks like _scheme_init_place is not defined in libmzscheme.a: $ nm mzscheme/libmzscheme.a | grep 'scheme_init_place' U _scheme_init_place $ uname -a Darwin david-van-horns-computer.local 8.10.1 Darwin Kernel Version 8.10.1: Wed May 23 16:33:00 PDT 2007; root:xnu-792.22.5~1/RELEASE_I386 i386 i386 Is this a bug or have I done something wrong? Let me know if I can provide any further info. David From mflatt at cs.utah.edu Fri Aug 15 13:00:59 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:25:53 2009 Subject: [plt-scheme] compiling from svn: undef'd symbol In-Reply-To: <48A5B5FC.9060506@ccs.neu.edu> References: <48A5B5FC.9060506@ccs.neu.edu> Message-ID: <20080815170059.DAF2B6500BE@mail-svr1.cs.utah.edu> Did you re-run `configure' before `make'? At Fri, 15 Aug 2008 12:59:40 -0400, David Van Horn wrote: > I just did an svn up; cd src; make, and got the following error: > > make mzschemecgc > mkdir -p PLT_MzScheme.framework/Versions/4.1.0.1 > gcc -o PLT_MzScheme.framework/Versions/4.1.0.1/PLT_MzScheme -framework > CoreFoundation -dynamiclib -all_load libmzscheme.a libmzgc.a -ldl -lm > -liconv > ld: Undefined symbols: > _scheme_init_place > /usr/bin/libtool: internal link edit command failed > make[4]: *** [PLT_MzScheme.framework/Versions/4.1.0.1/PLT_MzScheme] Error 1 > > Indeed it looks like _scheme_init_place is not defined in libmzscheme.a: > > $ nm mzscheme/libmzscheme.a | grep 'scheme_init_place' > U _scheme_init_place > > $ uname -a > Darwin david-van-horns-computer.local 8.10.1 Darwin Kernel Version > 8.10.1: Wed May 23 16:33:00 PDT 2007; root:xnu-792.22.5~1/RELEASE_I386 > i386 i386 > > Is this a bug or have I done something wrong? Let me know if I can > provide any further info. > > David > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From dvanhorn at ccs.neu.edu Fri Aug 15 13:08:37 2008 From: dvanhorn at ccs.neu.edu (David Van Horn) Date: Thu Mar 26 02:25:53 2009 Subject: [plt-scheme] compiling from svn: undef'd symbol In-Reply-To: <20080815170059.DAF2B6500BE@mail-svr1.cs.utah.edu> References: <48A5B5FC.9060506@ccs.neu.edu> <20080815170059.DAF2B6500BE@mail-svr1.cs.utah.edu> Message-ID: <48A5B815.5040405@ccs.neu.edu> Matthew Flatt wrote: > Did you re-run `configure' before `make'? Nope. That did it, thanks! David From robert.matovinovic at web.de Fri Aug 15 13:29:06 2008 From: robert.matovinovic at web.de (Robert Matovinovic) Date: Thu Mar 26 02:25:53 2009 Subject: AW: [plt-scheme] Replace & Find in v4.1 In-Reply-To: <932b2f1f0808150702t1bbf52f5xdddb6f33287e63a0@mail.gmail.com> Message-ID: <5875040B90BF4D49B08B784E31C80395@IBMI> See below > -----Urspr?ngliche Nachricht----- > Von: robby.findler@gmail.com [mailto:robby.findler@gmail.com] > Im Auftrag von Robby Findler > Gesendet: Freitag, 15. August 2008 16:03 > An: Robert Matovinovic > Cc: plt-scheme@list.cs.brown.edu > Betreff: Re: [plt-scheme] Replace & Find in v4.1 > > > On Fri, Aug 15, 2008 at 8:17 AM, Robert Matovinovic > wrote: > > What I also found right now is that if words are not > wrapped in editor > > buffer and you are somewhere in a long line where you don't see the > > next selection ctrl+g doesn't bring you there only the > cursor jumps, > > which is confusing because you see in the find dialog > editor there are > > matches but you don't get there. > > Are you saying that you hit "control-g", there are matches, > but you do not jump to the next match? That sounds like a bug. > Not exactly but similar: I had a very long line which I copied into the editor(actually it was a word list for completions which I copied from standard output). I was looking for something right at the end of the line and then I searched for something. There was only one match right at the beginning of the line. So while I was pressing ctrl+g or ctrl+f I saw that the cursor was jumping away, but the window wasn't scrolled to the left so that I could see the match. > > I checked out anchor search and find that I'm personally > used to jump > > between selections which I have to work on mostly. So I > don't see the > > advantage of the anchor without selection, but you might give me a > > hint. > > I'm not quite getting this part. I think you might be > suggesting a way to improve the search -- perhaps you can > elaborate a little? Ok, I analyzed my search behavior in light of v4.1. Most of the time when I search I want to find something and not see how things are distributed over the file. That means, it is nice to see where the matches are, but basically it is not necessary to see the distribution of matches. What I like about the circles is that they let you jump faster with the eye from match to match. But back to search. I initially expected to have selected one match after typing a search string, best the next to the cursor. Because the matches are circled, so they are found and one is already selected I assumed, as it has been before the introduction of circling in search. So I was wondering why it wasn't like that. That is what I needed. Then I'm also used to use ctrl+f for find again as well and was confused when only ctrl+g brought me forward. And further something deep in my brain was confused by the normal selection (blue) and the round tan selection which changed seemingly arbitrarily using ctrl+f,g,r. They both mean the same but appear very different in shape and color. So somewhere in my brain I asked myself - is it really the same thing? And I found that I react strongly to such difference, that I would like to have no different appearance of selections, if they carry the same information. Very often I look only for one special thing, so I want to get there with the least possible effort. That means something like ctrl+f for the dialog and an incremental search by typing in the search string. If I'm there another click or ctrl+r for replace and find again. But I'm also used to a non incremental search making another ctrl+f, ctrl+g or button click necessary to get to the next match. I would suggest this: 2 search modes Mode 1, incremental, type in a search string and during that the cursor jumps to the next match and selects it so that replace works right away Mode 2, absolute, type in a search string, nothing happens, pressing the find button jumps to the next match (either from the cursor, if no match is selected yet, or from the actual match) and selects it. Replace and find again works as usual. These modes are similar to those we had in earlier versions with the undocked and docked search dialog window. To change the search mode via the window position is not very intuitive so I only learned the difference by chance. But actually I think search modes are a kind of personal preference (I mostly would use Mode 1), so it should be selectable in either Preferences/Editing/General, or by a checkbox in the search dialog. The anchor search seems to me similar to Mode 1, where the anchor is a selection. The circling of matches is a nice feature, to get an idea where the matches are, but I also see it as a personal preference which should be selectable in Preferences/Editing/General. This is a lot but I hope it helps. I found it very interesting being confronted with a feature I thought I knew and how many assumptions I made about it about which I wasn't aware. > > > Feature request: > > What I like about the new find dialog is the count of > matches. I had > > to use find extensively yesterday and noticed, what would be in > > addition very helpful, if you work on big files with a lot > of matches, > > would be the number of the current match beneath it. > > You mean how many matches before and how many after the > insertion point, as in "there are 5 matches after the > insertion point"? Or do you mean the count, as in "the > current section is the 3rd match" (which might not always be > relevant, if nothing is selected). I thought of something like "there are 5 matches after the insertion point/the current match". > > Robby > From eli at barzilay.org Fri Aug 15 13:48:26 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:53 2009 Subject: [plt-scheme] Re: how do you include documentation with a teachpack or planet collection? In-Reply-To: References: <932b2f1f0708260542p64f0e44cr1c9ef2189f9809c5@mail.gmail.com> <932b2f1f0708270508x583c0f22w63ce2af1c392b670@mail.gmail.com> <47C62BE3-A51E-42E0-87D0-759DB5B22010@adelphi.edu> <932b2f1f0808142026h7ae49480j268ad6e89d2c6325@mail.gmail.com> <18597.4119.916172.762905@arabic.ccs.neu.edu> Message-ID: <18597.49514.806569.630316@arabic.ccs.neu.edu> On Aug 15, Stephen Bloch wrote: > > On Aug 15, 2008, at 1:11 AM, Eli Barzilay wrote: > > > Actually, there might be a way to get what you want (it wasn't clear > > if this is what you tried so apologies if you already did). > > > > The first step is to create a post-installer hook ... > > Ah! I didn't know about that. I was doing roughly the same thing at > the end of the module itself. A minor problem is that it currently > copies EVERYTHING from the PLaneT cache subdirectory, including > "info.ss" which then shows up in the "Add Teachpack" dialogue as > though it were a teachpack; I need to experiment to figure out > exactly what needs to be copied. Don't copy everything... The code I had installed a stub file that reprovides stuff from your real package for exactly that purpose. This has many advantages: first, there's no need to choose what needs to be copied -- the package itself can have anything you want, and the stub just refers to that; second, it's easy to identify when the file that you want to write is "not yours" which will be a good feature to have if/when you want other people to try it; third, the stub file is very simple so you don't need to update it -- it gets "updated" indirectly when the planet package is updated. > In the long run, it would be nice to have an info.ss field that > decides where to put the thing, e.g. > > (define destination-finder > [...] Specifically, this will not work, because the system expects to look for collections in specific places. For irregular needs (like what the package developer needs) there's planet. Writing something directly to the installed teachpacks directory is also an irregular thing to do -- which is yet another reason I limited the "damage" to a stub file -- this way when the teachpack facility changes to whatever (as Robby mentioned) you won't need to change your code (my guess is that you'll either add a field to the info file naming the teachpacks, or you'll just change the place where the stub goes). If you copy more files, you might end up with code that depends on the new placement of these files, and this might mess things up when such a change to drscheme happens. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From gregory.woodhouse at gmail.com Fri Aug 15 15:56:34 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:25:54 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: References: Message-ID: On Aug 15, 2008, at 6:04 AM, Noel Welsh wrote: > plt-linalg has basic linear algebra. Don't know about fft, or > least-squares, or what you mean by non-basic statistics. Basically, > if you want libraries I'd recommend R, Octave, Matlab etc. If you > want a better language then look at PLT Scheme, but be prepared to > build more of the infrastructure (but this is fairly quick in my > experience). > > N. A good linear algebra package is the foundation upon which numerical packages ultimately rest. The reason is that many algorithms ultimately boil down to solving linear systems. "It is never too late to become reasonable and wise; but if the insight comes too late, there is always more difficulty in starting the change." -- Immanuel Kant http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080815/74521474/attachment.htm From dherman at ccs.neu.edu Fri Aug 15 19:30:15 2008 From: dherman at ccs.neu.edu (Dave Herman) Date: Thu Mar 26 02:25:54 2009 Subject: [plt-scheme] small API suggestion Message-ID: <48A61187.8080703@ccs.neu.edu> It's hard to test programs that use `syntax-local-introduce' without a predicate for checking for the current mark. Here's a simple API for testing for the presence of the current mark: ;; syntax-local-input? :: syntax -> boolean (define (syntax-local-input? stx) (bound-identifier=? (datum->syntax stx 'foo) (datum->syntax (current-transformer-input) 'foo))) (This is assuming a built-in function current-transformer-input :: -> syntax which returns the current syntax object that is the argument of the current transformer. Obviously this helper function wouldn't be necessary for a native implementation.) The expected behavior would be that for any syntax object stx, (syntax-local-input? stx) => (not (syntax-local-input? (syntax-local-introduce stx))) Does this seem like a good idea? I think it'd be useful. If nothing else, at least it would be helpful for understanding the behavior of `syntax-local-introduce'. Thanks, Dave From neil at neilvandyke.org Sat Aug 16 01:27:53 2008 From: neil at neilvandyke.org (Neil Van Dyke) Date: Thu Mar 26 02:25:55 2009 Subject: [plt-scheme] setup-plt --mode errortrace standard-module-name-resolver: cycle in loading In-Reply-To: <20080801152020.C2FEE6500B7@mail-svr1.cs.utah.edu> References: <4892D2BE.8030906@neilvandyke.org> <20080801132544.339EC6500C7@mail-svr1.cs.utah.edu> <48931ADE.3030208@neilvandyke.org> <20080801152020.C2FEE6500B7@mail-svr1.cs.utah.edu> Message-ID: <48A66559.5030509@neilvandyke.org> Matthew, this afterthought of yours has been a big win for us. Since we started running our system with JIT disabled, we've consistently gotten very helpful trace info without needing Errortrace. Thanks again. (Not that I discourage anyone from using the JIT. Our system does some unusual things that I imagine might contribute to the poor error traces when combined with JIT. I will look into this in our system when time permits.) Neil Matthew Flatt wrote at 08/01/2008 11:20 AM: > At Fri, 01 Aug 2008 10:17:02 -0400, Neil Van Dyke wrote: > >> In the interim, is there anything I can do to improve the backtraces >> when debugging >> > > One more thought: it sometimes helps to disable the JIT. The JIT and > the bytecode interpreter compute stack traces in different ways, and > they usually produce slightly different results. > > Matthew > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080816/9a51607b/attachment.html From marek at xivilization.net Sat Aug 16 05:53:22 2008 From: marek at xivilization.net (Marek Kubica) Date: Thu Mar 26 02:25:55 2009 Subject: [plt-scheme] Timedeltas for PLT? Message-ID: <20080816115322.26563787@halmanfloyd.lan.local> Hi, I am trying to write some small non-trivial programs in Scheme and while looking for stuff that might help me I ran across PLT Reference Chapter 14.6, Time, . Now, I'm quite used to Pythons datetime which has two constructs that are useful to me: datetime.strptime and the timedelta. Is there something like this also for PLT or do I have to create my own library[1]? regards, Marek [1] that I could upload to PLaneT if it proves useful From eli at barzilay.org Sat Aug 16 07:06:49 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:55 2009 Subject: [plt-scheme] Timedeltas for PLT? In-Reply-To: <20080816115322.26563787@halmanfloyd.lan.local> References: <20080816115322.26563787@halmanfloyd.lan.local> Message-ID: <18598.46281.739067.165796@arabic.ccs.neu.edu> On Aug 16, Marek Kubica wrote: > Hi, > > I am trying to write some small non-trivial programs in Scheme and > while looking for stuff that might help me I ran across PLT Reference > Chapter 14.6, Time, . > Now, I'm quite used to Pythons datetime > which has two > constructs that are useful to me: datetime.strptime and the timedelta. > Is there something like this also for PLT or do I have to create my own > library[1]? Looks like both are covered by srfi-19. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From gregory.woodhouse at gmail.com Sat Aug 16 17:19:34 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:25:56 2009 Subject: [plt-scheme] Problem with contract in module Message-ID: <915060D8-C602-449D-8220-61C91CA36189@gmail.com> This code will not compile #lang scheme (require scheme/date) (provide log-to-console) (provide/contract [log-to-console (-> logger? (one-of/c 'debug 'info 'warning 'error 'fatal) procedure?)]) (define (log-to-console logger level) ...) The error is module: identifier already provided (as a different binding) in: log- to-console On the other hand, if I comment out the contract, it works as expected. Am I using the contract facility correctly? "In the human mind, one-sidedness has always been the rule and many-sidedness the exception. Hence, even in revolutions of thought, one part of the truth usually sets while another rises." --John Stuart Mill http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080816/601b5d89/attachment.htm From robert.matovinovic at web.de Sat Aug 16 17:31:11 2008 From: robert.matovinovic at web.de (Robert Matovinovic) Date: Thu Mar 26 02:25:56 2009 Subject: AW: [plt-scheme] Completions from distinct manuals In-Reply-To: <932b2f1f0808151319m510dac70w9a0f5803f829497@mail.gmail.com> Message-ID: <44769BDDD74D40599E48BD68AC7A726A@IBMI> I tried what you wrote, but can't confirm that it works. Actually I have the same behavior as before. Obviously I wasn't clear enough about my test phase editions to get-mytest-manual-keywords in mytest-tool: Only the first line of the of the following block which is an excerpt of get-mytest-manual-keywords is the real one. All others are tests what happens to the word list with other collections. The last one is the "all-words" option which works anyway. So I assume you did not comment out these parts, which yields in a completions list with all words including that of my collection. As I already mentioned that I know works. Otherwise I can't explain to myself why it worked for you. (set! words (text:get-completions/manuals (list 'mytest))) ; (dbgprn "~n~nmytest words:~n~a" words) ; (set! words (text:get-completions/manuals (list 'mysterx 'mytest))) ; (dbgprn "~n~nmysterx and mytest words:~n~a" words) ; (set! words (text:get-completions/manuals (list 'frtime))) ; (dbgprn "~n~nfrtime words:~n~a" words) ; (set! words (text:get-completions/manuals (list 'mysterx))) ; (dbgprn "~n~nmysterx words:~n~a" words) ; (set! words (text:get-completions/manuals #f)) ; (dbgprn "~n~nall words:~n~a" words) So there is still something to solve. I'd appreciate if you could look at it again. I'll be away for the next 14 days so there is no hurry. Thank you very much Robert > -----Urspr?ngliche Nachricht----- > Von: robby.findler@gmail.com [mailto:robby.findler@gmail.com] > Im Auftrag von Robby Findler > Gesendet: Freitag, 15. August 2008 22:19 > An: Robert Matovinovic > Cc: Matthew Flatt > Betreff: Re: [plt-scheme] Completions from distinct manuals > > > Thanks. It looks like you've run afoul of the wrong > place/missing @defmodule declaration problem in Scribble. I'm > not sure how, but there should probably be a better error > message for this case. Anyways, this version of mytest.scrbl > works. I'll also note that, when you use @defmodule, you'll > see it underline the module in red when it is not linked up > properly, which is also a useful clue sometimes. > > #lang scribble/doc > @(require "common.ss") > @title[#:style 'toc]{@bold{MrMytest}: A DrScheme Interface to > MyTest} @defmodule[mytest/mytest-elk] > > @local-table-of-contents[#:style 'immediate-only] > > @defform[(mytest-cmd args)] > > @index-section[] > > > hth, > Robby > > On Fri, Aug 15, 2008 at 8:17 AM, Robert Matovinovic > wrote: > > It took a while to strip things down for a demo, but I'm > grateful that > > you will have a look at it. In mytest-tool.ss there is a function > > get-mytest-manual-keywords which load completion lists. For demo > > purposes it loads lists from several collections and prints > the lists > > to standard output. You will see that text:get-completions/manuals > > gives back all the lists except the one for 'mytest. I combined for > > example mysterx and mytest, but only for #f (all words)the single > > command from my language mytest-cmd is in the list and will > be shown > > if it is a completion after pressing ctrl+/. You can check > that after > > compilation running DrScheme and select MyTest Compatible Mode as > > language. > > > > BTW I found that F1 for help only works if the cursor is in > front or > > inside a word but not at the end. I find that somewhat annoying > > because I mostly use it that way. If the cursor is at the end of a > > word only the main page of Help Desk opens with no further > actions. If > > that's by purpose, I'd like to understand why. > > > > Robert > > > From czhu at cs.utah.edu Sat Aug 16 17:55:04 2008 From: czhu at cs.utah.edu (Chongkai Zhu) Date: Thu Mar 26 02:25:57 2009 Subject: [plt-scheme] Problem with contract in module In-Reply-To: <915060D8-C602-449D-8220-61C91CA36189@gmail.com> References: <915060D8-C602-449D-8220-61C91CA36189@gmail.com> Message-ID: <48A74CB8.1090100@cs.utah.edu> If you want to provide `log-to-console' with the contract, then there is no need to have the `(provide log-to-console)' line. `provide/contract' provides it with a contract. The error message means you provided ` log-to-console' twice, once with contract and once without. Chongkai Woodhouse Gregory wrote: > This code will not compile > > #lang scheme > > (require scheme/date) > > (provide log-to-console) > > (provide/contract > [log-to-console (-> logger? > (one-of/c 'debug 'info 'warning 'error 'fatal) > procedure?)]) > (define (log-to-console logger level) > > ...) > > > The error is > > module: identifier already provided (as a different binding) in: > log-to-console > > On the other hand, if I comment out the contract, it works as > expected. Am I using the contract facility correctly? > > > "In the human mind, one-sidedness has > always been the rule and many-sidedness the > exception. Hence, even in revolutions of > thought, one part of the truth usually sets while > another rises." > --John Stuart Mill > > http://www.gwoodhouse.com > http://GregWoodhouse.ImageKind.com > > > > > > ------------------------------------------------------------------------ > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From gregory.woodhouse at gmail.com Sat Aug 16 18:30:41 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:25:57 2009 Subject: [plt-scheme] A couple of contract questions Message-ID: <8F043C53-38F9-40D7-BB5B-CEFD41371B22@gmail.com> How do I write a contract for a function that takes no arguments (i.e., a thunk)? Is it possible to write a contract specifying that the return value is a function of particular shape? Ideally, I'd like to be able to write something like (-> integer? (-> integer? integer?)) for a function like (lambda (x) (lambda (y) (+ x y))) but I don't know if that's possible. (Instead, I've just used procedure? for the range.) "Mathematics is the science of patterns." --Lynn Arthur Steen, 1988 http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080816/f0c91631/attachment.html From jadudm at gmail.com Sat Aug 16 18:58:14 2008 From: jadudm at gmail.com (Matt Jadud) Date: Thu Mar 26 02:25:57 2009 Subject: [plt-scheme] A couple of contract questions In-Reply-To: <8F043C53-38F9-40D7-BB5B-CEFD41371B22@gmail.com> References: <8F043C53-38F9-40D7-BB5B-CEFD41371B22@gmail.com> Message-ID: Hi Gregory, On Sat, Aug 16, 2008 at 6:30 PM, Woodhouse Gregory wrote: > How do I write a contract for a function that takes no arguments (i.e., a > thunk)? (define/contract foo (-> number?) (lambda () 42)) > Is it possible to write a contract specifying the return value > for a function like > (lambda (x) (lambda (y) (+ x y))) (define/contract bar (-> (-> number? number?)) (lambda () (lambda (n) 42))) Or, if you prefer, (define/contract greg (-> number? (-> number? number?)) (lambda (x) (lambda (y) (+ x y)))) > ((greg 4) 2) 6 > ((greg 4) 'two) . . 5:4: 5:3 broke the contract (-> number? (-> number? number?)) on greg; expected , given: two You can be more specific: (define/contract specific-greg (-> (and/c number? even?) (-> (and/c number? odd?) number?)) (lambda (x) (lambda (y) (+ x y)))) > ((specific-greg 2) 3) 5 > ((specific-greg 3) 2) . . 5:4: 5:3 broke the contract (-> (and/c number? even?) (-> (and/c number? odd?) number?)) on specific-greg; expected <(and/c number? even?)>, given: 3 I think I'm using 402 under OSX. Cheers, Matt From marek at xivilization.net Sat Aug 16 19:48:59 2008 From: marek at xivilization.net (Marek Kubica) Date: Thu Mar 26 02:25:57 2009 Subject: [plt-scheme] Timedeltas for PLT? In-Reply-To: <18598.46281.739067.165796@arabic.ccs.neu.edu> References: <20080816115322.26563787@halmanfloyd.lan.local> <18598.46281.739067.165796@arabic.ccs.neu.edu> Message-ID: <20080817014859.3e00720a@halmanfloyd.lan.local> On Sat, 16 Aug 2008 07:06:49 -0400 Eli Barzilay wrote: > > I am trying to write some small non-trivial programs in Scheme and > > while looking for stuff that might help me I ran across PLT > > Reference Chapter 14.6, Time, > > . Now, I'm quite > > used to Pythons datetime > > which has two > > constructs that are useful to me: datetime.strptime and the > > timedelta. Is there something like this also for PLT or do I have > > to create my own library[1]? > > Looks like both are covered by srfi-19. Yeah, looks fine, thanks. Now that I do not have to reinvent poorly I can start to write my poor non-reinvented programs :) Btw: Somehow the PLT documentation search does not find the SFRI documentation. The search function is cool, but somehow it does not (yet) find all useful things that are documented. regards, Marek From eli at barzilay.org Sat Aug 16 21:54:11 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:25:58 2009 Subject: [plt-scheme] Timedeltas for PLT? In-Reply-To: <20080817014859.3e00720a@halmanfloyd.lan.local> References: <20080816115322.26563787@halmanfloyd.lan.local> <18598.46281.739067.165796@arabic.ccs.neu.edu> <20080817014859.3e00720a@halmanfloyd.lan.local> Message-ID: <18599.33987.83104.285645@arabic.ccs.neu.edu> On Aug 17, Marek Kubica wrote: > On Sat, 16 Aug 2008 07:06:49 -0400 > Eli Barzilay wrote: > > > > I am trying to write some small non-trivial programs in Scheme and > > > while looking for stuff that might help me I ran across PLT > > > Reference Chapter 14.6, Time, > > > . Now, I'm quite > > > used to Pythons datetime > > > which has two > > > constructs that are useful to me: datetime.strptime and the > > > timedelta. Is there something like this also for PLT or do I have > > > to create my own library[1]? > > > > Looks like both are covered by srfi-19. > > Yeah, looks fine, thanks. Now that I do not have to reinvent poorly > I can start to write my poor non-reinvented programs :) > > Btw: Somehow the PLT documentation search does not find the SFRI > documentation. The search function is cool, but somehow it does not > (yet) find all useful things that are documented. I just entered "date string" and it found it -- what did you search for, and which entry was not in the results? -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From robby at cs.uchicago.edu Sat Aug 16 22:36:30 2008 From: robby at cs.uchicago.edu (robby@cs.uchicago.edu) Date: Thu Mar 26 02:25:58 2009 Subject: [plt-scheme] A couple of contract questions In-Reply-To: References: <8F043C53-38F9-40D7-BB5B-CEFD41371B22@gmail.com> Message-ID: <932b2f1f0808161936v6e940f84g288af9c913e24344@mail.gmail.com> Let me also reccomend the chapter on contracts in the Guide. Robby On 8/16/08, Matt Jadud wrote: > Hi Gregory, > > On Sat, Aug 16, 2008 at 6:30 PM, Woodhouse Gregory > wrote: >> How do I write a contract for a function that takes no arguments (i.e., a >> thunk)? > > (define/contract foo > (-> number?) > (lambda () 42)) > >> Is it possible to write a contract specifying the return value >> for a function like >> (lambda (x) (lambda (y) (+ x y))) > > (define/contract bar > (-> (-> number? number?)) > (lambda () (lambda (n) 42))) > > Or, if you prefer, > > (define/contract greg > (-> number? (-> number? number?)) > (lambda (x) (lambda (y) (+ x y)))) > >> ((greg 4) 2) > 6 >> ((greg 4) 'two) > . . 5:4: 5:3 broke the contract > (-> number? (-> number? number?)) > on greg; expected , given: two > > You can be more specific: > > (define/contract specific-greg > (-> (and/c number? even?) (-> (and/c number? odd?) number?)) > (lambda (x) (lambda (y) (+ x y)))) > >> ((specific-greg 2) 3) > 5 >> ((specific-greg 3) 2) > . . 5:4: 5:3 broke the contract > (-> > (and/c number? even?) > (-> (and/c number? odd?) number?)) > on specific-greg; expected <(and/c number? even?)>, given: 3 > > I think I'm using 402 under OSX. > > Cheers, > Matt > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From gregory.woodhouse at gmail.com Sat Aug 16 23:05:00 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:25:58 2009 Subject: [plt-scheme] A couple of contract questions In-Reply-To: <932b2f1f0808161936v6e940f84g288af9c913e24344@mail.gmail.com> References: <8F043C53-38F9-40D7-BB5B-CEFD41371B22@gmail.com> <932b2f1f0808161936v6e940f84g288af9c913e24344@mail.gmail.com> Message-ID: <2C2800F8-26A3-4EDA-BCDB-E2093F199B9C@gmail.com> On Aug 16, 2008, at 7:36 PM, robby@cs.uchicago.edu wrote: > Let me also reccomend the chapter on contracts in the Guide. > > Robby Well, I was reading through the guide and never found anything but "any" in the final (range) position for -> . I may ell have missed it. "Life can only be understood going backwards, but it must be lived going forwards." --S?ren Kierkegaard http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080816/fc4e72a5/attachment.htm From sverrir.valgeirsson at gmail.com Sun Aug 17 02:50:24 2008 From: sverrir.valgeirsson at gmail.com (Sverrir Valgeirsson) Date: Thu Mar 26 02:25:59 2009 Subject: [plt-scheme] Problem with Create Executable (Win XP) Message-ID: Hi. I'm using DrScheme 4.1 for writing a very simple MrEd program. The program works well when run from DrScheme, but when I've done a "Create Executable" and run the resulting file I get an error message saying: "cddr: expects argument of type ; given ("#f")" and then the program exits. I never use cddr in my program so I don't know where this comes from. Any ideas? BR Sverrir -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080817/d2b6d47a/attachment.html From marek at xivilization.net Sun Aug 17 06:33:06 2008 From: marek at xivilization.net (Marek Kubica) Date: Thu Mar 26 02:25:59 2009 Subject: [plt-scheme] Timedeltas for PLT? In-Reply-To: <18599.33987.83104.285645@arabic.ccs.neu.edu> References: <20080816115322.26563787@halmanfloyd.lan.local> <18598.46281.739067.165796@arabic.ccs.neu.edu> <20080817014859.3e00720a@halmanfloyd.lan.local> <18599.33987.83104.285645@arabic.ccs.neu.edu> Message-ID: <20080817123306.713e25cc@halmanfloyd.lan.local> On Sat, 16 Aug 2008 21:54:11 -0400 Eli Barzilay wrote: > > Btw: Somehow the PLT documentation search does not find the SFRI > > documentation. The search function is cool, but somehow it does not > > (yet) find all useful things that are documented. > > I just entered "date string" and it found it -- what did you search > for, and which entry was not in the results? Sorry, false alarm, it works properly, I just wrote the query wrong. Thanks for your answers. regards, Marek From tom at zwizwa.be Sun Aug 17 07:26:03 2008 From: tom at zwizwa.be (Tom Schouten) Date: Thu Mar 26 02:25:59 2009 Subject: [plt-scheme] automated PLaneT upload Message-ID: <20080817112603.GA21302@zzz.i> Hello, Is there a way to upload PLaneT packages without having to go through the web interface? Aditionally, is there a way to delete releases, or redirect a release to an 'unstable snapshot' version that's hosted somewhere else? Cheers, Tom From mflatt at cs.utah.edu Sun Aug 17 07:38:11 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:25:59 2009 Subject: [plt-scheme] Problem with Create Executable (Win XP) In-Reply-To: References: Message-ID: <20080817113814.5F7D56500A9@mail-svr1.cs.utah.edu> At Sun, 17 Aug 2008 08:50:24 +0200, "Sverrir Valgeirsson" wrote: > I'm using DrScheme 4.1 for writing a very simple MrEd program. > The program works well when run from DrScheme, but when I've done a > "Create Executable" and run the resulting file I get an error message > saying: "cddr: expects argument of type ; given > ("#f")" and then the program exits. > I never use cddr in my program so I don't know where this comes from. > > Any ideas? Are you using the "Pretty Big" language? I see that "Create Executable" doesn't work with Pretty Big in v4.x. If so, we'll fix that bug, but your best option is really to use the module system (and the "Module" language in DrScheme). Converting your program to a module may be as simple as adding #lang scheme/gui to the beginning of your program. Matthew From robby at cs.uchicago.edu Sun Aug 17 08:48:55 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:00 2009 Subject: [plt-scheme] automated PLaneT upload In-Reply-To: <20080817112603.GA21302@zzz.i> References: <20080817112603.GA21302@zzz.i> Message-ID: <932b2f1f0808170548n2482bd8an67283add05bf89a5@mail.gmail.com> No, unfortunately, none of that is possible at the moment. Uploading via the web interface should be fairly painless, but we are planning on adding something to the commandline tool for uploading. As far as the other goes, we can hide releases (so that it is only accessible if someone explicitly requests that version and no other version), but you have to go thru a PLaneT maintainer to do that. Robby On Sun, Aug 17, 2008 at 6:26 AM, Tom Schouten wrote: > Hello, > > Is there a way to upload PLaneT packages without having to go through > the web interface? > > Aditionally, is there a way to delete releases, or redirect a release > to an 'unstable snapshot' version that's hosted somewhere else? > > Cheers, > Tom > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From ancmin at gmail.com Sun Aug 17 08:35:47 2008 From: ancmin at gmail.com (=?ISO-8859-1?Q?Fran=E7ois_Schwarzentruber?=) Date: Thu Mar 26 02:26:00 2009 Subject: [plt-scheme] scheme in java Message-ID: Hello, First of all, I thank you for your work. Congratulations ! DrScheme is absolutely great and powerful. I use it to program a generic solver for modal logic. (see http://www.irit.fr/~Francois.Schwarzentruber/lotreclightinscheme/lotreclightscheme.html ) Now, I have many questions : 1) Do you know if it is possible to embed a Scheme interpreter into a Java application ? (a sort of library providing me the possibility that the user can enter scheme code into a JEdit and interpret it by pressing a JButton) I have found those interesting projects: - Jatha, very easy to ease but it is Lisp and not Scheme :( - JScheme and SISC but there are a bit difficult and I don't know if the whole R6RS Scheme is supported. 2) What do you mean by exactly "pretty big scheme" ? Is it R6RS ? Thank you in advance. Have a nice day ! Best regards, Fran?ois Schwarzentruber -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080817/02bd46f6/attachment.htm From kbohdan at mail.ru Sun Aug 17 09:20:10 2008 From: kbohdan at mail.ru (kbohdan@mail.ru) Date: Thu Mar 26 02:26:01 2009 Subject: [plt-scheme] Problem importing srfi Message-ID: How can i import srfi (with number or name) using r6rs imports ? No luck by now. Neither of (import (srfi 48)) (import (srfi-48)) (import (srfi format)) works. -- Bohdan From sk at cs.brown.edu Sun Aug 17 10:18:38 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:26:01 2009 Subject: [plt-scheme] scheme in java In-Reply-To: References: Message-ID: Excellent! Love the image examples. > 1) Do you know if it is possible to embed a Scheme interpreter into a Java > application ? (a sort of library providing me the possibility that the user > can enter scheme code into a JEdit and interpret it by pressing a JButton) I saw on your Web page that you want to do this to deploy programs on the Web. But Scheme already has a great Web server interface. So why would you want to mess w/ Java? See the tutorial that Danny and Jay have developed, if you need help getting started. (Jay, can you please post a pointer?) > 2) What do you mean by exactly "pretty big scheme" ? Is it R6RS ? A better name would be "kitchen sink Scheme": it's Standard Scheme plus all the usual PLT additions (structures, LOCAL, better names for some primitives, etc, etc). The Help Desk (under the Help menu) will give you more info. Shriram From grettke at acm.org Sun Aug 17 11:38:34 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:01 2009 Subject: [plt-scheme] scheme in java In-Reply-To: References: Message-ID: <756daca50808170838x711a834em80ac4049c5e60921@mail.gmail.com> >> 2) What do you mean by exactly "pretty big scheme" ? Is it R6RS ? > > A better name would be "kitchen sink Scheme": it's Standard Scheme > plus all the usual PLT additions (structures, LOCAL, better names for > some primitives, etc, etc). The Help Desk (under the Help menu) will > give you more info. If Fran?ois wants to use the PLT web server, would he be better off moving his code from "pretty big" to "#lang scheme using modules"? From anesward at mac.com Sun Aug 17 13:47:01 2008 From: anesward at mac.com (mike) Date: Thu Mar 26 02:26:01 2009 Subject: [plt-scheme] answers from htdp Message-ID: Hi all ; i am presently on a self study journey though htdp and would like to know is it possible to be able to access some of exercise answers from the web; I noticed that it is password protected. mike From sk at cs.brown.edu Sun Aug 17 14:22:16 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:26:01 2009 Subject: [plt-scheme] answers from htdp In-Reply-To: References: Message-ID: Sorry, no, the passwords are for professors only. But you can get lots of help on forums like this or the comp.lang.scheme newsgroup if you demonstrate that you really are working through the material yourself, not just asking people to provide you with answers. Our newer material, here -- http://world.cs.brown.edu/ -- comes with public solutions to some of the materials to help self-learners like you. Shriram From DekuDekuplex at Yahoo.com Mon Aug 18 02:24:33 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:26:01 2009 Subject: [plt-scheme] Where can I find the rocket-s.jpg image of "How to Design Programs/2e: Prolog, Section 2?" Message-ID: While trying to follow along "How to Design Programs/2e: Prolog, Section 2" (see http://www.ccs.neu.edu/home/matthias/HtDP/Prologue/book-Z-H-4.html), I got stuck in trying to insert the rocket-s.jpg image; viz.: > One important library -- world.ss -- supports operations for computing the width and height of an image: > >(* (image-width ) > (image-height )) > >Once you have added a library to your program, clicking Run gives you > > 1200 I was unable to find this image just by going to the "Insert" -> "Insert Image..." menu item, and when I finally right-clicked on the image in the browser, then clicked on "Save Image As...," it saved as "rocket-s.jpg," but then executing the above function in the Definitions Window returned the following value in the Interactions Window: > 1176 This is not what the text specifies. How should I insert the image so that I get "1200" as the result of executing the above function? (Incidentally, do you know why "Prolog" comes up as the page title when saving a bookmark of the page? Is this a bug, or is the book actually related to Prolog?) -- Benjamin L. Russell From DekuDekuplex at Yahoo.com Mon Aug 18 03:15:12 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:26:02 2009 Subject: [plt-scheme] Re: Where can I find the rocket-s.jpg image of "How to Design Programs/2e: Prolog, Section 2?" References: Message-ID: On Mon, 18 Aug 2008 15:24:33 +0900, Benjamin L.Russell wrote: >While trying to follow along "How to Design Programs/2e: Prolog, >Section 2" (see >http://www.ccs.neu.edu/home/matthias/HtDP/Prologue/book-Z-H-4.html), I >got stuck in trying to insert the rocket-s.jpg image; viz.: > >> One important library -- world.ss -- supports operations for computing the width and height of an image: >> >>(* (image-width ) >> (image-height )) >> >>Once you have added a library to your program, clicking Run gives you >> >> 1200 > >I was unable to find this image just by going to the "Insert" -> >"Insert Image..." menu item, and when I finally right-clicked on the >image in the browser, then clicked on "Save Image As...," it saved as >"rocket-s.jpg," but then executing the above function in the >Definitions Window returned the following value in the Interactions >Window: > >> 1176 > >This is not what the text specifies. How should I insert the image so >that I get "1200" as the result of executing the above function? After searching on the Internet, I discovered that the above rocket-s.jpg image was available at the following site: /trunk/larceny_src/lib/TeachPacks/rocket-s.jpg -- The Larceny Project -- Trac: https://trac.ccs.neu.edu/trac/larceny/browser/trunk/larceny_src/lib/TeachPacks/rocket-s.jpg?rev=3939 However, using this image with the above function still returned 1176, instead of 1200. Also, it seems strange that I should need either to download the rocket-s.jpg image from the Web page or to search for it on the Internet in order to find it; the book should be self-contained with respect to using images. Is there something terribly obvious that I am missing about inserting this particular image so that the above function returns 1200? -- Benjamin L. Russell From DekuDekuplex at Yahoo.com Mon Aug 18 06:28:44 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:26:02 2009 Subject: [plt-scheme] Any tips for avoiding intermittent freezing when navigating file system directories with mounted network volumes in DrScheme? Message-ID: <74jia4hvk0ena11cvch0neuq7hlfca7jh5@4ax.com> While this topic has already been discussed in this mailing list (without a clear solution), I am still wondering whether there is any way to avoid intermittent freezing when navigating file system directories in DrScheme. Today, I was using DrScheme, version 4.1, english, on Windows XP, Service Pack 2, and repeatedly encountered freezing every few seconds while navigating the system directories when trying to save the Definitions and Interactions Windows. I actually spent more time on waiting for the freezes to stop than on the actual saving of the files. IIRC, somebody once stated on this mailing list that this problem happens if the system has -mounted network volumes in its file system. My system does, but I am not navigating those volumes when saving; I am only navigating the local C drive. Does anybody have any tips on avoiding this intermittent freezing when navigating local file system directories on a system with mounted network volumes? -- Benjamin L. Russell From sk at cs.brown.edu Mon Aug 18 07:44:01 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:26:02 2009 Subject: [plt-scheme] Re: Where can I find the rocket-s.jpg image of "How to Design Programs/2e: Prolog, Section 2?" In-Reply-To: References: Message-ID: > I was unable to find this image just by going to the "Insert" -> > "Insert Image..." menu item, and when I finally right-clicked on the > image in the browser, then clicked on "Save Image As...," it saved as > "rocket-s.jpg," but then executing the above function in the > Definitions Window returned the following value in the Interactions > Window: > >> 1176 > > This is not what the text specifies. How should I insert the image so > that I get "1200" as the result of executing the above function? Maybe the image was scaled differently? > (Incidentally, do you know why "Prolog" comes up as the page title > when saving a bookmark of the page? Is this a bug, or is the book > actually related to Prolog?) No. "Prolog" = "Prologue" > However, using this image with the above function still returned 1176, > instead of 1200. Also, it seems strange that I should need either to > download the rocket-s.jpg image from the Web page or to search for it > on the Internet in order to find it; the book should be self-contained > with respect to using images. If you want to play with World programs, go to http://world.cs.brown.edu/ It's totally self-contained in a way that even the most pedantic person can't miss. If you claim *that* isn't self-contained, then I'm afraid I simply don't understand you. Shriram From mflatt at cs.utah.edu Mon Aug 18 09:49:08 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:02 2009 Subject: [plt-scheme] Problem importing srfi In-Reply-To: References: Message-ID: <20080818134909.E9AEE6500BD@mail-svr1.cs.utah.edu> At Sun, 17 Aug 2008 16:20:10 +0300, kbohdan@mail.ru wrote: > How can i import srfi (with number or name) using r6rs imports ? > No luck by now. > > Neither of > (import (srfi 48)) > (import (srfi-48)) > (import (srfi format)) > works. You could use (import (srfi \x34;8)) which turns "48" into a symbol by using the hex encoding of the character "4". I expect that we'll eventually support the path convention of SRFI 97, but it's not in place, yet. Also, beware that SRFIs that consume or produce lists will not work as expected with R6RS, since the current SRFI implementations use immutable pairs (as compatible the PLT dialects of Scheme). When we put libraries in place using the SRFI 97 convention, they'll work as expected with R6RS lists. Matthew From sk at cs.brown.edu Mon Aug 18 10:15:34 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:26:02 2009 Subject: [plt-scheme] Re: answers from htdp In-Reply-To: <867iae5y2z.fsf@gmail.com> References: <867iae5y2z.fsf@gmail.com> Message-ID: You know, if we never had those "Solution" links in the HTML document, nobody would *ever* complain about this. (They might ask, but they wouldn't complain.) Anyway, changing HtDP's structure at this point is non-trivial. But fixing this problem for the second edition is a concrete goal. As I already said, our new World material already takes the route that about half the assignments have public solutions. The reason we have protected solutions at all (and will continue to do so) is because some of our teachers want that, so they can assign those problems and grade against definitive solutions. [NB: Please don't bother flaming these teachers. We've heard or thought about every argument in this regard. This is our policy and we're sticking to it. You can flame us instead of the teachers, but that won't be a very productive use of time.] Shriram PS: Ignoring all these gmane.org addresses... From matthias at ccs.neu.edu Mon Aug 18 10:23:57 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:02 2009 Subject: [plt-scheme] Where can I find the rocket-s.jpg image of "How to Design Programs/2e: Prolog, Section 2?" In-Reply-To: References: Message-ID: <00A699C5-450A-4C7B-BAD5-2D8798743D6B@ccs.neu.edu> Apologies. The Prologue was supposed to energize an HtDP/2e effort and was supposed to come with pictures and web pages. Well, I was too busy and I am still too busy. So Shriram has collected our world material and has put out a collection for now. -- Matthias On Aug 18, 2008, at 2:24 AM, Benjamin L.Russell wrote: > While trying to follow along "How to Design Programs/2e: Prolog, > Section 2" (see > http://www.ccs.neu.edu/home/matthias/HtDP/Prologue/book-Z-H-4.html), I > got stuck in trying to insert the rocket-s.jpg image; viz.: > >> One important library -- world.ss -- supports operations for >> computing the width and height of an image: >> >> (* (image-width ) >> (image-height )) >> >> Once you have added a library to your program, clicking Run gives you >> >> 1200 > > I was unable to find this image just by going to the "Insert" -> > "Insert Image..." menu item, and when I finally right-clicked on the > image in the browser, then clicked on "Save Image As...," it saved as > "rocket-s.jpg," but then executing the above function in the > Definitions Window returned the following value in the Interactions > Window: > >> 1176 > > This is not what the text specifies. How should I insert the image so > that I get "1200" as the result of executing the above function? > > (Incidentally, do you know why "Prolog" comes up as the page title > when saving a bookmark of the page? Is this a bug, or is the book > actually related to Prolog?) > > -- Benjamin L. Russell > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From psykosh at earthlink.net Mon Aug 18 12:31:11 2008 From: psykosh at earthlink.net (Psy-Kosh) Date: Thu Mar 26 02:26:03 2009 Subject: [plt-scheme] OT: Cartoon Guide to Lob's Theorem Message-ID: This is a bit off topic, but I suspect some here would appreciate this: http://www.overcomingbias.com/2008/08/lobs-theorem.html Remenicent of the graphical lambda game thing. Psy-Kosh From smade4 at gmail.com Mon Aug 18 08:04:04 2008 From: smade4 at gmail.com (Glauber Alex Dias Prado) Date: Thu Mar 26 02:26:03 2009 Subject: [plt-scheme] Re: answers from htdp In-Reply-To: (Shriram Krishnamurthi's message of "Sun, 17 Aug 2008 14:22:16 -0400") References: Message-ID: <867iae5y2z.fsf@gmail.com> Just a complaint here, one of the best books I've came across to learn programming is A Gentle Introduction to Symbolic Computation, very good book and it has the answers on the end of the book, and i found it great to *really* practice the exercises, which in my opinion are a invaluable tool for learning anything and not having the answers, specially for those who work alone is a bad thing, no pun intended im sure you have your reason to not free it, the first i come across is bad students perhaps ? "Shriram Krishnamurthi" writes: > Sorry, no, the passwords are for professors only. > But you can get lots of help on forums like this or > the comp.lang.scheme newsgroup if you demonstrate > that you really are working through the material > yourself, not just asking people to provide you with > answers. > > Our newer material, here -- > > http://world.cs.brown.edu/ > > -- comes with public solutions to some of the materials > to help self-learners like you. > > Shriram > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From grettke at acm.org Mon Aug 18 15:13:07 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:03 2009 Subject: [plt-scheme] Re: answers from htdp In-Reply-To: <867iae5y2z.fsf@gmail.com> References: <867iae5y2z.fsf@gmail.com> Message-ID: <756daca50808181213i63f8885dv8146b059a69d928@mail.gmail.com> On Mon, Aug 18, 2008 at 7:04 AM, Glauber Alex Dias Prado wrote: > Just a complaint here, one of the best books I've came across to learn > programming is A Gentle Introduction to Symbolic Computation, very good > book and it has the answers on the end of the book, and i found it great > to *really* practice the exercises, which in my opinion are a invaluable > tool for learning anything and not having the answers, HTDP folks: Alternately; have you found that not-providing the solutions to "everyone" somehow impairs their learning? Just wondering... From grettke at acm.org Mon Aug 18 15:20:27 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:03 2009 Subject: [plt-scheme] Any tips for avoiding intermittent freezing when navigating file system directories with mounted network volumes in DrScheme? In-Reply-To: <74jia4hvk0ena11cvch0neuq7hlfca7jh5@4ax.com> References: <74jia4hvk0ena11cvch0neuq7hlfca7jh5@4ax.com> Message-ID: <756daca50808181220r2e6dfd8fqaecdab70748016de@mail.gmail.com> > Does anybody have any tips on avoiding this intermittent freezing when > navigating local file system directories on a system with mounted > network volumes? Just wondering, is this a general Windows issue or a DrScheme specific issue? My machine at work has horrible, terrible hanging issues whenever I use Explorer. From atmamta at gmail.com Tue Aug 19 04:05:52 2008 From: atmamta at gmail.com (Atmam Ta) Date: Thu Mar 26 02:26:04 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: <0D599712-C925-41B9-A739-88DEE0317C8D@ccs.neu.edu> References: <5C8609B1-70DA-48AB-8EC8-166BD90DAA38@mit.edu> <0D599712-C925-41B9-A739-88DEE0317C8D@ccs.neu.edu> Message-ID: I heard that in the ocaml community people created software for automating c library interface creation - i.e. you plug in the .h header file(s) and after some parsing and code generation out comes the raw interface code (which usually needs human editing to work perfecty...). Has there been an example of that in plt-scheme? Perhaps the GSL library is large enough to worry about such automation... -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080819/ec441d3d/attachment.html From eli at barzilay.org Tue Aug 19 04:11:18 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:26:04 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: References: <5C8609B1-70DA-48AB-8EC8-166BD90DAA38@mit.edu> <0D599712-C925-41B9-A739-88DEE0317C8D@ccs.neu.edu> Message-ID: <18602.32806.243602.815667@arabic.ccs.neu.edu> On Aug 19, Atmam Ta wrote: > I heard that in the ocaml community people created software for > automating c library interface creation - i.e. you plug in the .h > header file(s) and after some parsing and code generation out comes > the raw interface code (which usually needs human editing to work > perfecty...). Has there been an example of that in plt-scheme? > Perhaps the GSL library is large enough to worry about such > automation... This requires either parsing header files, or using a C compiler to do it for you. Also, if the header files are platform specific, then it means that you won't want to just generate the Scheme code and use it, but do that genaration automatically so it can be performed on every platform. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From spdegabrielle at gmail.com Tue Aug 19 04:46:23 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:04 2009 Subject: [plt-scheme] set-text for text% Message-ID: <595b9ab20808190146t67912c5ek2a778f737b091c6@mail.gmail.com> Please forgive the dumb question; Does anyone know how to set the contents of a whole text% editor object? (with a string) get-text gets the whole thing as a string - but I can't find a setter that overwrites the whole contents without using a file. Cheers, Stephen From mflatt at cs.utah.edu Tue Aug 19 07:14:35 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:04 2009 Subject: [plt-scheme] set-text for text% In-Reply-To: <595b9ab20808190146t67912c5ek2a778f737b091c6@mail.gmail.com> References: <595b9ab20808190146t67912c5ek2a778f737b091c6@mail.gmail.com> Message-ID: <20080819111436.BC6586500AF@mail-svr1.cs.utah.edu> At Tue, 19 Aug 2008 09:46:23 +0100, "Stephen De Gabrielle" wrote: > Does anyone know how to set the contents of a whole text% editor > object? (with a string) Use `insert' with 0 for the starting position and the result of `last-position' for the end position: (send e insert str 0 (send e last-position)) Matthew From jadudm at gmail.com Tue Aug 19 07:44:31 2008 From: jadudm at gmail.com (Matt Jadud) Date: Thu Mar 26 02:26:04 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: <18602.32806.243602.815667@arabic.ccs.neu.edu> References: <5C8609B1-70DA-48AB-8EC8-166BD90DAA38@mit.edu> <0D599712-C925-41B9-A739-88DEE0317C8D@ccs.neu.edu> <18602.32806.243602.815667@arabic.ccs.neu.edu> Message-ID: On Tue, Aug 19, 2008 at 4:11 AM, Eli Barzilay wrote: > On Aug 19, Atmam Ta wrote: >> I heard that in the ocaml community people created software for >> automating c library interface creation - i.e. you plug in the .h > > This requires either parsing header files, or using a C compiler to do > it for you. Also, if the header files are platform specific, then it > means that you won't want to just generate the Scheme code and use it, > but do that genaration automatically so it can be performed on every > platform. i'm curious... has anyone ever looked at doing a MzScheme SWIG backend that emits CFFI code instead of creating C bindings? I've wondered if this would be a feasible approach from time-to-time, but never really investigated it. Cheers, Matt From lunarc.lists at gmail.com Tue Aug 19 09:28:17 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:04 2009 Subject: [plt-scheme] missing gsl scientific libraries In-Reply-To: References: <5C8609B1-70DA-48AB-8EC8-166BD90DAA38@mit.edu> <0D599712-C925-41B9-A739-88DEE0317C8D@ccs.neu.edu> <18602.32806.243602.815667@arabic.ccs.neu.edu> Message-ID: 2008/8/19 Matt Jadud : > i'm curious... has anyone ever looked at doing a MzScheme SWIG backend > that emits CFFI code instead of creating C bindings? I've wondered if > this would be a feasible approach from time-to-time, but never really > investigated it. It's been brought up from time to time on-list, but AFAIK no one has actually done anything toward it. I think the difficulty is that the bindings generated by SWIG would be platform-specific, as it would expand all #ifdefs. In PLT-Scheme, you would really want to switch on the value of (system-type) for platform-specific differences. The only way I've thought of doing that with SWIG would be to generate flat bindings for each system and do some automated diff on the results to generate different branches of definitions. Henk From andre.mayers at usherbrooke.ca Tue Aug 19 09:15:03 2008 From: andre.mayers at usherbrooke.ca (Andre Mayers) Date: Thu Mar 26 02:26:05 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> Message-ID: <003201c901fd$97704200$c650c600$@mayers@usherbrooke.ca> At the end of section 3.4 of "Sketchy LISP : An Introduction to Functional Programming in Scheme" http://t3x.org/sketchy/vol1/sl20.html we have (letrec ((x (call/cc list))) (if (pair? x) ((car x) (lambda () x)) (pair? (x)))) => #f but with drscheme we have Bienvenue dans DrScheme, version 4.1 [3m]. Langage: Module; memory limit: 256 megabytes. > (letrec ((x (call/cc list))) (if (pair? x) ((car x) (lambda () x)) (pair? (x)))) #t > Andr? Mayers, Ph.D., M. Ps. professeur agr?g? D?partement d'informatique Universit? de Sherbrooke Sherbrooke (Qu?bec) Canada J1K 2R1 t?l: +1 819-821-8000 poste 62041 fax: +1 819-821-8200 andre.mayers@usherbrooke.ca http://www.dmi.usherb.ca/~amayers From matthias at ccs.neu.edu Tue Aug 19 09:59:44 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:05 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <003201c901fd$97704200$c650c600$@mayers@usherbrooke.ca> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$@mayers@usherbrooke.ca> Message-ID: <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> Here is a proof that this must evaluate to #t. -- Matthias (letrec ((x (call/cc list))) (if (pair? x) ((car x) (lambda () x)) (pair? (x)))) => (letrec ((x (list *E*)) (if (pair? x) ((car x) (lambda () x)) (pair? (x))))) where *E* = (letrec ((x [])) (if (pair? x) ((car x) (lambda () x)) (pair? (x)))) => (if (pair? (list *E*)) ((car (list *E*)) (lambda () (list *E*))) (pair? ((list *E*)))) => ((car (list *E*)) (lambda () (list *E*))) => (*E* (lambda () (list *E*))) => (letrec ((x (lambda () (list *E*)))) (if (pair? x) ((car x) (lambda () x)) (pair? (x)))) => (if (pair? (lambda () (list *E*))) ((car (lambda () (list *E*))) (lambda () (lambda () (list *E*)))) (pair? ((lambda () (list *E*))))) => (pair? ((lambda () (list *E*)))) => (pair? (list *E*)) => #t From mflatt at cs.utah.edu Tue Aug 19 10:10:08 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:05 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$@mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> Message-ID: <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> At Tue, 19 Aug 2008 09:59:44 -0400, Matthias Felleisen wrote: > > Here is a proof that this must evaluate to #t. I believe that matches the semantics of PLT Scheme's `letrec'. The R5RS/R6RS `letrec' is different, and the result with that other `letrec' should be #f: (letrec ((x (call/cc list))) (if (pair? x) ((car x) (lambda () x)) (pair? (x)))) = (let ((x #f)) (set! x (call/cc list)) (if (pair? x) ((car x) (lambda () x)) (pair? (x)))) => (define x_0 #f) (begin (set! x (call/cc list)) (if (pair? x_0) ((car x_0) (lambda () x_0)) (pair? (x_0))))) => (define x_0 #f) (begin (set! x (list *E*)) (if (pair? x_0) ((car x_0) (lambda () x_0)) (pair? (x_0))))) where *E* = (begin (set! x_0 []) (if (pair? x_0) ((car x_0) (lambda () x_0)) (pair? (x_0)))) => (define x_0 (list *E*)) (if (pair? x_0) ((car x_0) (lambda () x_0)) (pair? (x_0))) => (define x_0 (list *E*)) (if (pair? (list *E*)) ((car x_0) (lambda () x_0)) (pair? (x_0))) => (define x_0 (list *E*)) ((car x_0) (lambda () x_0)) => (define x_0 (list *E*)) (*E* (lambda () x_0)) => (define x_0 (list *E*)) (begin (set! x_0 (lambda () x_0)) (if (pair? x_0) ((car x_0) (lambda () x_0)) (pair? (x_0)))) => (define x_0 (lambda () x_0)) (if (pair? x_0) ((car x_0) (lambda () x_0)) (pair? (x_0))) => (pair? (x_0)) => (pair? ((lambda () x_0))) => (pair? x_0) => (pair? (lambda () x_0)) => #f From mflatt at cs.utah.edu Tue Aug 19 10:22:28 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:05 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$@mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> Message-ID: <20080819142229.DC4046500B2@mail-svr1.cs.utah.edu> At Tue, 19 Aug 2008 09:59:44 -0400, Matthias Felleisen wrote: > Here is a proof that this must evaluate to #t. Actually, on further investigation, I don't think that PLT Scheme's `letrec' is supposed to behave that way, either. Your proof is treating `letrec' like `let', right? That's exactly what MzScheme's optimizer is incorrectly doing in this case. So I'm now pretty sure that the right answer is #f for all of our variations on `letrec', and I'll fix the optimizer. Matthew From matthias at ccs.neu.edu Tue Aug 19 10:27:09 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:05 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$@mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> Message-ID: Fair enough. I should have known better. I used callcc to extract set! out of letrec's back in 1987. -- Matthias On Aug 19, 2008, at 10:10 AM, Matthew Flatt wrote: > At Tue, 19 Aug 2008 09:59:44 -0400, Matthias Felleisen wrote: >> >> Here is a proof that this must evaluate to #t. > > I believe that matches the semantics of PLT Scheme's `letrec'. > > The R5RS/R6RS `letrec' is different, and the result with that other > `letrec' should be #f: > > > (letrec ((x (call/cc list))) > (if (pair? x) > ((car x) (lambda () x)) > (pair? (x)))) > > = > > (let ((x #f)) > (set! x (call/cc list)) > (if (pair? x) > ((car x) (lambda () x)) > (pair? (x)))) > > => > > (define x_0 #f) > (begin > (set! x (call/cc list)) > (if (pair? x_0) > ((car x_0) (lambda () x_0)) > (pair? (x_0))))) > > => > > (define x_0 #f) > (begin > (set! x (list *E*)) > (if (pair? x_0) > ((car x_0) (lambda () x_0)) > (pair? (x_0))))) > > where *E* = > (begin > (set! x_0 []) > (if (pair? x_0) > ((car x_0) (lambda () x_0)) > (pair? (x_0)))) > > => > > (define x_0 (list *E*)) > > (if (pair? x_0) > ((car x_0) (lambda () x_0)) > (pair? (x_0))) > > => > > (define x_0 (list *E*)) > > (if (pair? (list *E*)) > ((car x_0) (lambda () x_0)) > (pair? (x_0))) > > => > > (define x_0 (list *E*)) > > ((car x_0) (lambda () x_0)) > > => > > (define x_0 (list *E*)) > > (*E* (lambda () x_0)) > > => > > (define x_0 (list *E*)) > > (begin > (set! x_0 (lambda () x_0)) > (if (pair? x_0) > ((car x_0) (lambda () x_0)) > (pair? (x_0)))) > > => > > (define x_0 (lambda () x_0)) > > (if (pair? x_0) > ((car x_0) (lambda () x_0)) > (pair? (x_0))) > > => > > (pair? (x_0)) > > => > > (pair? ((lambda () x_0))) > > => > > (pair? x_0) > > => > > (pair? (lambda () x_0)) > > => > > #f > From matthias at ccs.neu.edu Tue Aug 19 10:34:09 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:06 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <20080819142229.DC4046500B2@mail-svr1.cs.utah.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$@mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819142229.DC4046500B2@mail-svr1.cs.utah.edu> Message-ID: On Aug 19, 2008, at 10:22 AM, Matthew Flatt wrote: > At Tue, 19 Aug 2008 09:59:44 -0400, Matthias Felleisen wrote: >> Here is a proof that this must evaluate to #t. > > Actually, on further investigation, I don't think that PLT Scheme's > `letrec' is supposed to behave that way, either. Your proof is > treating > `letrec' like `let', right? Correct. That was my mistake if you take the RnRS set! definition as the semantics of letrec. If, however, you agree that letrec is to find the fixed point of the equation x = (call/cc list), I think a let-style semantics is appropriate because x doesn't occur on the right side of the equation. [NB. I do believe that Bob Hieb showed me how this worked in Chez way back, i.e., it also computes the FV set of the right-hand sides and replaces a letrec with a nest of let/let* computations. Of course Kent may have changed that since then.] > That's exactly what MzScheme's optimizer is > incorrectly doing in this case. Depends on what we define letrec to mean. > So I'm now pretty sure that the right answer is #f for all of our > variations on `letrec', and I'll fix the optimizer. Yes I can see an argument for having a set! style semantics in all cases. -- Matthias From mflatt at cs.utah.edu Tue Aug 19 10:59:14 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:06 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> Message-ID: <20080819145916.5DA0A6500AA@mail-svr1.cs.utah.edu> At Tue, 19 Aug 2008 07:44:50 -0700, Abdulaziz Ghuloum wrote: > > On Aug 19, 2008, at 7:10 AM, Matthew Flatt wrote: > > > The R5RS/R6RS `letrec' is different, and the result with that other > > `letrec' should be #f: > > An R6RS implementation may (or may not) raise an &assertion when the > continuation is invoked the second time, right? To me, that > says that "it is an error" (in the R5RS sense) to evaluate an > continuation more that once, so, the program is incorrect. Yes, good point. Matthew From aghuloum at cs.indiana.edu Tue Aug 19 10:44:50 2008 From: aghuloum at cs.indiana.edu (Abdulaziz Ghuloum) Date: Thu Mar 26 02:26:06 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> Message-ID: <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> On Aug 19, 2008, at 7:10 AM, Matthew Flatt wrote: > The R5RS/R6RS `letrec' is different, and the result with that other > `letrec' should be #f: An R6RS implementation may (or may not) raise an &assertion when the continuation is invoked the second time, right? To me, that says that "it is an error" (in the R5RS sense) to evaluate an continuation more that once, so, the program is incorrect. Aziz,,, From jay.mccarthy at gmail.com Tue Aug 19 11:09:29 2008 From: jay.mccarthy at gmail.com (Jay McCarthy) Date: Thu Mar 26 02:26:06 2009 Subject: [plt-scheme] scheme in java In-Reply-To: References: Message-ID: On Sun, Aug 17, 2008 at 8:18 AM, Shriram Krishnamurthi wrote: >> 1) Do you know if it is possible to embed a Scheme interpreter into a Java >> application ? (a sort of library providing me the possibility that the user >> can enter scheme code into a JEdit and interpret it by pressing a JButton) > > I saw on your Web page that you want to do this to deploy programs on > the Web. But Scheme already has a great Web server interface. So why > would you want to mess w/ Java? See the tutorial that Danny and Jay > have developed, if you need help getting started. (Jay, can you > please post a pointer?) Here's the new web tutorial: http://docs.plt-scheme.org/web-server-tutorial/index.html -- Jay McCarthy Assistant Professor / Brigham Young University http://jay.teammccarthy.org "The glory of God is Intelligence" - D&C 93 From jadudm at gmail.com Tue Aug 19 11:17:46 2008 From: jadudm at gmail.com (Matt Jadud) Date: Thu Mar 26 02:26:06 2009 Subject: [plt-scheme] scheme in java In-Reply-To: References: Message-ID: On Tue, Aug 19, 2008 at 11:09 AM, Jay McCarthy wrote: > Here's the new web tutorial: > > http://docs.plt-scheme.org/web-server-tutorial/index.html I recently tried Untyped's "dispatch" library for the first time. If you want to develop an application that quickly maps URLs to functionality, it provides a really nice, simplified framework. At least, I thought it was really simple and fun to use. I know Dave and Noel are using it for large projects, but they seemed to keep the heavy-lifting power behind-the-scenes for simple stuff. http://planet.plt-scheme.org/package-source/untyped/dispatch.plt/1/5/planet-docs/dispatch/index.html By following the example Dave wrote in the documentation, I was iteratively developing and poking my app on the local host very quickly, and moving it to a live server was quite painless. Cheers, Matt From matthias at ccs.neu.edu Tue Aug 19 11:19:48 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:06 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> Message-ID: <657C5DD6-A1EF-4F99-8FFB-377E18AAEFD3@ccs.neu.edu> On Aug 19, 2008, at 10:44 AM, Abdulaziz Ghuloum wrote: > > On Aug 19, 2008, at 7:10 AM, Matthew Flatt wrote: > >> The R5RS/R6RS `letrec' is different, and the result with that other >> `letrec' should be #f: > > An R6RS implementation may (or may not) raise an &assertion when the > continuation is invoked the second time, right? To me, that > says that "it is an error" (in the R5RS sense) to evaluate an > continuation more that once, so, the program is incorrect. I assume w/ "incorrect" you mean "is not a legal program". It never ceases to amaze me that the Report specifies that some syntactically legal expressions are NOT programs but you can only find out (as far as I know) that they are NOT programs by RUNNING them. (Of course all this means is that compilers and interpreters accept and deal with 'things' that are not legal programs in the spirit of a report, though I can't think of another language with this property.) -- Matthias From andre.mayers at usherbrooke.ca Tue Aug 19 11:37:30 2008 From: andre.mayers at usherbrooke.ca (Andre Mayers) Date: Thu Mar 26 02:26:07 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <657C5DD6-A1EF-4F99-8FFB-377E18AAEFD3@ccs.neu.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <657C5DD6-A1EF-4F99-8FFB-377E18AAEFD3@ccs.neu.edu> Message-ID: <004801c90211$7e326020$7a972060$@mayers@usherbrooke.ca> If I summarize (letrec ((x (call/cc list))) (if (pair? x) ((car x) (lambda () x)) (pair? (x)))) is an illegal program because the init of x is evaluated twice. Therefore the behaviour of drscheme and Sketchy LISP are inappropriate. Andre -----Message d'origine----- De?: plt-scheme-bounces@list.cs.brown.edu [mailto:plt-scheme-bounces@list.cs.brown.edu] De la part de Matthias Felleisen Envoy??: August-19-08 11:20 AM ??: Abdulaziz Ghuloum Cc?: Matthew Flatt; andre.mayers@usherbrooke.ca; 'PLT List' Objet?: Re: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? On Aug 19, 2008, at 10:44 AM, Abdulaziz Ghuloum wrote: > > On Aug 19, 2008, at 7:10 AM, Matthew Flatt wrote: > >> The R5RS/R6RS `letrec' is different, and the result with that other >> `letrec' should be #f: > > An R6RS implementation may (or may not) raise an &assertion when the > continuation is invoked the second time, right? To me, that > says that "it is an error" (in the R5RS sense) to evaluate an > continuation more that once, so, the program is incorrect. I assume w/ "incorrect" you mean "is not a legal program". It never ceases to amaze me that the Report specifies that some syntactically legal expressions are NOT programs but you can only find out (as far as I know) that they are NOT programs by RUNNING them. (Of course all this means is that compilers and interpreters accept and deal with 'things' that are not legal programs in the spirit of a report, though I can't think of another language with this property.) -- Matthias _________________________________________________ For list-related administrative tasks: http://list.cs.brown.edu/mailman/listinfo/plt-scheme From czhu at cs.utah.edu Tue Aug 19 12:26:44 2008 From: czhu at cs.utah.edu (Chongkai Zhu) Date: Thu Mar 26 02:26:07 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <657C5DD6-A1EF-4F99-8FFB-377E18AAEFD3@ccs.neu.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <657C5DD6-A1EF-4F99-8FFB-377E18AAEFD3@ccs.neu.edu> Message-ID: <48AAF444.6050508@cs.utah.edu> Matthias Felleisen wrote: > > I assume w/ "incorrect" you mean "is not a legal program". > > It never ceases to amaze me that the Report specifies that some > syntactically legal expressions are NOT programs but you can only > find out (as far as I know) that they are NOT programs by RUNNING > them. (Of course all this means is that compilers and interpreters > accept and deal with 'things' that are not legal programs in the > spirit of a report, though I can't think of another language with > this property.) > Being a dynamic-typed language, a lot of syntactically legal expression are not programs. > -- Matthias > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From matthias at ccs.neu.edu Tue Aug 19 12:45:12 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:07 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <48AAF444.6050508@cs.utah.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <657C5DD6-A1EF-4F99-8FFB-377E18AAEFD3@ccs.neu.edu> <48AAF444.6050508@cs.utah.edu> Message-ID: <403581B0-B2C9-47D8-A00E-62008408436A@ccs.neu.edu> On Aug 19, 2008, at 12:26 PM, Chongkai Zhu wrote: > Matthias Felleisen wrote: >> >> I assume w/ "incorrect" you mean "is not a legal program". >> >> It never ceases to amaze me that the Report specifies that some >> syntactically legal expressions are NOT programs but you can only >> find out (as far as I know) that they are NOT programs by RUNNING >> them. (Of course all this means is that compilers and interpreters >> accept and deal with 'things' that are not legal programs in the >> spirit of a report, though I can't think of another language with >> this property.) >> > > Being a dynamic-typed language, a lot of syntactically legal > expression are not programs. Try harder :-) From d.j.gurnell at gmail.com Tue Aug 19 13:00:12 2008 From: d.j.gurnell at gmail.com (Dave Gurnell) Date: Thu Mar 26 02:26:08 2009 Subject: [plt-scheme] Custom match expanders for eq?, eqv? and equal? Message-ID: <3E921C16-EB9D-4706-9F04-CEE6DF30636B@gmail.com> Hi PLTers, I've often thought an equivalent of "eq?" or "equal?" to be a useful addition for the match library. "?" does more or less what I want but it's a little verbose: (define x 'a) (define y 'b) (match x [(? (cut eq? <> y)) "X is the same as Y."]) What I'd like to see is something like this: (match x [(eq? y) "X is the same as Y."]) I had a play this afternoon and wrote the a module called "my- match.ss" (attached) that redefines eq?, eqv? and equal? to do what I've described above: #lang scheme (require (file "my-match.ss")) ; and so on... Now for my question. By supplying my own versions of these identifiers, I have also changed how they are treated in an expression context (although the end result of using them should be the same). Is it a "Bad Thing" (TM) to do this to identifiers that are so fundamental to the core of Scheme? Should I rename these guys, or make sure I only ever require them with a prefix? Many thanks, -- Dave ; my-match.ss ==================================== #lang scheme (require srfi/26) ; Match expanders -------------------------------- ; (_ expr pattern ...) (define-match-expander match:eq? (syntax-rules () [(_ value pattern ...) (? (cut eq? <> value) pattern ...)]) eq?) ; (_ expr pattern ...) (define-match-expander match:eqv? (syntax-rules () [(_ value pattern ...) (? (cut eqv? <> value) pattern ...)]) eqv?) ; (_ expr pattern ...) (define-match-expander match:equal? (syntax-rules () [(_ value pattern ...) (? (cut equal? <> value) pattern ...)]) equal?) ; Provide statements ----------------------------- (provide (rename-out [match:eq? eq?] [match:eqv? eqv?] [match:equal? equal?])) -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080819/d02835ee/attachment.htm From aghuloum at cs.indiana.edu Tue Aug 19 13:24:16 2008 From: aghuloum at cs.indiana.edu (Abdulaziz Ghuloum) Date: Thu Mar 26 02:26:08 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <657C5DD6-A1EF-4F99-8FFB-377E18AAEFD3@ccs.neu.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <657C5DD6-A1EF-4F99-8FFB-377E18AAEFD3@ccs.neu.edu> Message-ID: <56E4E7E1-A28E-4666-AD32-479BA0306CC4@cs.indiana.edu> On Aug 19, 2008, at 8:19 AM, Matthias Felleisen wrote: > I assume w/ "incorrect" you mean "is not a legal program". Correct. > It never ceases to amaze me that the Report specifies that some > syntactically legal expressions are NOT programs but you can only > find out (as far as I know) that they are NOT programs by RUNNING > them. (Of course all this means is that compilers and interpreters > accept and deal with 'things' that are not legal programs in the > spirit of a report, though I can't think of another language with > this property.) It goes by the same spirit in which the Report specifies that some S-expressions (a.k.a. datum) are NOT syntactically legal (as programs) but you can only find out that they are NOT syntactically legal by EXPANDING* them. Scheme is not unique in this aspect (e.g., C++ can only be syntactically verified by expanding the templates). Aziz,,, [*] expanding a program means running it through the expander which is a sort-of evaluator whose input is an S-expression with a suitable environment and whose output is a syntactically legal expanded program. From samth at ccs.neu.edu Tue Aug 19 13:38:26 2008 From: samth at ccs.neu.edu (Sam TH) Date: Thu Mar 26 02:26:08 2009 Subject: [plt-scheme] Custom match expanders for eq?, eqv? and equal? In-Reply-To: <3E921C16-EB9D-4706-9F04-CEE6DF30636B@gmail.com> References: <3E921C16-EB9D-4706-9F04-CEE6DF30636B@gmail.com> Message-ID: <63bb19ae0808191038v6fb6c42doc914a933fcf38ef6@mail.gmail.com> I typically use `==' for this, to mean your `equal?'. When I need a different comparison, I just use `?', since that's pretty rare. I would avoid changing the meaning of `eq?' etc, just because it potentially makes it harder to read your code. sam th On Tue, Aug 19, 2008 at 1:00 PM, Dave Gurnell wrote: > Hi PLTers, > I've often thought an equivalent of "eq?" or "equal?" to be a useful > addition for the match library. "?" does more or less what I want but it's a > little verbose: > (define x 'a) > (define y 'b) > (match x > [(? (cut eq? <> y)) "X is the same as Y."]) > What I'd like to see is something like this: > (match x > [(eq? y) "X is the same as Y."]) > I had a play this afternoon and wrote the a module called "my-match.ss" > (attached) that redefines eq?, eqv? and equal? to do what I've described > above: > #lang scheme > > (require (file "my-match.ss")) > > ; and so on... > Now for my question. By supplying my own versions of these identifiers, I > have also changed how they are treated in an expression context (although > the end result of using them should be the same). Is it a "Bad Thing" (TM) > to do this to identifiers that are so fundamental to the core of Scheme? > Should I rename these guys, or make sure I only ever require them with a > prefix? > Many thanks, > -- Dave > ; my-match.ss ==================================== > #lang scheme > (require srfi/26) > ; Match expanders -------------------------------- > ; (_ expr pattern ...) > (define-match-expander match:eq? > (syntax-rules () > [(_ value pattern ...) > (? (cut eq? <> value) pattern ...)]) > eq?) > ; (_ expr pattern ...) > (define-match-expander match:eqv? > (syntax-rules () > [(_ value pattern ...) > (? (cut eqv? <> value) pattern ...)]) > eqv?) > ; (_ expr pattern ...) > (define-match-expander match:equal? > (syntax-rules () > [(_ value pattern ...) > (? (cut equal? <> value) pattern ...)]) > equal?) > ; Provide statements ----------------------------- > (provide (rename-out [match:eq? eq?] > [match:eqv? eqv?] > [match:equal? equal?])) > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > -- sam th samth@ccs.neu.edu From matthias at ccs.neu.edu Tue Aug 19 14:42:39 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:08 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <56E4E7E1-A28E-4666-AD32-479BA0306CC4@cs.indiana.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <657C5DD6-A1EF-4F99-8FFB-377E18AAEFD3@ccs.neu.edu> <56E4E7E1-A28E-4666-AD32-479BA0306CC4@cs.indiana.edu> Message-ID: On Aug 19, 2008, at 1:24 PM, Abdulaziz Ghuloum wrote: > Scheme is not unique in this aspect (e.g., C++ can only be > syntactically verified > by expanding the templates). Interesting. I had never realized that C++ is in exactly the same boat as Scheme. Or is Scheme in the same boat as C++ since the items I am referring to date back to 1984-1986? In either case, it is nice to know that we're not alone and that we can always point to C++ as a comparably defined language. -- Matthias From jmarshall at alum.mit.edu Tue Aug 19 17:48:36 2008 From: jmarshall at alum.mit.edu (Joe Marshall) Date: Thu Mar 26 02:26:09 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> Message-ID: On Tue, Aug 19, 2008 at 7:44 AM, Abdulaziz Ghuloum wrote: > > On Aug 19, 2008, at 7:10 AM, Matthew Flatt wrote: > >> The R5RS/R6RS `letrec' is different, and the result with that other >> `letrec' should be #f: I've always thought this was a wart in the language. > > An R6RS implementation may (or may not) raise an &assertion when the > continuation is invoked the second time, right? Ugh. That's worse than the SET! expansion. It seems to me that Matthias's derivation is the `right way' and how it `should be done'. The SET! expansion seems way too New Jersey, and just legislating that `legal programs' aren't allowed to check is heinous. (define (foo) (if (zero? (modulo (real-time-clock) 2)) (call/cc list) #t)) (letrec ((x (foo))) ....) Now I have a program that's `legal' half the time. -- ~jrm From cce at ccs.neu.edu Tue Aug 19 18:06:49 2008 From: cce at ccs.neu.edu (Carl Eastlund) Date: Thu Mar 26 02:26:09 2009 Subject: [plt-scheme] Custom match expanders for eq?, eqv? and equal? In-Reply-To: <63bb19ae0808191038v6fb6c42doc914a933fcf38ef6@mail.gmail.com> References: <3E921C16-EB9D-4706-9F04-CEE6DF30636B@gmail.com> <63bb19ae0808191038v6fb6c42doc914a933fcf38ef6@mail.gmail.com> Message-ID: <990e0c030808191506q77c2cf0el51cb82c746abcd20@mail.gmail.com> Could we add eq?, eqv?, and equal? as builtin match bindings, the way we already interpret list and cons as patterns? Is there a way for users to add match interpretations for existing bindings? Its a weird use of syntax, but it has its uses... it would be nice to say, for instance, (make-posn x y) instead of (struct posn (x y)). Or, for that matter, (list* a b) instead of (list-rest a b). Right now, if a constructor exists without the forethought of also adding it as a match expander, we're out of luck. --Carl On Tue, Aug 19, 2008 at 1:38 PM, Sam TH wrote: > I typically use `==' for this, to mean your `equal?'. When I need a > different comparison, I just use `?', since that's pretty rare. > > I would avoid changing the meaning of `eq?' etc, just because it > potentially makes it harder to read your code. > > sam th > > On Tue, Aug 19, 2008 at 1:00 PM, Dave Gurnell wrote: >> Hi PLTers, >> I've often thought an equivalent of "eq?" or "equal?" to be a useful >> addition for the match library. "?" does more or less what I want but it's a >> little verbose: >> (define x 'a) >> (define y 'b) >> (match x >> [(? (cut eq? <> y)) "X is the same as Y."]) >> What I'd like to see is something like this: >> (match x >> [(eq? y) "X is the same as Y."]) >> I had a play this afternoon and wrote the a module called "my-match.ss" >> (attached) that redefines eq?, eqv? and equal? to do what I've described >> above: >> #lang scheme >> >> (require (file "my-match.ss")) >> >> ; and so on... >> Now for my question. By supplying my own versions of these identifiers, I >> have also changed how they are treated in an expression context (although >> the end result of using them should be the same). Is it a "Bad Thing" (TM) >> to do this to identifiers that are so fundamental to the core of Scheme? >> Should I rename these guys, or make sure I only ever require them with a >> prefix? >> Many thanks, >> -- Dave >> ; my-match.ss ==================================== >> #lang scheme >> (require srfi/26) >> ; Match expanders -------------------------------- >> ; (_ expr pattern ...) >> (define-match-expander match:eq? >> (syntax-rules () >> [(_ value pattern ...) >> (? (cut eq? <> value) pattern ...)]) >> eq?) >> ; (_ expr pattern ...) >> (define-match-expander match:eqv? >> (syntax-rules () >> [(_ value pattern ...) >> (? (cut eqv? <> value) pattern ...)]) >> eqv?) >> ; (_ expr pattern ...) >> (define-match-expander match:equal? >> (syntax-rules () >> [(_ value pattern ...) >> (? (cut equal? <> value) pattern ...)]) >> equal?) >> ; Provide statements ----------------------------- >> (provide (rename-out [match:eq? eq?] >> [match:eqv? eqv?] >> [match:equal? equal?])) >> From mflatt at cs.utah.edu Tue Aug 19 19:17:07 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:09 2009 Subject: [plt-scheme] decompiler for bytecode Message-ID: <20080819231709.93EA8650094@mail-svr1.cs.utah.edu> In case you ever wonder what the compiler and bytecode optimizer does to your code, mzc now supports a `--decompile' mode to convert a ".zo" file back into Scheme (sort of). For example, if "ex.ss" contains #lang scheme (define x (+ 1 2)) then laptop% mzc ex.ss mzc v4.1.0.1 [3m], Copyright (c) 2004-2008 PLT Scheme Inc. "ex.ss": making "/private/tmp/ex.ss" [output to "./compiled/ex_ss.zo"] laptop% mzc --decompile compiled/ex_ss.zo mzc v4.1.0.1 [3m], Copyright (c) 2004-2008 PLT Scheme Inc. (begin (module ex .... (define-values (_x) '3))) confirms that the compiler knows how to fold `(+ 1 2)' to `3'. Since the decompiler is intended to help explain performance, its output includes annotations like `#%sfs-clear' and `#%checked'. Those annotations are no-ops if you read the code as Scheme, but they reflect specific steps taken in the JITted form of the bytecode. Similarly, `lambda' forms are annotated as `#%closed' when they are implemented as constant closures; otherwise, they're annotated with captured variables. Primitive operations that will be inlined by the JIT are annotated with `#%in'. See the mzc documentation for details: http://docs.plt-scheme.org/mzc/decompile.html Currently, the decompiler doesn't reconstruct syntax objects, though it shows a partially-decoded form that can give you a sense of what the syntax objects contain and how much space they consume. For that and other reasons, the decompiler's output currently cannot be fed back into the evaluator. Matthew From geoff at knauth.org Tue Aug 19 20:27:29 2008 From: geoff at knauth.org (Geoff Knauth) Date: Thu Mar 26 02:26:09 2009 Subject: [plt-scheme] scheme in java In-Reply-To: References: Message-ID: <5A2A9E18-31EF-4692-B939-7F17F1CE4F6B@knauth.org> On Aug 17, 2008, at 08:35, Fran?ois Schwarzentruber wrote: > Do you know if it is possible to embed a Scheme interpreter into a > Java application ? If you really need to use Java, try: http://jscheme.sourceforge.net/jscheme/main.html Then on Aug 17, 2008, at 10:18, Shriram Krishnamurthi wrote to Fran?ois: > I saw on your Web page that you want to do this to deploy programs on > the Web. But Scheme already has a great Web server interface. So why > would you want to mess w/ Java? See the tutorial that Danny and Jay > have developed, if you need help getting started. Great suggestion. From grettke at acm.org Tue Aug 19 22:43:53 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:09 2009 Subject: [plt-scheme] Re: answers from htdp In-Reply-To: References: <867iae5y2z.fsf@gmail.com> <756daca50808181213i63f8885dv8146b059a69d928@mail.gmail.com> Message-ID: <756daca50808191943g6db4bd66v3e37d0687b3f7e21@mail.gmail.com> > I'm on the beach in Rio Please enjoy the beach and don't worry about things like people wondering if somehow the lack of answers impairs their learning. From DekuDekuplex at Yahoo.com Wed Aug 20 01:22:10 2008 From: DekuDekuplex at Yahoo.com (Benjamin L.Russell) Date: Thu Mar 26 02:26:09 2009 Subject: [plt-scheme] Re: Any tips for avoiding intermittent freezing when navigating file system directories with mounted network volumes in DrScheme? References: <74jia4hvk0ena11cvch0neuq7hlfca7jh5@4ax.com> <74jia4hvk0ena11cvch0neuq7hlfca7jh5-e09XROE/p8c@public.gmane.org> <756daca50808181220r2e6dfd8fqaecdab70748016de@mail.gmail.com> Message-ID: <5bana45vi6vddqituc6fhl434psijor8rv@4ax.com> On Mon, 18 Aug 2008 14:20:27 -0500, "Grant Rettke" wrote: >> Does anybody have any tips on avoiding this intermittent freezing when >> navigating local file system directories on a system with mounted >> network volumes? > >Just wondering, is this a general Windows issue or a DrScheme specific issue? > >My machine at work has horrible, terrible hanging issues whenever I >use Explorer. Since I can navigate those same directories in Windows Explorer and other applications without any problems, but the intemittent freezing always occurs in DrScheme, this issue appears to be DrScheme-specific. -- Benjamin L. Russell From gresvol at gmail.com Wed Aug 20 03:06:51 2008 From: gresvol at gmail.com (Sergey Lovtsov) Date: Thu Mar 26 02:26:09 2009 Subject: [plt-scheme] Division error in DrScheme v.4.1 Message-ID: <48ABC28B.5000908@gmail.com> Hello to all! I'm just a beginner in Scheme (studying HtDP now) and now i have a problem with DrScheme. When i'm calculating an expression wich returns integer values, like (/ 45 5) or (/ 32 8), all goes just fine. But when i'm operating with fractions, like (/ 4 23) or (* .04 6), DrScheme returns me an error instead and crushes, error is ------ get-extent in snip%, extracting return value via box, extracting boxed argument: expected argument of type ; given -1.0 === context === C:\Program Files\PLT\collects\framework\private\text.ss:1667:4: do-insertion method in ...work/private/text.ss:1351:2 C:\Program Files\PLT\collects\framework\private\text.ss:1661:9 ----- How can i solve this? From norman at astro.gla.ac.uk Wed Aug 20 05:37:20 2008 From: norman at astro.gla.ac.uk (Norman Gray) Date: Thu Mar 26 02:26:10 2009 Subject: [plt-scheme] scheme in java In-Reply-To: <5A2A9E18-31EF-4692-B939-7F17F1CE4F6B@knauth.org> References: <5A2A9E18-31EF-4692-B939-7F17F1CE4F6B@knauth.org> Message-ID: <8612A478-48B6-462E-A65F-308491B4523C@astro.gla.ac.uk> On 2008 Aug 20, at 01:27, Geoff Knauth wrote: > On Aug 17, 2008, at 08:35, Fran?ois Schwarzentruber wrote: >> Do you know if it is possible to embed a Scheme interpreter into a >> Java application ? > > If you really need to use Java, try: > > http://jscheme.sourceforge.net/jscheme/main.html Another possibility is SISC . It's worked well for me, specifically to write servlets which live inside Tomcat or Jetty. Norman -- Norman Gray : http://nxg.me.uk Physics and Astronomy, University of Leicester From smade4 at gmail.com Wed Aug 20 07:36:44 2008 From: smade4 at gmail.com (glauber M4) Date: Thu Mar 26 02:26:10 2009 Subject: Resp.: [plt-scheme] Re: answers from htdp In-Reply-To: <756daca50808191943g6db4bd66v3e37d0687b3f7e21@mail.gmail.com> References: <867iae5y2z.fsf@gmail.com> <756daca50808181213i63f8885dv8146b059a69d928@mail.gmail.com> <756daca50808191943g6db4bd66v3e37d0687b3f7e21@mail.gmail.com> Message-ID: <57ec141d0808200436x4cf8dbd7r71fa06894d05b24e@mail.gmail.com> 2008/8/19, Grant Rettke : >> I'm on the beach in Rio > Cool, if you like hikeing try going up to the "pedra da gavea"(gavea's stone) very nice view of the south region. People usually jump with "delta-wings?"(I'm not sure about the english name) down of it. Dont go alone though, risky of being robbed :) . Cheers, glauber. From ancmin at gmail.com Tue Aug 19 06:51:58 2008 From: ancmin at gmail.com (=?ISO-8859-1?Q?Fran=E7ois_Schwarzentruber?=) Date: Thu Mar 26 02:26:10 2009 Subject: [plt-scheme] scheme in java In-Reply-To: <756daca50808170838x711a834em80ac4049c5e60921@mail.gmail.com> References: <756daca50808170838x711a834em80ac4049c5e60921@mail.gmail.com> Message-ID: Thanks ! But in fact, I read http://docs.plt-scheme.org/web-server/index.html and it seems interesting. Now, I decided to use JScheme. As I said to Shriram, it is an interpreter Scheme one can use in java. Simply write : JScheme myScheme =new JScheme(); system.out.println( myScheme.eval("(+ 1 2)").toString()); And I don't know if I am going to code my entire application in Scheme as it said in http://docs.plt-scheme.org/web-server/index.html ("can be used to develop Web applications in Scheme."). For the GUI, I prefer to use a object oriented language. For the engine, I prefer a functionnal language where data and programs have the same structures. Any way, thanks for your answers. I will try to convince the computer science department of my university to teach Scheme and to use DrScheme, because... Scheme is a work of art. Best, Fran?ois 2008/8/17 Grant Rettke > >> 2) What do you mean by exactly "pretty big scheme" ? Is it R6RS ? > > > > A better name would be "kitchen sink Scheme": it's Standard Scheme > > plus all the usual PLT additions (structures, LOCAL, better names for > > some primitives, etc, etc). The Help Desk (under the Help menu) will > > give you more info. > > If Fran?ois wants to use the PLT web server, would he be better off > moving his code from "pretty big" to "#lang scheme using modules"? > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080819/8bf4f939/attachment.html From will at ccs.neu.edu Tue Aug 19 22:37:21 2008 From: will at ccs.neu.edu (William D Clinger) Date: Thu Mar 26 02:26:11 2009 Subject: [plt-scheme] ANN: Call for registration: 2008 Workshop on Scheme and Functional Programming Message-ID: The 2008 Workshop on Scheme and Functional Programming will be held * in Victoria, British Columbia, * on Saturday, 20 September, two days before ICFP. Discounted early registration closes Wednesday, 20 August. The workshop program is online at http://www.ccs.neu.edu/home/will/scheme2008/program.html For more details, see http://www.schemeworkshop.org/2008/ Will Clinger workshop chair From grettke at acm.org Wed Aug 20 09:37:59 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:11 2009 Subject: [plt-scheme] Division error in DrScheme v.4.1 In-Reply-To: <48ABC28B.5000908@gmail.com> References: <48ABC28B.5000908@gmail.com> Message-ID: <756daca50808200637q43f608dcp8b5cd676d1962741@mail.gmail.com> > When i'm calculating an expression wich returns integer values, like (/ 45 > 5) or (/ 32 8), all goes just fine. But when i'm operating with fractions, > like (/ 4 23) or (* .04 6), DrScheme returns me an error instead and > crushes, error is I'm running DrScheme/mzscheme v4.1 [3m], when I choose the "Beginning Student" language and apply those functions I get: > (/ 4 23) 0.1739130434782608695652 > (* .04 6) 0.24 > From grettke at acm.org Wed Aug 20 09:39:01 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:11 2009 Subject: [plt-scheme] scheme in java In-Reply-To: <8612A478-48B6-462E-A65F-308491B4523C@astro.gla.ac.uk> References: <5A2A9E18-31EF-4692-B939-7F17F1CE4F6B@knauth.org> <8612A478-48B6-462E-A65F-308491B4523C@astro.gla.ac.uk> Message-ID: <756daca50808200639l46abeffbp35cfe4ec351a96cf@mail.gmail.com> > Another possibility is SISC . It's worked well for > me, specifically to write servlets which live inside Tomcat or Jetty. They make a point to mention that they implement the whole R5RS spec, *including* continuations. I take it that is something that the other Scheme on the JVM implementers avoid. Why? From matthias at ccs.neu.edu Wed Aug 20 09:45:14 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:11 2009 Subject: [plt-scheme] Division error in DrScheme v.4.1 In-Reply-To: <48ABC28B.5000908@gmail.com> References: <48ABC28B.5000908@gmail.com> Message-ID: I can't recreate your error. Can you send instructions on how to get there from a plain drscheme start? Thanks!! -- Matthias On Aug 20, 2008, at 3:06 AM, Sergey Lovtsov wrote: > Hello to all! I'm just a beginner in Scheme (studying HtDP now) and > now i have a problem with DrScheme. > When i'm calculating an expression wich returns integer values, > like (/ 45 5) or (/ 32 8), all goes just fine. But when i'm > operating with fractions, like (/ 4 23) or (* .04 6), DrScheme > returns me an error instead and crushes, error is > > ------ > get-extent in snip%, extracting return value via box, extracting > boxed argument: expected argument of type ; > given -1.0 > > === context === > C:\Program Files\PLT\collects\framework\private\text.ss:1667:4: do- > insertion method in ...work/private/text.ss:1351:2 > C:\Program Files\PLT\collects\framework\private\text.ss:1661:9 > ----- > > How can i solve this? > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From cobbe at ccs.neu.edu Wed Aug 20 09:56:02 2008 From: cobbe at ccs.neu.edu (Richard Cobbe) Date: Thu Mar 26 02:26:11 2009 Subject: [plt-scheme] Division error in DrScheme v.4.1 In-Reply-To: <756daca50808200637q43f608dcp8b5cd676d1962741@mail.gmail.com> References: <48ABC28B.5000908@gmail.com> <756daca50808200637q43f608dcp8b5cd676d1962741@mail.gmail.com> Message-ID: <20080820135602.GB993@perdita.local> On Wed, Aug 20, 2008 at 08:37:59AM -0500, Grant Rettke wrote: > > When i'm calculating an expression wich returns integer values, like (/ 45 > > 5) or (/ 32 8), all goes just fine. But when i'm operating with fractions, > > like (/ 4 23) or (* .04 6), DrScheme returns me an error instead and > > crushes, error is > > I'm running DrScheme/mzscheme v4.1 [3m], when I choose the "Beginning > Student" language and apply those functions I get: > > > (/ 4 23) > 0.1739130434782608695652 > > (* .04 6) > 0.24 If you open the "Choose Language" dialog and click on "Show Details", you'll see an option to "Use decimal notation for rationals", which is clearly selected in your case. If memory serves correctly, the teaching languages default to using decimal notation for rationals, because decimals are easier to read than a ratio of two ~120-digit relatively-prime integers. (This situation arose several times in teaching labs.) Changing the output printer saves us having to explain exact->inexact, but at the cost of being able to show off DrScheme's arbitrary-precision rationals. I think it's a net win, myself. Richard From gresvol at gmail.com Wed Aug 20 10:31:58 2008 From: gresvol at gmail.com (Sergey Lovtsov) Date: Thu Mar 26 02:26:11 2009 Subject: [plt-scheme] Division error in DrScheme v.4.1 Message-ID: <48AC2ADE.8010005@gmail.com> Thank you for your help! I have fix the problem, it seems that something was wrong with plt-prefs.ss file. I've deleted it and, after that, DrScheme has created new plt-prefs.ss with default preferences. So, everything is ok now. I don't know what caused this problem, the only thing i've changed in DrScheme is the font. From aghuloum at cs.indiana.edu Wed Aug 20 11:20:04 2008 From: aghuloum at cs.indiana.edu (Abdulaziz Ghuloum) Date: Thu Mar 26 02:26:12 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> Message-ID: On Aug 19, 2008, at 2:48 PM, Joe Marshall wrote: > On Tue, Aug 19, 2008 at 7:44 AM, Abdulaziz Ghuloum > wrote: >> >> On Aug 19, 2008, at 7:10 AM, Matthew Flatt wrote: >> >>> The R5RS/R6RS `letrec' is different, and the result with that >>> other `letrec' should be #f: > > I've always thought this was a wart in the language. Fine, but how else would letrec be implements in order to provide the full generality of letrec (letrec is not fix) and at the same time obey the other rules of the imperative, strict, call-by-value language known as Scheme? E.g., how would you evaluate (letrec ([x (list (lambda () x))]) (eq? x ((car x)))) ; => #t without a side effect? >> An R6RS implementation may (or may not) raise an &assertion when >> the continuation is invoked the second time, right? > > Ugh. That's worse than the SET! expansion. Returning to an continuation may (1) rebind the variable as Matthias showed, (2) assign to an already existing binding as Matthew showed, or (3) raise an assertion as the report suggests. Rebinding is not always possible since there is no known general letrec transformation that eliminates side effects. Options 2 and 3 are always possible for all shapes of letrec, but they're ugly as you suggest. Where does that leave us? Aziz,,, From matthias at ccs.neu.edu Wed Aug 20 11:35:58 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:12 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> Message-ID: <51732291-5D52-464F-9816-8447469B2037@ccs.neu.edu> The reason letrec has an "expansive" semantics (let + set!) is so that we can use abstractions even for the definition of mutually recursive functions: (letrec ((co1 (make-coroutine-for-game "Matthias")) (co2 (make-coroutine-for-game "Abdulaziz"))) (coroutine-start co1 (pick-card))) is the kind of "poem" that we used (at Indiana) to justify the EXPRESSION rhs for letrec. Reality is, we do use this power on rare occasions but perhaps we should admit by now, these occasions are rare and the cost is high. How about: 1. LETREC RHS must be syntactic values. (Note: ML got away with this for POLY LET after Andrew showed that there were like fewer than 10 uses in 100 Kloc of SML code.) 2. LETREC RHS must be "provably equal" to values without effects. That is, we allow beta_value and nothing else. 1b. LETREC RHS must be "expansionably equal" (macro expansion) to values. That's probably the proper compromise. Nice, easy spec and we won't miss much of the other opportunities. -- Matthias P.S. ETA expansion doesn't work for the coroutine example because the result isn't necessarily a lambda function. So Andrew's trick is out. On Aug 20, 2008, at 11:20 AM, Abdulaziz Ghuloum wrote: > > On Aug 19, 2008, at 2:48 PM, Joe Marshall wrote: > >> On Tue, Aug 19, 2008 at 7:44 AM, Abdulaziz Ghuloum >> wrote: >>> >>> On Aug 19, 2008, at 7:10 AM, Matthew Flatt wrote: >>> >>>> The R5RS/R6RS `letrec' is different, and the result with that >>>> other `letrec' should be #f: >> >> I've always thought this was a wart in the language. > > Fine, but how else would letrec be implements in order to provide > the full generality of letrec (letrec is not fix) and at the same > time obey the other rules of the imperative, strict, call-by-value > language known as Scheme? E.g., how would you evaluate > > (letrec ([x (list (lambda () x))]) > (eq? x ((car x)))) ; => #t > > without a side effect? > >>> An R6RS implementation may (or may not) raise an &assertion when >>> the continuation is invoked the second time, right? >> >> Ugh. That's worse than the SET! expansion. > > Returning to an continuation may (1) rebind the variable > as Matthias showed, (2) assign to an already existing binding as > Matthew showed, or (3) raise an assertion as the report suggests. > > Rebinding is not always possible since there is no known general > letrec transformation that eliminates side effects. Options 2 > and 3 are always possible for all shapes of letrec, but they're > ugly as you suggest. Where does that leave us? > > Aziz,,, > From grettke at acm.org Wed Aug 20 11:50:02 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:12 2009 Subject: [plt-scheme] Re: answers from htdp In-Reply-To: <756daca50808191943g6db4bd66v3e37d0687b3f7e21@mail.gmail.com> References: <867iae5y2z.fsf@gmail.com> <756daca50808181213i63f8885dv8146b059a69d928@mail.gmail.com> <756daca50808191943g6db4bd66v3e37d0687b3f7e21@mail.gmail.com> Message-ID: <756daca50808200850r3b2098f9jda1d125c375a13a@mail.gmail.com> On Tue, Aug 19, 2008 at 9:43 PM, Grant Rettke wrote: >> I'm on the beach in Rio > > Please enjoy the beach and don't worry about things like people > wondering if somehow the lack of answers impairs their learning. Just wanted to clarify my comment here. My original question was supposed to ask "Are there any observable drawbacks of not providing answers to students?". I figured that it was obvious that providing them wouldn't work because why do the work if you've got that answers. In my case, I am interested in the answer because we are starting a HTDP study group at work, and, we don't have the answers. Since management was interested in "grading" the work done by everyone, it did make me wonder what we would gain by having the answers. Ultimately, since I am doing this "nights and weekends" (in other words on my own initiative), I chose not to make the time to grade homework (I think it would take too much time that I don't want to give it). So *that* is what drove the question, but, I don't think we, non-classroom-students, are necessarily alone in suspecting that we aren't missing anything ; though the original poster comment made me wonder what we *could* be missing. From samth at ccs.neu.edu Wed Aug 20 11:57:03 2008 From: samth at ccs.neu.edu (Sam TH) Date: Thu Mar 26 02:26:12 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <51732291-5D52-464F-9816-8447469B2037@ccs.neu.edu> References: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <51732291-5D52-464F-9816-8447469B2037@ccs.neu.edu> Message-ID: <63bb19ae0808200857w4fb81296y324239159a5135cb@mail.gmail.com> On Wed, Aug 20, 2008 at 11:35 AM, Matthias Felleisen wrote: > > The reason letrec has an "expansive" semantics (let + set!) is so that we > can use abstractions even for the definition of mutually recursive > functions: > > (letrec ((co1 (make-coroutine-for-game "Matthias")) > (co2 (make-coroutine-for-game "Abdulaziz"))) > (coroutine-start co1 (pick-card))) > > is the kind of "poem" that we used (at Indiana) to justify the EXPRESSION > rhs for letrec. > > Reality is, we do use this power on rare occasions but perhaps we should > admit by now, these occasions are rare and the cost is high. > > How about: > > 1. LETREC RHS must be syntactic values. (Note: ML got away with this for > POLY LET after Andrew showed that there were like fewer than 10 uses in 100 > Kloc of SML code.) > > 2. LETREC RHS must be "provably equal" to values without effects. That is, > we allow beta_value and nothing else. > > 1b. LETREC RHS must be "expansionably equal" (macro expansion) to values. > That's probably the proper compromise. > > Nice, easy spec and we won't miss much of the other opportunities. -- > Matthias Note that this rules out the following code: (define (f x) (define local-var (add1 x)) (define (do-stuff . args) ...) (do-stuff x local-var)) which I think would be a big loss. What precisely are we gaining by restricting `letrec'? Thanks, -- sam th samth@ccs.neu.edu From matthias at ccs.neu.edu Wed Aug 20 11:58:39 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:12 2009 Subject: [plt-scheme] Re: answers from htdp In-Reply-To: <756daca50808200850r3b2098f9jda1d125c375a13a@mail.gmail.com> References: <867iae5y2z.fsf@gmail.com> <756daca50808181213i63f8885dv8146b059a69d928@mail.gmail.com> <756daca50808191943g6db4bd66v3e37d0687b3f7e21@mail.gmail.com> <756daca50808200850r3b2098f9jda1d125c375a13a@mail.gmail.com> Message-ID: Grading the stuff yourself is so antiquated. Out source it! -- Matthias :-) On Aug 20, 2008, at 11:50 AM, Grant Rettke wrote: > > > On Tue, Aug 19, 2008 at 9:43 PM, Grant Rettke wrote: >>> I'm on the beach in Rio >> >> Please enjoy the beach and don't worry about things like people >> wondering if somehow the lack of answers impairs their learning. > > Just wanted to clarify my comment here. > > My original question was supposed to ask "Are there any observable > drawbacks of not providing answers to students?". I figured that it > was obvious that providing them wouldn't work because why do the work > if you've got that answers. In my case, I am interested in the answer > because we are starting a HTDP study group at work, and, we don't have > the answers. Since management was interested in "grading" the work > done by everyone, it did make me wonder what we would gain by having > the answers. Ultimately, since I am doing this "nights and weekends" > (in other words on my own initiative), I chose not to make the time to > grade homework (I think it would take too much time that I don't want > to give it). So *that* is what drove the question, but, I don't think > we, non-classroom-students, are necessarily alone in suspecting that > we aren't missing anything ; though the original poster comment made > me wonder what we *could* be missing. > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From matthias at ccs.neu.edu Wed Aug 20 12:00:00 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:12 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <63bb19ae0808200857w4fb81296y324239159a5135cb@mail.gmail.com> References: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <51732291-5D52-464F-9816-8447469B2037@ccs.neu.edu> <63bb19ae0808200857w4fb81296y324239159a5135cb@mail.gmail.com> Message-ID: <296A30B9-C200-4E57-8D92-562E5A23509D@ccs.neu.edu> On Aug 20, 2008, at 11:57 AM, Sam TH wrote: > Note that this rules out the following code: > > (define (f x) > (define local-var (add1 x)) > (define (do-stuff . args) ...) > (do-stuff x local-var)) > > which I think would be a big loss. What precisely are we gaining by > restricting `letrec'? Don't get me started on internal define. How about an Algol semantics for this kind of block. You get your cake, and I eat it. Or something like that. -- Matthias From jmarshall at alum.mit.edu Wed Aug 20 14:27:56 2008 From: jmarshall at alum.mit.edu (Joe Marshall) Date: Thu Mar 26 02:26:13 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> Message-ID: On Wed, Aug 20, 2008 at 8:20 AM, Abdulaziz Ghuloum wrote: > > On Aug 19, 2008, at 2:48 PM, Joe Marshall wrote: > >> On Tue, Aug 19, 2008 at 7:44 AM, Abdulaziz Ghuloum >> wrote: >>> >>> On Aug 19, 2008, at 7:10 AM, Matthew Flatt wrote: >>> >>>> The R5RS/R6RS `letrec' is different, and the result with that >>>> other `letrec' should be #f: >> >> I've always thought this was a wart in the language. > > Fine, but how else would letrec be implements in order to provide > the full generality of letrec (letrec is not fix) and at the same > time obey the other rules of the imperative, strict, call-by-value > language known as Scheme? E.g., how would you evaluate > > (letrec ([x (list (lambda () x))]) > (eq? x ((car x)))) ; => #t > > without a side effect? The thing that I thought was a wart was that letrec was *required* to expand as if it were a let followed by a set even in cases where it could have been accomplished by a fixed-point computation. You are forced to be inelegant even when you don't need to be. >>> An R6RS implementation may (or may not) raise an &assertion when >>> the continuation is invoked the second time, right? >> >> Ugh. That's worse than the SET! expansion. > > Returning to an continuation may (1) rebind the variable > as Matthias showed, (2) assign to an already existing binding as > Matthew showed, or (3) raise an assertion as the report suggests. > > Rebinding is not always possible since there is no known general > letrec transformation that eliminates side effects. Options 2 > and 3 are always possible for all shapes of letrec, but they're > ugly as you suggest. Where does that leave us? Option 4: An implementation *may* implement letrec as a binding followed by an assignment, or it *may* implement letrec as a fixed point, or it *may* mix the two. Returning to an continuation may cause re-assignment or rebinding at the discretion of the implementation. Alternatively, the right hand side of the letrec could be restricted. I rarely use letrec (or internal define) for arbitrary values. I almost always use letrec (or internal define) for procedures only. If this were the case, then you'd have to explicitly have a side effect in the code above: (let ((x (list #f))) (set-car! x (lambda () x)) (eq? x ((car x)))) Which, frankly, is a better way of writing this than the letrec because it is obvious that some side-effecting is going on in order to create magic circular structure such that (eq? x ((car x))) could evaluate to #t. -- ~jrm From jmarshall at alum.mit.edu Wed Aug 20 14:33:24 2008 From: jmarshall at alum.mit.edu (Joe Marshall) Date: Thu Mar 26 02:26:13 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <63bb19ae0808200857w4fb81296y324239159a5135cb@mail.gmail.com> References: <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <51732291-5D52-464F-9816-8447469B2037@ccs.neu.edu> <63bb19ae0808200857w4fb81296y324239159a5135cb@mail.gmail.com> Message-ID: On Wed, Aug 20, 2008 at 8:57 AM, Sam TH wrote: > > Note that this rules out the following code: > > (define (f x) > (define local-var (add1 x)) > (define (do-stuff . args) ...) > (do-stuff x local-var)) > > which I think would be a big loss. I don't consider that a big loss. It's trivial to change this to either (define (f x) (let ((local-var (add1 x))) (define (do-stuff . args) ...) ;; if you refer to local-var freely in here (do-stuff x local-var))) or (define (f x) (define (do-stuff . args) ...) ;; if local-var is not used in here (let ((local-var (add1 x))) (do-stuff x local-var))) > What precisely are we gaining by restricting `letrec'? The ability to write mutally-recursive programs in a side-effect free subset of the language. What precisely are we losing by allowing arbitrary expresions on the right hand side? -- ~jrm From matthias at ccs.neu.edu Wed Aug 20 14:33:31 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:13 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> Message-ID: <5BC924B7-EB61-4A0E-8C4E-6E2C454F8A3B@ccs.neu.edu> On Aug 20, 2008, at 2:27 PM, Joe Marshall wrote: > Which, frankly, is a better way of writing this than the letrec > because it is obvious that some side-effecting is going on in > order to create magic circular structure such that > (eq? x ((car x))) could evaluate to #t. Amen. From sk at cs.brown.edu Wed Aug 20 15:38:29 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:26:13 2009 Subject: [plt-scheme] scheme in java In-Reply-To: <756daca50808200639l46abeffbp35cfe4ec351a96cf@mail.gmail.com> References: <5A2A9E18-31EF-4692-B939-7F17F1CE4F6B@knauth.org> <8612A478-48B6-462E-A65F-308491B4523C@astro.gla.ac.uk> <756daca50808200639l46abeffbp35cfe4ec351a96cf@mail.gmail.com> Message-ID: Because you'd need to CPS, and that really destroys program structure and potentially also performance. See: http://www.cs.brown.edu/~sk/Publications/Papers/Published/pcmkf-cont-from-gen-stack-insp/ S. On Wed, Aug 20, 2008 at 9:39 AM, Grant Rettke wrote: >> Another possibility is SISC . It's worked well for >> me, specifically to write servlets which live inside Tomcat or Jetty. > > They make a point to mention that they implement the whole R5RS spec, > *including* continuations. I take it that is something that the other > Scheme on the JVM implementers avoid. Why? > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From aghuloum at cs.indiana.edu Wed Aug 20 15:44:21 2008 From: aghuloum at cs.indiana.edu (Abdulaziz Ghuloum) Date: Thu Mar 26 02:26:13 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> Message-ID: <4BAF2B47-302A-407D-AF0B-738E02A03019@cs.indiana.edu> On Aug 20, 2008, at 11:27 AM, Joe Marshall wrote: > Option 4: An implementation *may* implement letrec as a binding > followed by an assignment, or it *may* implement letrec as a > fixed point, or it *may* mix the two. This is precisely what I do in my compiler. > Returning to an continuation > may cause re-assignment or rebinding at the discretion of the > implementation. How is this better than raising an exception? (Note, Ikarus does not raise such exceptions, so, it is far less work for me and far more efficient for Ikarus to not introduce these checks for programs that return more than once to an , but I still don't see that choosing to rebind or to assign depending on the implementation's choice is better than raising an exception) > Alternatively, the right hand side of the letrec could be restricted. No! Any restriction like that invalidates way too many valid and perfectly good programs that I do write all the time. > I rarely use letrec (or internal define) for arbitrary values. I > almost > always use letrec (or internal define) for procedures only. I can't say the same. For example, I consider parameters (i.e., the result of calling make-parameter), record accessors, mutators, constructors, etc., to be procedures even if they're obtained by procedural means (from non-lambda expressions). This is a simple sequence of definitions: (define make-adder (lambda (n) (lambda (m) (+ n m)))) (define add1 (make-adder 1)) Do you never write code like this? > If this > were the case, then you'd have to explicitly have a side effect in > the code above: > > (let ((x (list #f))) > (set-car! x (lambda () x)) > (eq? x ((car x)))) > > Which, frankly, is a better way of writing this than the letrec > because it is obvious that some side-effecting is going on in > order to create magic circular structure such that > (eq? x ((car x))) could evaluate to #t. I agree that this is clearer and that letrec/call-cc tricks are good for puzzles only and are never useful in practice. However, ruling out all non-lambdas or non-trivial expressions from letrec and internal defines is an overkill; especially when the motivation for doing so is just to disallow such puzzles. Aziz,,, From sk at cs.brown.edu Wed Aug 20 15:51:07 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:26:14 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <4BAF2B47-302A-407D-AF0B-738E02A03019@cs.indiana.edu> References: <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <4BAF2B47-302A-407D-AF0B-738E02A03019@cs.indiana.edu> Message-ID: If LOCAL had a slightly less onerous syntax (the current syntax meets one need superbly, but at the cost of some syntactic pain for people writing a fresh LOCAL expression from scratch), would you object to it supplanting LETREC? S. From jmarshall at alum.mit.edu Wed Aug 20 16:03:37 2008 From: jmarshall at alum.mit.edu (Joe Marshall) Date: Thu Mar 26 02:26:14 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <4BAF2B47-302A-407D-AF0B-738E02A03019@cs.indiana.edu> References: <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <4BAF2B47-302A-407D-AF0B-738E02A03019@cs.indiana.edu> Message-ID: On Wed, Aug 20, 2008 at 12:44 PM, Abdulaziz Ghuloum wrote: > > On Aug 20, 2008, at 11:27 AM, Joe Marshall wrote: > >> Option 4: An implementation *may* implement letrec as a binding >> followed by an assignment, or it *may* implement letrec as a >> fixed point, or it *may* mix the two. > > This is precisely what I do in my compiler. > >> Returning to an continuation >> may cause re-assignment or rebinding at the discretion of the >> implementation. > > How is this better than raising an exception? (Note, Ikarus does > not raise such exceptions, so, it is far less work for me and far > more efficient for Ikarus to not introduce these checks for programs > that return more than once to an , but I still don't see that > choosing to rebind or to assign depending on the implementation's > choice is better than raising an exception) It's better than raising an exception because returning to an continuation doesn't necessarily mean your program is broken. If your program doesn't try to do anything `funny' with the bindings, then it shouldn't notice or care if they are re-assigned or rebound and there is no reason to raise an exception. (In other words, I could write a program that worked perfectly well on your compiler and didn't depend on whether things were rebound or re-assigned, yet it wouldn't work at all on someone else's compiler because they raise an exception. (But it *would* work if they were lazy enough not to check.) Or alternatively, someone could perversely depend on that exception and discover it didn't happen on your compiler. > >> Alternatively, the right hand side of the letrec could be restricted. > > No! Any restriction like that invalidates way too many valid and > perfectly good programs that I do write all the time. > >> I rarely use letrec (or internal define) for arbitrary values. I almost >> always use letrec (or internal define) for procedures only. > > I can't say the same. For example, I consider parameters (i.e., > the result of calling make-parameter), record accessors, mutators, > constructors, etc., to be procedures even if they're obtained by > procedural means (from non-lambda expressions). > > This is a simple sequence of definitions: > > (define make-adder (lambda (n) (lambda (m) (+ n m)))) > (define add1 (make-adder 1)) > > Do you never write code like this? Not often. It may be a habit I picked up from working in Common Lisp where you don't have letrec (you have labels, which only allows function binding). It's trivial enough to write (let ((add1 (make-adder 1))) ... (add1 22)) And I find internal defines to be a tiny bit odd. I like the way they look, but the fact that you have to scan them out is distasteful. In my mental model, I see `let' as introducing a binding cell that contains a value. I see internal define as introducing a named routine that I can invoke or return, but not as introducing a `variable' that can be mutated. > >> If this >> were the case, then you'd have to explicitly have a side effect in >> the code above: >> >> (let ((x (list #f))) >> (set-car! x (lambda () x)) >> (eq? x ((car x)))) >> >> Which, frankly, is a better way of writing this than the letrec >> because it is obvious that some side-effecting is going on in >> order to create magic circular structure such that >> (eq? x ((car x))) could evaluate to #t. > > I agree that this is clearer and that letrec/call-cc tricks are > good for puzzles only and are never useful in practice. However, > ruling out all non-lambdas or non-trivial expressions from letrec > and internal defines is an overkill; especially when the motivation > for doing so is just to disallow such puzzles. > > Aziz,,, > -- ~jrm From jmarshall at alum.mit.edu Wed Aug 20 16:11:24 2008 From: jmarshall at alum.mit.edu (Joe Marshall) Date: Thu Mar 26 02:26:14 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <4BAF2B47-302A-407D-AF0B-738E02A03019@cs.indiana.edu> Message-ID: Local makes me ill. It's bad enough that the top level doesn't have the same semantics as internal define, but that's a compromise due to the interactive nature of top level. It's worse to promote that behavior to internal define as well. On Wed, Aug 20, 2008 at 12:51 PM, Shriram Krishnamurthi wrote: > would you object to it supplanting LETREC? Yes. ----- But.... Who would I object to? And why would anyone care what I thought? If the semantics of internal define changed enough that the code I write stopped working, I'd just write an explicit letrec or I'd write a macro that made it work right again. I'd certainly not make it the default in my own implementation, but if you have a portable macro you are free to do what you will. -- ~jrm From pdkhai89 at yahoo.com Wed Aug 20 10:08:14 2008 From: pdkhai89 at yahoo.com (Pham Dinh Khai) Date: Thu Mar 26 02:26:14 2009 Subject: [plt-scheme] Define-scope Message-ID: <181132.47356.qm@web34405.mail.mud.yahoo.com> Hi there, I'm Khai, I am studing DrScheme language. Could you help me to define the meaning of scope in programming global - variables local - parameters, local variables and local environments I uderstand these aspects but i don't know how to define in words hope to hear from you soon thanks, Khai From mvanier42 at gmail.com Wed Aug 20 22:05:23 2008 From: mvanier42 at gmail.com (Michael Vanier) Date: Thu Mar 26 02:26:14 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> Message-ID: <48ACCD63.8000906@cs.caltech.edu> Jumping in here... I wasn't aware that "letrec" was defined in terms of its let/set! semantics (though I knew that it could be so defined). I had always assumed that it was a primitive. To muddy the waters further, I believe that R6RS says that internal defines are actually translated into "letrec*", even though I don't know of any Scheme implementation that actually supports "letrec*". It's all a big mess. I also hate it wrt teaching, because SICP, for instance, describes define to have very simple semantics, but this isn't at all what internal defines really do (I'm guessing that the reason for this is that implementing internal defines in terms of some letrec or let/set! primitives is easier to optimize). So users expect that internal defines behave in ways similar to top-level defines, which they do not. This significantly undercuts the argument that Scheme is a "simple, elegant" language. I don't know of a good way out, either. I kind of like the Ocaml model where there are exactly two let forms, "let" (which makes one binding only) and "let rec" (which makes any number of mutually-recursive bindings). However, the syntax would be awkward for Scheme, and even in Ocaml, top-level lets behave differently (there is an implicit "in" which scopes over the rest of the file). I don't know if Ocaml resolves "let rec" to let/set!, but I doubt it. One other gripe: I've read in some places that PLT Scheme has about 12 fundamental special forms, but I can't find any documentation about which forms they are. Is that an oversight or intentional? I'm sure there is no desire to set Scheme primitives in stone, but it would be nice to know what forms an expression will eventually expand into. None of this is meant to detract from the enormous respect I have for PLT Scheme and its implementors, of course. Mike From mflatt at cs.utah.edu Wed Aug 20 22:18:44 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:14 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <48ACCD63.8000906@cs.caltech.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <48ACCD63.8000906@cs.caltech.edu> Message-ID: <20080821021846.784186500B2@mail-svr1.cs.utah.edu> At Wed, 20 Aug 2008 19:05:23 -0700, Michael Vanier wrote: > I wasn't aware that "letrec" was defined in terms of its let/set! > semantics (though I knew that it could be so defined). I had always > assumed that it was a primitive. To muddy the waters further, I believe > that R6RS says that internal defines are actually translated into > "letrec*", even though I don't know of any Scheme implementation that > actually supports "letrec*". R6RS implementations provide `letrec*'. FWIW, PLT Scheme's `letrec' corresponds to R6RS's `letrec*'. > One other gripe: I've read in some places that PLT Scheme has about 12 > fundamental special forms, but I can't find any documentation about > which forms they are. http://docs.plt-scheme.org/reference/syntax-model.html#(part._fully-expanded) Matthew From mvanier42 at gmail.com Wed Aug 20 22:22:15 2008 From: mvanier42 at gmail.com (Michael Vanier) Date: Thu Mar 26 02:26:15 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <20080821021846.784186500B2@mail-svr1.cs.utah.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <48ACCD63.8000906@cs.caltech.edu> <20080821021846.784186500B2@mail-svr1.cs.utah.edu> Message-ID: <48ACD157.1050302@cs.caltech.edu> Matthew Flatt wrote: > At Wed, 20 Aug 2008 19:05:23 -0700, Michael Vanier wrote: > >> I wasn't aware that "letrec" was defined in terms of its let/set! >> semantics (though I knew that it could be so defined). I had always >> assumed that it was a primitive. To muddy the waters further, I believe >> that R6RS says that internal defines are actually translated into >> "letrec*", even though I don't know of any Scheme implementation that >> actually supports "letrec*". >> > > R6RS implementations provide `letrec*'. > > FWIW, PLT Scheme's `letrec' corresponds to R6RS's `letrec*'. > > >> One other gripe: I've read in some places that PLT Scheme has about 12 >> fundamental special forms, but I can't find any documentation about >> which forms they are. >> > > http://docs.plt-scheme.org/reference/syntax-model.html#(part._fully-expanded) > > > Matthew > > Excellent, thanks! Mike From eli at barzilay.org Wed Aug 20 22:32:54 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:26:15 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <48ACCD63.8000906@cs.caltech.edu> References: <0hiv94tb45i52h8anvtrkrjhfbai3l17mb@4ax.com> <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <48ACCD63.8000906@cs.caltech.edu> Message-ID: <18604.54230.485404.496649@arabic.ccs.neu.edu> On Aug 20, Michael Vanier wrote: > Jumping in here... > > I wasn't aware that "letrec" was defined in terms of its let/set! > semantics (though I knew that it could be so defined). I had always > assumed that it was a primitive. To muddy the waters further, I > believe that R6RS says that internal defines are actually translated > into "letrec*", even though I don't know of any Scheme > implementation that actually supports "letrec*". At least in PLT, internal definitions were always done with a `letrec*', or more accurately, mzscheme's `letrec' is actually a `letrec*'. IIRC, ages ago there used to be a `letrec*' binding which was identical to `letrec'. > It's all a big mess. I also hate it wrt teaching, because SICP, for > instance, describes define to have very simple semantics, but this > isn't at all what internal defines really do (I'm guessing that the > reason for this is that implementing internal defines in terms of > some letrec or let/set! primitives is easier to optimize). So users > expect that internal defines behave in ways similar to top-level > defines, which they do not. This significantly undercuts the > argument that Scheme is a "simple, elegant" language. I don't know > of a good way out, either. It's still pretty simple. Continuations have a bad habit of exposing all kinds of implementation details as happened at the beginning of this thread. > I kind of like the Ocaml model where there are exactly two let > forms, "let" (which makes one binding only) and "let rec" (which > makes any number of mutually-recursive bindings). However, the > syntax would be awkward for Scheme, and even in Ocaml, top-level > lets behave differently (there is an implicit "in" which scopes over > the rest of the file). I don't know if Ocaml resolves "let rec" to > let/set!, but I doubt it. It doesn't matter, because there are no first class continuation, (and because of the restriction on what you can put in the rhs of `letrec's). And BTW, OCaml's `let rec' is still inconvenient, it often forces you to put the whole file in a single such form -- if there's a function at the top that needs to call a function at the bottom. And personally I found that to be very disturbing, since I'd try to move just the calling function down, but that might drag others too. In general you get a general topological sort problem to solve, and if in the end you find that you really need mutually recursive functions then either you work to restore the reasonable order and wrap it all in a `let rec' or you leave things in the mess they happend to be left at. Of course you could try to always begin with a single `let rec' for everything, but then you're stuck with polymorphic functions that don't work... Finally, there's the fact that because of the implicit `in' that wraps the rest of the REPL too, you get the well expected mess: # let x = 123;; val x : int = 123 # let foo() = x;; val foo : unit -> int = # let x = 1000;; val x : int = 1000 # foo();; - : int = 123 and this mess can become a major pain when you're dealing with new type definitions. (My personal conclusion was to not use the repl for more than very simple games.) The bottom line is that it's not all roses in the ocaml world either. Bindings are difficult any way you look at it. > One other gripe: I've read in some places that PLT Scheme has about > 12 fundamental special forms, but I can't find any documentation > about which forms they are. Is that an oversight or intentional? > I'm sure there is no desire to set Scheme primitives in stone, but > it would be nice to know what forms an expression will eventually > expand into. This might be what you're looking for: (require syntax/kerncase) (map syntax-e (kernel-form-identifier-list)) -> (begin define-values define-syntaxes define-values-for-syntax set! let-values letrec-values #%plain-lambda case-lambda if quote letrec-syntaxes+values with-continuation-mark #%expression #%plain-app #%top #%datum #%variable-reference) but it's useful in rare cases. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From eli at barzilay.org Wed Aug 20 22:41:03 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:26:15 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <5BC924B7-EB61-4A0E-8C4E-6E2C454F8A3B@ccs.neu.edu> References: <701FE9D6-9226-4275-AA8A-F8F8D0042A4B@gmail.com> <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <5BC924B7-EB61-4A0E-8C4E-6E2C454F8A3B@ccs.neu.edu> Message-ID: <18604.54719.89475.579469@arabic.ccs.neu.edu> On Aug 20, Matthias Felleisen wrote: > > On Aug 20, 2008, at 2:27 PM, Joe Marshall wrote: > > > Which, frankly, is a better way of writing this than the letrec > > because it is obvious that some side-effecting is going on in > > order to create magic circular structure such that > > (eq? x ((car x))) could evaluate to #t. > > Amen. (negated Amen). Not only do I like not doing an explicit side effect -- I'd go further and merge the `shared' functionality into `letrec', just to make it *really* usable for data too. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From lunarc.lists at gmail.com Wed Aug 20 22:48:55 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:15 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) Message-ID: A while ago I started a thread on the automatic releasing of resource locks on servlet termination in the web server: http://list.cs.brown.edu/pipermail/plt-scheme/2008-July/026121.html The problem is that individual threads acquire read/write locks on the database, but they may be terminated at any time due to timeout. In the worst case, a thread with a write lock is terminated, and then no other threads can get a read lock until the web server is restarted. Robby pointed me to a paper on implementing kill-safe shared resources: http://www.cs.utah.edu/plt/kill-safe/ Now that I finally have time to devote to this, I've taken a look. >From what I understand, though, this technique only helps when your lock lasts only for the duration of your call to the resource. In my case, my database monitor has the following interface: (call-as-retryable-job thunk) Waits to acquire a read lock and runs the thunk. Returns the result of the thunk. Releases any read/write locks obtained when returning. (aquire-write-lock) Called only within a thunk given to call-as-retryable-job. Tries to acquire a write lock by blocking new readers and waiting for existing readers to finish. If there is another thread already waiting for a write lock, an escape continuation is used to retry the thunk from scratch as a new reader. (has-read-lock?) (has-write-lock?) Kinda obvious. Now, if my servlet is terminated during the execution of thunk, my read/write locks are not released, and new readers/writers may have trouble getting into the database. I can't see how the techniques described in the above paper will help me solve this. Would "scheme_add_managed" help me with this problem? I get the idea this function was designed only to handle C-level cleanup, but I'm not sure what else to do. Any help would be appreciated, Henk Boom Monitor implementation: #lang scheme/base (provide call-as-retryable-job acquire-write-lock has-read-lock? has-write-lock?) (define read-s (make-semaphore 1)) (define write-s (make-semaphore 1)) (define reader-counter 0) (define reader-counter-s (make-semaphore 1)) (define *lock-type* (make-parameter #f)) (define *retry-proc* (make-parameter 'no-retry)) (define (has-read-lock?) (and (*lock-type*) #t)) (define (has-write-lock?) (eq? (*lock-type*) 'write)) (define-syntax with-semaphore (syntax-rules () ((with-semaphore s . body) (call-with-semaphore s (lambda () . body))))) (define (start-read) ; don't go until there are no writers waiting, to make sure they go first (sync (semaphore-peek-evt write-s)) ; acquire read-lock if necessary (with-semaphore reader-counter-s (when (= 0 reader-counter) (semaphore-wait read-s)) (set! reader-counter (+ reader-counter 1)) (printf "reader-counter=~a after increment~n" reader-counter)) ; we can now read (*lock-type* 'read)) (define (finish-read) ; prohibit access (*lock-type* #f) ; release read-lock if necessary (with-semaphore reader-counter-s (set! reader-counter (- reader-counter 1)) (printf "reader-counter=~a after decrement~n" reader-counter) (when (= 0 reader-counter) (semaphore-post read-s)))) (define (acquire-write-lock) ; see if we are the first waiting to write (if (semaphore-try-wait? write-s) ; we are, go ahead (begin (finish-read) ; get the read lock to ensure all readers have left (semaphore-wait read-s) (*lock-type* 'write)) ; we aren't, so retry the transaction from the start to give the other ; writer a chance ((*retry-proc*)))) (define (finish-write) ; prohibit access (*lock-type* #f) (semaphore-post read-s) (semaphore-post write-s)) (define (call-as-retryable-job thunk) (let/ec success (let loop () (let/ec retry (call-with-continuation-barrier (lambda () (start-read) (parameterize ((*retry-proc* retry)) (dynamic-wind void (lambda () (success (thunk))) (lambda () (if (eq? (*lock-type*) 'write) (finish-write) (finish-read)))))))) (loop)))) From gregory.woodhouse at gmail.com Wed Aug 20 22:52:06 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:26:16 2009 Subject: [plt-scheme] Define-scope In-Reply-To: <181132.47356.qm@web34405.mail.mud.yahoo.com> References: <181132.47356.qm@web34405.mail.mud.yahoo.com> Message-ID: <0E1E94DB-1F0C-40BE-92E8-F8436FB018FC@gmail.com> On Aug 20, 2008, at 7:08 AM, Pham Dinh Khai wrote: > Hi there, > I'm Khai, I am studing DrScheme language. Could you help me to define > the meaning of scope in programming > global - variables > local - parameters, local variables and local > environments > I uderstand these aspects but i don't know how to define in words > hope to hear from you soon > thanks, > Khai Scope is that portion of a program where a binding is in effect. For instance (let ([x 3]) (let ([x 4]) x)) evaluates to 4 (not 3), because x is evaluated using the binding introduced by the innermost let. Notice that the scope corresponds to a specific part of the program (source). This is called static scoping, and when Scheme was introduced in 1975, one of its main innovations was static scoping rules. "Those who are enamored of practice without theory are like a pilot who goes into a ship without rudder or compass." --Leonardo da Vinci (1452-1519) http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080820/f1c6e51b/attachment.htm From jmarshall at alum.mit.edu Thu Aug 21 00:25:43 2008 From: jmarshall at alum.mit.edu (Joe Marshall) Date: Thu Mar 26 02:26:16 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <18604.54719.89475.579469@arabic.ccs.neu.edu> References: <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <5BC924B7-EB61-4A0E-8C4E-6E2C454F8A3B@ccs.neu.edu> <18604.54719.89475.579469@arabic.ccs.neu.edu> Message-ID: On Wed, Aug 20, 2008 at 7:41 PM, Eli Barzilay wrote: > On Aug 20, Matthias Felleisen wrote: >> >> On Aug 20, 2008, at 2:27 PM, Joe Marshall wrote: >> >> > Which, frankly, is a better way of writing this than the letrec >> > because it is obvious that some side-effecting is going on in >> > order to create magic circular structure such that >> > (eq? x ((car x))) could evaluate to #t. >> >> Amen. > > (negated Amen). Eli, what's wrong with you?! Are you sure you're feeling ok? > Not only do I like not doing an explicit side effect -- I'd go further > and merge the `shared' functionality into `letrec', just to make it > *really* usable for data too. The thing I *really* want is for there to be a subset of Scheme that supports pure functional programming where it is obvious, by cursory inspection, that there are no side effects. No explicit calls to SET! (or set-car!, rplaca, etc.) means no side effects period. R5RS didn't have this because it required letrec to expand into let + set! whether it needed it or not. I was hoping that R6RS would improve on this by at least *allowing* an implementation to use a fixed-point if possible. The more I program, the more I get the feeling that the case against side effects is vastly understated even by the people that object the most to them. -- ~jrm From gregory.woodhouse at gmail.com Thu Aug 21 00:27:14 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:26:17 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <87269756-644A-4C0A-8266-2849C4267962@ccs.neu.edu> <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <4BAF2B47-302A-407D-AF0B-738E02A03019@cs.indiana.edu> Message-ID: <674A3565-296C-4C90-A5C6-319C74148255@gmail.com> On Aug 20, 2008, at 12:51 PM, Shriram Krishnamurthi wrote: > If LOCAL had a slightly less onerous syntax (the current syntax meets > one need superbly, but at the cost of some syntactic pain for people > writing a fresh LOCAL expression from scratch), would you object to it > supplanting LETREC? > > S. I guess it depends on what you mean by "supplant". I wouldn't be happy to see LETREC disappear from the language, even if it weren't actually needed, or if it could be replaced with reasonable clarity by another construct (I wouldn't put LET ... SET! ... in this category). Maybe it's just a matter of tradition - or familiarity. In any case, one thing that bothers me is that LOCAL just seems too mysterious (or maybe it's really DEFINE that is mysterious). The Reference says that LOCAL is like LETREC "except that bindings are expressed in the same way as in top-level or in a module body". The Reference the points to section 1.2.3.6 on partial expansion, which certainly helps, and confirms intuition about what a self-referential DEFINE could possibly mean. When I look up LETREC, I read (section 2.9): "Similar to let, but the location for all ids are created first and filled with #..." That doesn't sound the same at all. Or does it? If I think intuitively about how I might read a LETREC, I think about creating mental placeholders and filling them in as I go, so it kind of comes down to the same process. But enough of me thinking out loud. The problems to me seem twofold: I never learned or used LOCAL when learning Scheme, and try to avoid using internal DEFINEs. I suspect a lot of other people are in the same boat. The other is that LOCAL and LETREC are generally presented in different ways, and it's not obvious that (or if) they are operationally equivalent. "Mathematics is the science of patterns." --Lynn Arthur Steen, 1988 http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080820/411567dc/attachment.html From gregory.woodhouse at gmail.com Thu Aug 21 01:03:42 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:26:18 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <5BC924B7-EB61-4A0E-8C4E-6E2C454F8A3B@ccs.neu.edu> <18604.54719.89475.579469@arabic.ccs.neu.edu> Message-ID: <69611B01-07D4-426E-8E26-4B7384EAE8FF@gmail.com> On Aug 20, 2008, at 9:25 PM, Joe Marshall wrote: > The thing I *really* want is for there to be a subset of Scheme > that supports pure functional programming where it is obvious, > by cursory inspection, that there are no side effects. No explicit > calls to SET! (or set-car!, rplaca, etc.) means no side effects > period. R5RS didn't have this because it required letrec to expand > into let + set! whether it needed it or not. I was hoping that > R6RS would improve on this by at least *allowing* an implementation > to use a fixed-point if possible. > Me, too. In the case of letrec, though, what if it were primitive? It might be implemented using let/set! (or something like it) but its only side- effect is to bind a name. If I recall correctly, Haskell uses a single let that allows for recursive definitions much like letrec in Scheme. It would be interesting to have a fixed point operator made explicit in the language. I may be out of my depth here, but in a stack based (as opposed to reduction based) implementation, I soppose that would mean capturing continuations (to handle the Y f => f steps). > The more I program, the more I get the feeling that the case against > side effects is vastly understated even by the people that object > the most to them. > "Mathematics is the science of patterns." --Lynn Arthur Steen, 1988 http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080820/baffe917/attachment.htm From eli at barzilay.org Thu Aug 21 01:26:31 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:26:18 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <003201c901fd$97704200$c650c600$%mayers@usherbrooke.ca> <49C48DC5-B21E-4231-81E2-96657B99156E@ccs.neu.edu> <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <5BC924B7-EB61-4A0E-8C4E-6E2C454F8A3B@ccs.neu.edu> <18604.54719.89475.579469@arabic.ccs.neu.edu> Message-ID: <18604.64647.647115.72326@arabic.ccs.neu.edu> On Aug 20, Joe Marshall wrote: > On Wed, Aug 20, 2008 at 7:41 PM, Eli Barzilay wrote: > > On Aug 20, Matthias Felleisen wrote: > >> > >> On Aug 20, 2008, at 2:27 PM, Joe Marshall wrote: > >> > >> > Which, frankly, is a better way of writing this than the letrec > >> > because it is obvious that some side-effecting is going on in > >> > order to create magic circular structure such that > >> > (eq? x ((car x))) could evaluate to #t. > >> > >> Amen. > > > > (negated Amen). > > Eli, what's wrong with you?! Are you sure you're feeling ok? Yes. And I still prefer the implicit side-effect over the explicit one. Even back in the days where we were happily mutating pairs, I still considered (define foo* (set-cdr! (last-pair foo) foo)) to be a hack. A slightly better way to achieve this would be (define foo* (append! foo foo)) becuase it's clearer what kind of short-circuiting it makes, and the actual side-effect that is needed to implement it is not for me to worry. A better way, when possible, is (define foo* '#0=(1 2 3 . #0#)) except that it's very rare to need a circular list of literals, so it's almost never useful. But what beats all of these by an order of magnitude is: (define foo* (letrec ([foo* (append foo foo*)]) foo*)) I can get *some* of that functionality with `shared', but not everything. The best I can do is: (require lazy/force) (define (cycle l) (!! (letrec ([c (lazy (append l c))]) c))) The bottom line is that there are certain kinds of well-behaved circular references that the language can do by itself, and I'm happy to leave the implementation details for it. (In the above case, the (restricted) side effect is implicit in promise caches and in !!'s use of `make-reader-graph'.) [This is why I don't really care if Matthew made `letrec' achieve the magic by a `let'+`set!', by a fixpoint combinator, or by voodoo machine-code translations. For all I know he has 5 different methods and chooses one randomly for every minor version to see which one's fastest. If they all work the same, I don't care which one is used. (Yes, continuations expose some of these details, which is unfortunate -- I still don't want explicit mutation to get my self references.)] -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From mflatt at cs.utah.edu Thu Aug 21 11:58:54 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:18 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: References: Message-ID: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> At Wed, 20 Aug 2008 22:48:55 -0400, "Henk Boom" wrote: > > http://www.cs.utah.edu/plt/kill-safe/ > > Now that I finally have time to devote to this, I've taken a look. > From what I understand, though, this technique only helps when your > lock lasts only for the duration of your call to the resource. Forget locks. Make a process that's in charge of the resource. [The process is effectively an implementation of a readers+writer lock, but this characterization is probably useful only if you're trained to think in terms of locks instead of processes. The key is that you get to implement the "lock" instead of trying to juggle primitive locks.] The process representing the resource accepts reader requests and lets them run them in parallel; when a reader asks to become a writer, then the managing process waits for all the other readers to finish before granting the conversion; if there's already a pending writer, then all new writer-conversion requests are rejected. The process can see when a reader/writer terminates, and it can adjust accordingly. The enclosed "rwlock.ss" illustrates this implementation. Depending on the domain, though, there's one more problem beyond granting read and write access in a kill-safe way. What if a thread is terminated while it's in write mode? The "rwlock.ss" implementation treats termination the same as the completion, but that's valid only if each atomic step in writing keeps the relevant data consistent. Otherwise, you need some way to ensure that the write completes so that the data is consistent. If all you have is locks, then you're stuck on this second problem. If you have a process, though, the solution is pretty easy: delegate the writing work to the process that handles read and write access. (The writing work has to be trusted in this case, in the sense that it won't raise unexpected exceptions or things like that.) The enclosed "rwlock-complete-write.ss" illustrates the generalization or "rwlock.ss" to solve that problem. BEWARE: a version of the enclosed code exposed a bug in `sync'. (An array was improperly re-used when, for a non-zero N, `sync' receives N `choice-evt's that contain no non-choice events plus M `choice-evts' that contain a total of N+M non-choice events.) The bug is fixed in SVN, and the enclosed code contains a dummy semaphore to work around the bug. Matthew -------------- next part -------------- #lang scheme ;; To send messages to server: (define read-req-ch (make-channel)) (define write-req-ch (make-channel)) ;; A message to the server: (define-struct req (accept-ch done-sema th)) ;; Internal to server: (define-struct reader (done-sema th)) (define-struct writer (accept-ch done-sema th)) (define temporary-workaround-evt (make-semaphore)) ;; avoids a bug in version prior to v4.1.0.2-svn11367 (define (serve readers pending-writer) (sync ;; Handle reqeusst to become writer: (handle-evt write-req-ch (lambda (r) (cond [pending-writer ;; Reject request, because someone else has asked ;; to become a writer (reply (req-accept-ch r) #f) (serve readers pending-writer)] [else ;; Accept the writer and remove it from the readers, ;; but don't let the writer continue until we're ;; out of readers (serve (remove r readers (lambda (a b) (eq? (req-th a) (reader-th b)))) (make-writer (req-accept-ch r) (req-done-sema r) (req-th r)))]))) ;; If a pending writer and no readers, let writer continue: (if (and pending-writer (null? readers)) (choice-evt (handle-evt (channel-put-evt (writer-accept-ch pending-writer) #t) (lambda (v) ;; Writer has accepted and is now running. Wait for it ;; to finish (without accepting reject reader requests meanwhile). ;; If it dies we release the lock --- MAYBE WITH A PARTIAL WRITE! (sync (writer-done-sema pending-writer) (thread-dead-evt (writer-th pending-writer))) ;; Demote the writer back to a reader: (serve (list (make-reader (writer-done-sema pending-writer) (writer-th pending-writer))) #f))) (handle-evt (thread-dead-evt (writer-th pending-writer)) (lambda (v) ;; Writer died before continuing (serve null #f)))) never-evt) ;; Handle requests to become a reader (if pending-writer never-evt ; don't allow if there's a pending writer (handle-evt read-req-ch (lambda (r) ;; Accept new reader (reply (req-accept-ch r) #t) (serve (cons (make-reader (req-done-sema r) (req-th r)) readers) #f)))) ;; Handle reader completion/termination by removing it from our list (apply choice-evt temporary-workaround-evt (map (lambda (r) (handle-evt (choice-evt (reader-done-sema r) (thread-dead-evt (reader-th r))) (lambda (v) (serve (remq r readers) pending-writer)))) readers)))) (define (reply ch v) (or ;; Reply immediately, if possible; this is an optimization (sync/timeout 0 (channel-put-evt ch v)) ;; Reply eventually (thread-resume (thread (lambda () (channel-put ch v))) (current-thread)))) ;; Start the server: (define serve-thread (thread (lambda () (serve null #f)))) ;; ---------------------------------------- (define retry (make-continuation-prompt-tag 'retry)) ;; call-as-retryable : (((-> beta) -> beta) -> alpha) -> alpha ;; Given function acts as reader. When the reader is called, it's given ;; a function that takes a thunk to apply in write mode (but write mode ;; also continues after the thunk returns) (define (call-as-retryable read-proc) ;; Ensure that server is running: (thread-resume serve-thread (current-thread)) ;; Set up a prompt for abort and retry: (call-with-continuation-prompt (lambda () (let ([accept-ch (make-channel)] [done-sema (make-semaphore)]) (channel-put read-req-ch (make-req accept-ch done-sema (current-thread))) (channel-get accept-ch) ;; wait until accepted as a reader (call-with-continuation-barrier (lambda () (dynamic-wind void (lambda () ;; read... (read-proc (lambda (write-thunk) ;; shift into write mode (let ([accept-ch (make-channel)]) (channel-put write-req-ch (make-req accept-ch done-sema (current-thread))) (if (channel-get accept-ch) ;; allowed to write: (write-thunk) ;; can't write, so abort (and abort handler will retry) (abort-current-continuation retry)))))) (lambda () (semaphore-post done-sema))))))) retry ;; On abort, retry: (lambda () (call-as-retryable read-proc)))) ;; ---------------------------------------- ;; Example use (define x 0) (for ([i (in-range 100)]) (thread (lambda () (printf "~s\n" (call-as-retryable (lambda (call-write) (when (zero? (random 3)) ; randomly become writer (call-write (lambda () (let ([v x]) (set! x #f) ; simulate inconsistency (sleep) ; what if the thread is killed here? (set! x (add1 v)))))) (when (zero? (random (add1 i))) ; randomly die (kill-thread (current-thread))) ;; x should never be #f (i.e., inconsistent): x))) ;; pretend to continue with other work... (sleep 1000)))) -------------- next part -------------- #lang scheme ;; To send messages to server: (define read-req-ch (make-channel)) (define write-req-ch (make-channel)) ;; A message to the server: (define-struct req (accept-ch done-sema th)) ;; Internal to server: (define-struct reader (done-sema th)) (define-struct writer (accept-ch done-sema th)) (define temporary-workaround-evt (make-semaphore)) ;; avoids a bug in version prior to v4.1.0.2-svn11367 (define (serve readers pending-writer) (sync ;; Handle reqeusst to become writer: (handle-evt write-req-ch (lambda (r) (cond [pending-writer ;; Reject request, because someone else has asked ;; to become a writer (reply (req-accept-ch r) #f) (serve readers pending-writer)] [else ;; Accept the writer and remove it from the readers, ;; but don't let the writer continue until we're ;; out of readers (serve (remove r readers (lambda (a b) (eq? (req-th a) (reader-th b)))) (make-writer (req-accept-ch r) (req-done-sema r) (req-th r)))]))) ;; If a pending writer and no readers, let writer continue: (if (and pending-writer (null? readers)) (choice-evt (let ([completed-sema (make-semaphore)]) (handle-evt (channel-put-evt (writer-accept-ch pending-writer) completed-sema) (lambda (v) ;; Writer has accepted and should now provide the (trusted!) ;; writing thunk (sync ;; handle provided thunk: (handle-evt (writer-accept-ch pending-writer) (lambda (write-thunk) (write-thunk))) ;; No problem if the writer dies before supplying the thunk: (thread-dead-evt (writer-th pending-writer))) ;; Tell writing thread that the thunk completed: (semaphore-post completed-sema) ;; Demote the writer back to a reader: (serve (list (make-reader (writer-done-sema pending-writer) (writer-th pending-writer))) #f)))) (handle-evt (thread-dead-evt (writer-th pending-writer)) (lambda (v) ;; Writer died before continuing (serve null #f)))) never-evt) ;; Handle requests to become a reader (if pending-writer never-evt ; don't allow if there's a pending writer (handle-evt read-req-ch (lambda (r) ;; Accept new reader (reply (req-accept-ch r) #t) (serve (cons (make-reader (req-done-sema r) (req-th r)) readers) #f)))) ;; Handle reader completion/termination by removing it from our list (apply choice-evt temporary-workaround-evt (map (lambda (r) (handle-evt (choice-evt (reader-done-sema r) (thread-dead-evt (reader-th r))) (lambda (v) (serve (remq r readers) pending-writer)))) readers)))) (define (reply ch v) (or ;; Reply immediately, if possible; this is an optimization (sync/timeout 0 (channel-put-evt ch v)) ;; Reply eventually (thread-resume (thread (lambda () (channel-put ch v))) (current-thread)))) ;; Start the server: (define serve-thread (thread (lambda () (serve null #f)))) ;; ---------------------------------------- (define retry (make-continuation-prompt-tag 'retry)) ;; call-as-retryable : (((-> beta) -> beta) -> alpha) -> alpha ;; Given function acts as reader. When the reader is called, it's given ;; a function that takes a thunk to apply in write mode (but write mode ;; also continues after the thunk returns) (define (call-as-retryable read-proc) ;; Ensure that server is running: (thread-resume serve-thread (current-thread)) ;; Set up a prompt for abort and retry: (call-with-continuation-prompt (lambda () (let ([accept-ch (make-channel)] [done-sema (make-semaphore)]) (channel-put read-req-ch (make-req accept-ch done-sema (current-thread))) (channel-get accept-ch) ;; wait until accepted as a reader (call-with-continuation-barrier (lambda () (dynamic-wind void (lambda () ;; read... (read-proc (lambda (write-thunk) ;; shift into write mode (let ([accept-ch (make-channel)]) (channel-put write-req-ch (make-req accept-ch done-sema (current-thread))) (let ([completed-sema (channel-get accept-ch)]) (if completed-sema ;; allowed to write: (begin (channel-put accept-ch write-thunk) (semaphore-wait completed-sema)) ;; can't write, so abort (and abort handler will retry) (abort-current-continuation retry))))))) (lambda () (semaphore-post done-sema))))))) retry ;; On abort, retry: (lambda () (call-as-retryable read-proc)))) ;; ---------------------------------------- ;; Example use (define x 0) (for ([i (in-range 100)]) (thread (lambda () (printf "~s\n" (call-as-retryable (lambda (call-write) (when (zero? (random 3)) ; randomly become writer (call-write (lambda () (let ([v x]) (set! x #f) ; simulate inconsistency (sleep) ;; if the server thread is killed here, it will get resumed ;; by any future read attempt, and so the write action will ;; finish (set! x (add1 v)))))) (when (zero? (random (add1 i))) ; randomly die (kill-thread (current-thread))) ;; x should never be #f (i.e., inconsistent): x))) ;; pretend to continue with other work... (sleep 1000)))) From noelwelsh at gmail.com Thu Aug 21 12:20:11 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:26:19 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: References: Message-ID: We've had bad experiences with timeout based servlets. I would use the LRU manager, and implement my own timeouts. This way you can send a "timeout" events to your database process and tell it to release all locks. Hopefully that help; I'm not sure I'm fully understood your problem. N. From lunarc.lists at gmail.com Thu Aug 21 15:51:50 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:19 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> Message-ID: On 2008-08-21, Matthew Flatt wrote: > Forget locks. Make a process that's in charge of the resource. > > [The process is effectively an implementation of a readers+writer lock, > but this characterization is probably useful only if you're trained to > think in terms of locks instead of processes. The key is that you get > to implement the "lock" instead of trying to juggle primitive locks.] OK. I have semaphores on the brain right now, I just took the first OS course at my university and wrote that code after we went through a bunch of semaphore examples in class, including the regular reader-writer problem. When you have a shiny new hammer. . . =) > The process representing the resource accepts reader requests and lets > them run them in parallel; when a reader asks to become a writer, then > the managing process waits for all the other readers to finish before > granting the conversion; if there's already a pending writer, then all > new writer-conversion requests are rejected. The process can see when a > reader/writer terminates, and it can adjust accordingly. The enclosed > "rwlock.ss" illustrates this implementation. Thanks! I'm at work at the moment, but it looks like there's a lot for me to chew on in there; I'll take a look tonight. > Depending on the domain, though, there's one more problem beyond > granting read and write access in a kill-safe way. What if a thread is > terminated while it's in write mode? The "rwlock.ss" implementation > treats termination the same as the completion, but that's valid only if > each atomic step in writing keeps the relevant data consistent. > Otherwise, you need some way to ensure that the write completes so that > the data is consistent. > > If all you have is locks, then you're stuck on this second problem. If > you have a process, though, the solution is pretty easy: delegate the > writing work to the process that handles read and write access. (The > writing work has to be trusted in this case, in the sense that it won't > raise unexpected exceptions or things like that.) The enclosed > "rwlock-complete-write.ss" illustrates the generalization or > "rwlock.ss" to solve that problem. Actually, I had a solution to this problem already, to use when the writer throws an exception. Since each writer has its own sqlite transaction, I can just signal to sqlite to do a rollback. It looks like to do this properly I will have to move some DB calls into the monitor itself. Thanks, Henk Boom > BEWARE: a version of the enclosed code exposed a bug in `sync'. (An > array was improperly re-used when, for a non-zero N, `sync' receives N > `choice-evt's that contain no non-choice events plus M `choice-evts' > that contain a total of N+M non-choice events.) The bug is fixed in > SVN, and the enclosed code contains a dummy semaphore to work around > the bug. > > > > Matthew > > From sk at cs.brown.edu Thu Aug 21 16:01:42 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:26:19 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> Message-ID: On Thu, Aug 21, 2008 at 3:51 PM, Henk Boom wrote: > On 2008-08-21, Matthew Flatt wrote: >> Forget locks. Make a process that's in charge of the resource. >> >> [The process is effectively an implementation of a readers+writer lock, >> but this characterization is probably useful only if you're trained to >> think in terms of locks instead of processes. The key is that you get >> to implement the "lock" instead of trying to juggle primitive locks.] > > OK. I have semaphores on the brain right now, I just took the first OS > course at my university and wrote that code after we went through a > bunch of semaphore examples in class, including the regular > reader-writer problem. When you have a shiny new hammer. . . =) Just fyi, it so happens your shiny new hammer actually has a hidden crack in its handle, its head is made of untemepered steel, and the joint between the pieces lacks any fastening so at some unpredictable point during heavy use, the head will go flying and will smash a hole in some precious object. But this will happen without you noticing it, so you keep pounding away and will wonder why the nail isn't going any further into the wall. Apologies for being the messenger of bad news, Shriram From jmarshall at alum.mit.edu Thu Aug 21 16:22:11 2008 From: jmarshall at alum.mit.edu (Joe Marshall) Date: Thu Mar 26 02:26:19 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: <18604.64647.647115.72326@arabic.ccs.neu.edu> References: <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <5BC924B7-EB61-4A0E-8C4E-6E2C454F8A3B@ccs.neu.edu> <18604.54719.89475.579469@arabic.ccs.neu.edu> <18604.64647.647115.72326@arabic.ccs.neu.edu> Message-ID: On Wed, Aug 20, 2008 at 10:26 PM, Eli Barzilay wrote: > > The bottom line is that there are certain kinds of well-behaved > circular references that the language can do by itself, and I'm happy > to leave the implementation details for it. (In the above case, the > (restricted) side effect is implicit in promise caches and in !!'s use > of `make-reader-graph'.) > > [This is why I don't really care if Matthew made `letrec' achieve the > magic by a `let'+`set!', by a fixpoint combinator, or by voodoo > machine-code translations. For all I know he has 5 different methods > and chooses one randomly for every minor version to see which one's > fastest. If they all work the same, I don't care which one is used. > (Yes, continuations expose some of these details, which is unfortunate > -- I still don't want explicit mutation to get my self references.)] Ok, I get what you're saying. You want circularity in the data space as well as in the function space and letrec does that. I'm guessing, however, that you want EQ-ness as well. This leads to a real problem. EQ is a very weird function because it's quite useful in the absence of side effects, but absolutely critical in the presence. I don't understand why you want circularity, though. If you don't intend on using side effects, then there's no way, other than via EQ, to determine if a structure is circular. And if you don't intend to use side effects, then a non-circular, but infinite structure would be observationally equivalent for every function *except* EQ. In other words, you couldn't write a program that would return a different answer for circular vs. infinite *unless* you explicitly used EQ. (And depending on the philosophy of the implementor, a `pure' implementation of Scheme could use hash-consing to fold equivalent structure and the circular and infinite structure would be indistinguishable. Baker argues for this in http://home.pipeline.com/~hbaker1/ObjectIdentity.html ) So either you are using letrec because 1) You want infinite, self-similar objects and you don't care about `circularity' per-se, 2) You really want *circular* objects because you intend to do something that can distinguish between truly circular objects and inifinite ones. This implies the intent of side effects. The last paragraph where you say `` I don't really care if Matthew made `letrec' achieve the magic by a `let'+`set!', by a fixpoint combinator, or by voodoo'' seems to indicate the former. If *that's* the case, we don't have much of a problem. Abdulaziz Ghuloum's example: (letrec ([x (list (lambda () x))]) (eq? x ((car x)))) would simply be allowed to return #T or #F depending on the implementation. I could definitely live with that, but I expect other people will balk at it. -- ~jrm From robby at cs.uchicago.edu Thu Aug 21 18:05:00 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:20 2009 Subject: [plt-scheme] Division error in DrScheme v.4.1 In-Reply-To: <48AC2ADE.8010005@gmail.com> References: <48AC2ADE.8010005@gmail.com> Message-ID: <932b2f1f0808211505q7dfee887q5b794ea10e5c3c75@mail.gmail.com> If the problem comes back, I'd love to have a copy of your preferences file. Thanks, Robby On Wed, Aug 20, 2008 at 9:31 AM, Sergey Lovtsov wrote: > Thank you for your help! > I have fix the problem, it seems that something was wrong with plt-prefs.ss > file. I've deleted it and, after that, DrScheme has created new plt-prefs.ss > with default preferences. So, everything is ok now. > I don't know what caused this problem, the only thing i've changed in > DrScheme is the font. > > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From toddobryan at gmail.com Thu Aug 21 20:56:39 2008 From: toddobryan at gmail.com (Todd O'Bryan) Date: Thu Mar 26 02:26:20 2009 Subject: [plt-scheme] Re: Any tips for avoiding intermittent freezing when navigating file system directories with mounted network volumes in DrScheme? In-Reply-To: <5bana45vi6vddqituc6fhl434psijor8rv@4ax.com> References: <74jia4hvk0ena11cvch0neuq7hlfca7jh5@4ax.com> <74jia4hvk0ena11cvch0neuq7hlfca7jh5-e09XROE/p8c@public.gmane.org> <756daca50808181220r2e6dfd8fqaecdab70748016de@mail.gmail.com> <5bana45vi6vddqituc6fhl434psijor8rv@4ax.com> Message-ID: <904774730808211756o4065dd28sf465eb1269ce88e2@mail.gmail.com> Just another data point. I have a Linux lab running DrScheme 4.1 and several students had freeze issues when they tried to add a user teachpack right after they clicked the "Add teachpack to list..." button. The OS kept working and they were able to kill MrEd, but DrScheme was completely frozen. It happened to probably 5 or 6 people in each class of 25 or so. Todd On Wed, Aug 20, 2008 at 1:22 AM, Benjamin L. Russell wrote: > On Mon, 18 Aug 2008 14:20:27 -0500, "Grant Rettke" > wrote: > >>> Does anybody have any tips on avoiding this intermittent freezing when >>> navigating local file system directories on a system with mounted >>> network volumes? >> >>Just wondering, is this a general Windows issue or a DrScheme specific issue? >> >>My machine at work has horrible, terrible hanging issues whenever I >>use Explorer. > > Since I can navigate those same directories in Windows Explorer and > other applications without any problems, but the intemittent freezing > always occurs in DrScheme, this issue appears to be DrScheme-specific. > > -- Benjamin L. Russell > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From eli at barzilay.org Thu Aug 21 21:35:19 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:26:20 2009 Subject: [plt-scheme] about letrec and continuation : which behavior is correct ? and why ? In-Reply-To: References: <20080819141010.811CB6500BE@mail-svr1.cs.utah.edu> <0FD66D81-5812-4854-A9FD-F44019FDF6EB@cs.indiana.edu> <5BC924B7-EB61-4A0E-8C4E-6E2C454F8A3B@ccs.neu.edu> <18604.54719.89475.579469@arabic.ccs.neu.edu> <18604.64647.647115.72326@arabic.ccs.neu.edu> Message-ID: <18606.6103.927285.768541@arabic.ccs.neu.edu> On Aug 21, Joe Marshall wrote: > > Ok, I get what you're saying. You want circularity in the data > space as well as in the function space and letrec does that. Yes. (And that's why I like the `letrec*' semantics -- it give me some semi-sane way to mix non-function values, except without the self-referencing bit.) > I'm guessing, however, that you want EQ-ness as well. Only sometimes. In the examples I gave, eq-ness was important to be able to actually get the (cyclic) list. If I stick to the lazy language, then I could define `cycle' in a much simpler way: (define (cycle l) (append l (cycle l))) But this won't work if you want to get a hold of the list in plain Scheme -- there's no (easy/efficient) way to know when you have a loop, which is what you'll need to make the inner call into a cycle pointer. So I used a version that had an explicit cycle via a `letrec' value (in the lazy sense). > I don't understand why you want circularity, though. If you don't > intend on using side effects, then there's no way, other than via > EQ, to determine if a structure is circular. And if you don't > intend to use side effects, then a non-circular, but infinite > structure would be observationally equivalent for every function > *except* EQ. In other words, you couldn't write a program that > would return a different answer for circular vs. infinite *unless* > you explicitly used EQ. Well, it's just the above -- I don't care much for `eq?' in itself. If you manage to solve the forcing-an-infinite-lazy-value problem (which is the same as, for example, writing such a structure to a file), and if you gave me `equal?' that was as efficient as `eq?', then I probably wouldn't even notice when you take away `eq?'. > (And depending on the philosophy of the implementor, a `pure' > implementation of Scheme could use hash-consing to fold equivalent > structure and the circular and infinite structure would be > indistinguishable. Baker argues for this in > http://home.pipeline.com/~hbaker1/ObjectIdentity.html ) Not in the above code. The actual representation has promises holding cons cells to more promises, and the promises themselves cannot be unified unless you have a way to prove that two functions are equivalent. (Which might be possible in some simple cases like the above, but probably too expensive to detect automatically.) > So either you are using letrec because > > 1) You want infinite, self-similar objects and you don't care > about `circularity' per-se, > > 2) You really want *circular* objects because you intend to > do something that can distinguish between truly circular > objects and inifinite ones. This implies the intent of > side effects. > > The last paragraph where you say `` I don't really care if Matthew > made `letrec' achieve the magic by a `let'+`set!', by a fixpoint > combinator, or by voodoo'' seems to indicate the former. Yes, it's the former, mostly -- but a usable version of it. > If *that's* the case, we don't have much of a problem. Abdulaziz > Ghuloum's example: > > (letrec ([x (list (lambda () x))]) > (eq? x ((car x)))) > > would simply be allowed to return #T or #F depending on the > implementation. I could definitely live with that, but I expect > other people will balk at it. I'd balk at it too -- *unless* you give me this: (letrec ([x (list (lambda () x))]) (equal? x ((car x)))) --> #t instead. Since I can't get that, I need `eq?'. So I guess that I'm saying that the side-effect that is (possibly) used to create that self reference is an unfortunate by-product of working in an eager language -- which is one more reason I don't want to do it explicitly. -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From gresvol at gmail.com Fri Aug 22 08:14:44 2008 From: gresvol at gmail.com (Sergey Lovtsov) Date: Thu Mar 26 02:26:20 2009 Subject: [plt-scheme] Division error in DrScheme v.4.1 In-Reply-To: <932b2f1f0808211505q7dfee887q5b794ea10e5c3c75@mail.gmail.com> References: <48AC2ADE.8010005@gmail.com> <932b2f1f0808211505q7dfee887q5b794ea10e5c3c75@mail.gmail.com> Message-ID: <48AEADB4.5040708@gmail.com> Sure, i've already thought about that. > If the problem comes back, I'd love to have a copy of your preferences file. > > Thanks, > Robby > From robby at cs.uchicago.edu Fri Aug 22 10:14:37 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:20 2009 Subject: [plt-scheme] Re: Any tips for avoiding intermittent freezing when navigating file system directories with mounted network volumes in DrScheme? In-Reply-To: <904774730808211756o4065dd28sf465eb1269ce88e2@mail.gmail.com> References: <74jia4hvk0ena11cvch0neuq7hlfca7jh5@4ax.com> <74jia4hvk0ena11cvch0neuq7hlfca7jh5-e09XROE/p8c@public.gmane.org> <756daca50808181220r2e6dfd8fqaecdab70748016de@mail.gmail.com> <5bana45vi6vddqituc6fhl434psijor8rv@4ax.com> <904774730808211756o4065dd28sf465eb1269ce88e2@mail.gmail.com> Message-ID: <932b2f1f0808220714i44f92828jb27df60f58291a2@mail.gmail.com> This is the lab with one central computer and all of the students running DrScheme on it, right? Adding a teachpack can be a computationally intensive task (since it compiles the teachpack) so it may be that these freezes you're seeing are just the result of thrashing. Robby On Thu, Aug 21, 2008 at 7:56 PM, Todd O'Bryan wrote: > Just another data point. I have a Linux lab running DrScheme 4.1 and > several students had freeze issues when they tried to add a user > teachpack right after they clicked the "Add teachpack to list..." > button. > > The OS kept working and they were able to kill MrEd, but DrScheme was > completely frozen. > > It happened to probably 5 or 6 people in each class of 25 or so. > > Todd > > On Wed, Aug 20, 2008 at 1:22 AM, Benjamin L. Russell > wrote: >> On Mon, 18 Aug 2008 14:20:27 -0500, "Grant Rettke" >> wrote: >> >>>> Does anybody have any tips on avoiding this intermittent freezing when >>>> navigating local file system directories on a system with mounted >>>> network volumes? >>> >>>Just wondering, is this a general Windows issue or a DrScheme specific issue? >>> >>>My machine at work has horrible, terrible hanging issues whenever I >>>use Explorer. >> >> Since I can navigate those same directories in Windows Explorer and >> other applications without any problems, but the intemittent freezing >> always occurs in DrScheme, this issue appears to be DrScheme-specific. >> >> -- Benjamin L. Russell >> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From cwbowron at gmail.com Fri Aug 22 10:23:57 2008 From: cwbowron at gmail.com (Christopher Bowron) Date: Thu Mar 26 02:26:21 2009 Subject: [plt-scheme] Planet Modules in distribution exe Message-ID: <114e756c0808220723x435e5f71i8cf0b9fbe209e20@mail.gmail.com> I am trying to build an mred based distribution zip, but when I unzip the produced file and try to run the exe, I get the following error message: standard-module-name-resolver: collection not found: "planet" in any of: (# #) === context === loop [Exited] Here's a screenshot: http://screencast.com/t/L4c32wQwO02 Is using Planet modules not supported when building a program for distribution or is this just a bug? The module I am using is Jay McCarthy's sqlite bindings and I am importing the module in my code using: "(require (planet jaymccarthy/sqlite/sqlite))". Everything works fine when running from sources. I'm using 4.1 on Windows XP. Thanks -- Christopher W. Bowron [ Nothing is exciting if you know what the outcome will be ] - Joseph Campbell -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080822/e5f9a438/attachment.html From mflatt at cs.utah.edu Fri Aug 22 11:12:37 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:21 2009 Subject: [plt-scheme] Planet Modules in distribution exe In-Reply-To: <114e756c0808220723x435e5f71i8cf0b9fbe209e20@mail.gmail.com> References: <114e756c0808220723x435e5f71i8cf0b9fbe209e20@mail.gmail.com> Message-ID: <20080822151238.5D7B265013B@mail-svr1.cs.utah.edu> Handling of `planet' paths was broken in stand-alone executables. I've partly fixed the problem in SVN. It should work as long as an executable doesn't use multiple versions of a particular planet package. Matthew At Fri, 22 Aug 2008 10:23:57 -0400, "Christopher Bowron" wrote: > I am trying to build an mred based distribution zip, but when I unzip the > produced file and try to run the exe, I get the following error message: > > standard-module-name-resolver: collection not found: "planet" in any of: > (# Scheme\4.1\collects> #) > > === context === > loop > > > [Exited] > > Here's a screenshot: > > http://screencast.com/t/L4c32wQwO02 > > Is using Planet modules not supported when building a program for > distribution or is this just a bug? > > The module I am using is Jay McCarthy's sqlite bindings and I am importing > the module in my code using: "(require (planet > jaymccarthy/sqlite/sqlite))". Everything works fine when running from > sources. > > I'm using 4.1 on Windows XP. > > Thanks > -- > Christopher W. Bowron > [ Nothing is exciting if you know what the outcome will be ] > - Joseph Campbell From eellwyn at googlemail.com Fri Aug 22 18:23:11 2008 From: eellwyn at googlemail.com (Elizabeth Ellwyn) Date: Thu Mar 26 02:26:21 2009 Subject: [plt-scheme] Web application example Message-ID: <8148ed170808221523o7c390683j1964b5d67ea7d9fd@mail.gmail.com> Hi everyone, I'm trying to get up and running with a basic web application, but the most basic examples aren't working for me. http://docs.plt-scheme.org/web-server/insta.html http://docs.plt-scheme.org/web-server-tutorial/index.html The first example on each of these pages gives me the following error: standard-module-name-resolver: collection not found: # in any of: (# #) I'm running PLT Scheme 4.1, Windows XP. I haven't got the foggiest what I'm doing wrong. Could someone point me in the right direction? Thanks! Beth From mflatt at cs.utah.edu Fri Aug 22 18:57:14 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:22 2009 Subject: [plt-scheme] gui text field alignment and spacing under windows xp In-Reply-To: <20070914221918.525386500AD@mail-svr1.cs.utah.edu> References: <000b01c7f717$01608640$1602a8c0@IBMI> <20070914221918.525386500AD@mail-svr1.cs.utah.edu> Message-ID: <20080822225717.27BDE6500CF@mail-svr1.cs.utah.edu> At Fri, 14 Sep 2007 16:18:36 -0600, Matthew Flatt wrote: > At Fri, 14 Sep 2007 22:34:17 +0100, "Robert Matovinovic" wrote: > > But > > what I'm wondering about is the alignment of a text field for example. Label > > text and text of the text field are not on the same base line. > > This is a bug in MrEd for Windows. It's now fixed in SVN. > > (The problem was confusion in an internal method about the font to use > in measuring text. The text-field% class uses for aligning the > label.) > > > The space > > between the label and the field is very narrow. > > I think you're right. I'll look into adding some space. I somehow ended up looking into this today (finally). The repair reported above seems to have gotten lost, so I fixed it again. And I finally adjusted the spacing between a text field and its label. Matthew From jay.mccarthy at gmail.com Fri Aug 22 19:09:16 2008 From: jay.mccarthy at gmail.com (Jay McCarthy) Date: Thu Mar 26 02:26:22 2009 Subject: [plt-scheme] Web application example In-Reply-To: <8148ed170808221523o7c390683j1964b5d67ea7d9fd@mail.gmail.com> References: <8148ed170808221523o7c390683j1964b5d67ea7d9fd@mail.gmail.com> Message-ID: Hi Beth, The tutorial requires the most recent pre-release version. It is available at: http://pre.plt-scheme.org/installers/ It will also work in the next normal release of DrScheme. I apologize for the problems, Jay On Fri, Aug 22, 2008 at 4:23 PM, Elizabeth Ellwyn wrote: > Hi everyone, > > I'm trying to get up and running with a basic web application, but the > most basic examples aren't working for me. > > http://docs.plt-scheme.org/web-server/insta.html > http://docs.plt-scheme.org/web-server-tutorial/index.html > > The first example on each of these pages gives me the following error: > > standard-module-name-resolver: collection not found: > # in any of: (# Settings\Administrator\Application Data\PLT Scheme\4.1\collects> > #) > > I'm running PLT Scheme 4.1, Windows XP. I haven't got the foggiest > what I'm doing wrong. Could someone point me in the right direction? > > Thanks! > Beth > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -- Jay McCarthy Assistant Professor / Brigham Young University http://jay.teammccarthy.org "The glory of God is Intelligence" - D&C 93 From martindemello at gmail.com Sat Aug 23 01:08:04 2008 From: martindemello at gmail.com (Martin DeMello) Date: Thu Mar 26 02:26:22 2009 Subject: [plt-scheme] tabbed editing Message-ID: Is there any way to put drscheme into a "tabbed editing" mode where all files are opened in new tabs rather than in new windows? martin From robby at cs.uchicago.edu Sat Aug 23 01:12:29 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:22 2009 Subject: [plt-scheme] tabbed editing In-Reply-To: References: Message-ID: <932b2f1f0808222212hbfa2922x95d4307fa186c2cb@mail.gmail.com> Yes, in the preferences. Editing tab, and then General tab (if memory serves). Robby On Sat, Aug 23, 2008 at 12:08 AM, Martin DeMello wrote: > Is there any way to put drscheme into a "tabbed editing" mode where > all files are opened in new tabs rather than in new windows? > > martin > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From martindemello at gmail.com Sat Aug 23 01:41:10 2008 From: martindemello at gmail.com (Martin DeMello) Date: Thu Mar 26 02:26:22 2009 Subject: [plt-scheme] tabbed editing In-Reply-To: <932b2f1f0808222212hbfa2922x95d4307fa186c2cb@mail.gmail.com> References: <932b2f1f0808222212hbfa2922x95d4307fa186c2cb@mail.gmail.com> Message-ID: thanks! another feature request: it would be nice to have a "project" mode where i could save the set of tabs i had open, and open them all at once the next time. martin On Fri, Aug 22, 2008 at 10:12 PM, Robby Findler wrote: > Yes, in the preferences. Editing tab, and then General tab (if memory serves). > > Robby > > On Sat, Aug 23, 2008 at 12:08 AM, Martin DeMello > wrote: >> Is there any way to put drscheme into a "tabbed editing" mode where >> all files are opened in new tabs rather than in new windows? >> >> martin >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> > From patrickli_2001 at hotmail.com Sat Aug 23 02:22:49 2008 From: patrickli_2001 at hotmail.com (CuppoJava) Date: Thu Mar 26 02:26:22 2009 Subject: [plt-scheme] A book recommendation for learning PLT Scheme. Message-ID: <65a40d80-fa4d-4e3a-901b-41526663f538@n38g2000prl.googlegroups.com> Hi, I'm really excited about learning PLT Scheme, and wondered if anyone can recommend a book for me. I'm currently working through How to Design Programs, but I don't find it comprehensive enough. Is there any book that covers the basics of the PLT Scheme comprehensively? I'm looking for at least, the object system, threading, continuations, and macros. I come from 9 years of Java experience. And while I do find How to Design Programs an excellent read (you can never read too much on program design), the progress is a little slow as I kinda want to just jump in and work on a project. Thanks very much -Patrick From eli at barzilay.org Sat Aug 23 02:50:57 2008 From: eli at barzilay.org (Eli Barzilay) Date: Thu Mar 26 02:26:22 2009 Subject: [plt-scheme] A book recommendation for learning PLT Scheme. In-Reply-To: <65a40d80-fa4d-4e3a-901b-41526663f538@n38g2000prl.googlegroups.com> References: <65a40d80-fa4d-4e3a-901b-41526663f538@n38g2000prl.googlegroups.com> Message-ID: <18607.45905.88196.204197@arabic.ccs.neu.edu> On Aug 22, CuppoJava wrote: > > [...] And while I do find How to Design Programs an excellent read > (you can never read too much on program design), the progress is a > little slow as I kinda want to just jump in and work on a project. I think that the guides will be perfect for you -- see the first four entries at docs.plt-scheme.org. (Note that the Web Applications guide uses functionality that is part of the nightly builds.) -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://www.barzilay.org/ Maze is Life! From chust at web.de Sat Aug 23 07:48:23 2008 From: chust at web.de (Thomas Chust) Date: Thu Mar 26 02:26:23 2009 Subject: [plt-scheme] Buggy behaviour of the R6RS enumeration module? Message-ID: <48AFF907.2080007@web.de> Hello, if I understand R6RS correctly, the procedure enum-set->list should, just as the name indicates, always return a list when passed an enum set as a parameter. But unless the set passed in is empty, the return value from that procedure is something else, as you can see by executing the example code below. Is this a bug or am I doing something wrong? cu, Thomas #lang scheme (require (lib "rnrs/enums-6.ss")) (define-enumeration foo (bar baz) foo-set) (define l0 (enum-set->list (foo-set))) (printf "(list? l0) => ~s~%(pair? l0) => ~s~%l0 => ~s~%~%" (list? l0) (pair? l0) l0) (define l1 (enum-set->list (foo-set bar))) (printf "(list? l1) => ~s~%(pair? l1) => ~s~%l1 => ~s~%~%" (list? l1) (pair? l1) l1) From robby at cs.uchicago.edu Sat Aug 23 08:08:45 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:23 2009 Subject: [plt-scheme] tabbed editing In-Reply-To: References: <932b2f1f0808222212hbfa2922x95d4307fa186c2cb@mail.gmail.com> Message-ID: <932b2f1f0808230508t4108a6a2wa90bbfb5d6157e29@mail.gmail.com> One thing you can do for now is to start up drscheme with the files on the commandline. Robby On Sat, Aug 23, 2008 at 12:41 AM, Martin DeMello wrote: > thanks! another feature request: it would be nice to have a "project" > mode where i could save the set of tabs i had open, and open them all > at once the next time. > > martin > > On Fri, Aug 22, 2008 at 10:12 PM, Robby Findler wrote: >> Yes, in the preferences. Editing tab, and then General tab (if memory serves). >> >> Robby >> >> On Sat, Aug 23, 2008 at 12:08 AM, Martin DeMello >> wrote: >>> Is there any way to put drscheme into a "tabbed editing" mode where >>> all files are opened in new tabs rather than in new windows? >>> >>> martin >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>> >>> >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From mflatt at cs.utah.edu Sat Aug 23 08:12:23 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:23 2009 Subject: [plt-scheme] Buggy behaviour of the R6RS enumeration module? In-Reply-To: <48AFF907.2080007@web.de> References: <48AFF907.2080007@web.de> Message-ID: <20080823121225.26B0A6500E0@mail-svr1.cs.utah.edu> An R6RS pair and a PLT `scheme' pair are not the same datatype. An R6RS corresponds to a PLT `scheme' mutable pair, a.k.a. "mpair". #lang scheme (require rnrs/enums-6 scheme/mpair) (define-enumeration foo (bar baz) foo-set) (define l1 (enum-set->list (foo-set bar))) (printf "(list? l1) => ~s~%(pair? l1) => ~s~%l1 => ~s~%~%" (mlist? l1) (mpair? l1) l1) ; prints #t, #t, and {bar} At Sat, 23 Aug 2008 13:48:23 +0200, Thomas Chust wrote: > Hello, > > if I understand R6RS correctly, the procedure enum-set->list should, > just as the name indicates, always return a list when passed an enum set > as a parameter. > > But unless the set passed in is empty, the return value from that > procedure is something else, as you can see by executing the example > code below. > > Is this a bug or am I doing something wrong? > > cu, > Thomas > > > #lang scheme > (require > (lib "rnrs/enums-6.ss")) > > (define-enumeration foo > (bar baz) > foo-set) > > (define l0 > (enum-set->list (foo-set))) > > (printf "(list? l0) => ~s~%(pair? l0) => ~s~%l0 => ~s~%~%" > (list? l0) > (pair? l0) > l0) > > (define l1 > (enum-set->list (foo-set bar))) > > (printf "(list? l1) => ~s~%(pair? l1) => ~s~%l1 => ~s~%~%" > (list? l1) > (pair? l1) > l1) > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From jw00000 at gmail.com Sat Aug 23 08:30:35 2008 From: jw00000 at gmail.com (JW) Date: Thu Mar 26 02:26:23 2009 Subject: [plt-scheme] (Speed) difference between make-hash and make-hasheq Message-ID: <41d635340808230530v6c88b8b0wfab3eee56fbc8eba@mail.gmail.com> Hi everyone, I'm just starting out with (PLT) Scheme, and I have a simple question for you. I was solving some problems at Project Euler, to get to know PLT Scheme. The last one, problem 14 (http://projecteuler.net/index.php?section=problems&id=14) was a particularly tough one for me, since I couldn't get my solution to work fast enough. Eventually, I solved the problem, by making my program run for about 5 minutes straight. Afterwards, I looked at solutions other people had written, and I found one that finished in less than 20 seconds. I searched for what could be wrong with my solution, and I found out that the hash table I used to cache results, made the whole thing several times slower. Eventually, I found out that using (make-hash) instead of (make-hasheq) was the root of all my problems. Why is that? Is it normal that there's such a speed difference between using 'equal?' and 'eq?'? For the record, I am using 'MzScheme v4.0 [cgc]', installed through the Ubuntu repositories (where it's marked version 2:4.0-1ubuntu1). I also put the code at http://pastie.org/258542: running it using (make-hasheq) takes about 5 seconds, with (make-hash) it takes > 5 minutes. Any help is appreciated, JW From mflatt at cs.utah.edu Sat Aug 23 08:46:41 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:23 2009 Subject: [plt-scheme] (Speed) difference between make-hash and make-hasheq In-Reply-To: <41d635340808230530v6c88b8b0wfab3eee56fbc8eba@mail.gmail.com> References: <41d635340808230530v6c88b8b0wfab3eee56fbc8eba@mail.gmail.com> Message-ID: <20080823124643.093CD6500EE@mail-svr1.cs.utah.edu> At Sat, 23 Aug 2008 14:30:35 +0200, JW wrote: > Eventually, I solved the problem, by making my > program run for about 5 minutes straight. Afterwards, I looked at > solutions other people had written, and I found one that finished in > less than 20 seconds. I searched for what could be wrong with my > solution, and I found out that the hash table I used to cache results, > made the whole thing several times slower. > > Eventually, I found out that using (make-hash) instead of > (make-hasheq) was the root of all my problems. Why is that? Is it > normal that there's such a speed difference between using 'equal?' and > 'eq?'? No, that's not normal for cases when the `equal?' comparison is easy, such as for fixnums. The problem was a bad hashing function for fixnums. Specifically, the secondary hash code (used for double hashing) was 37 for all fixnums. The hashing function is now fixed in SVN. On my machine, the example now runs in about 3.5 seconds using `make-hash', compared to about 2 seconds for `hash-hasheq'. Thanks for the report! Matthew From s.degabrielle at cs.ucl.ac.uk Sat Aug 23 08:47:53 2008 From: s.degabrielle at cs.ucl.ac.uk (Stephen De Gabrielle) Date: Thu Mar 26 02:26:24 2009 Subject: [plt-scheme] tabbed editing In-Reply-To: References: <932b2f1f0808222212hbfa2922x95d4307fa186c2cb@mail.gmail.com> Message-ID: <595b9ab20808230547n1d1d4112o5c8dfda28521c236@mail.gmail.com> This has come up before, and it's something thats on my 'to do oneday' list , but the check syntax and module browser features give you most of the benefits of a project facility, plus a little more IMHO. for instance, you can use the syntax checker to open linked files by right clicking their entry in the require form. the drsync extension also helps vc users, just not in a project. and feel free to start a project project, i'm sure many people would support it in whatever way they could. stephen On 8/23/08, Martin DeMello wrote: > thanks! another feature request: it would be nice to have a "project" > mode where i could save the set of tabs i had open, and open them all > at once the next time. > > martin > > On Fri, Aug 22, 2008 at 10:12 PM, Robby Findler > wrote: >> Yes, in the preferences. Editing tab, and then General tab (if memory >> serves). >> >> Robby >> >> On Sat, Aug 23, 2008 at 12:08 AM, Martin DeMello >> wrote: >>> Is there any way to put drscheme into a "tabbed editing" mode where >>> all files are opened in new tabs rather than in new windows? >>> >>> martin >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>> >>> >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -- Sent from Google Mail for mobile | mobile.google.com Cheers, Stephen -- Stephen De Gabrielle s.degabrielle@cs.ucl.ac.uk Telephone +44 (0)20 7679 0693 (x30693) Mobile 079 851 890 45 Project: Making Sense of Information (MaSI) Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html Home:http://www.degabrielle.name/stephen UCL Interaction Centre MPEB 8th floor University College London Gower Street London WC1E 6BT From chust at web.de Sat Aug 23 08:54:56 2008 From: chust at web.de (Thomas Chust) Date: Thu Mar 26 02:26:24 2009 Subject: [plt-scheme] Buggy behaviour of the R6RS enumeration module? In-Reply-To: <20080823121225.26B0A6500E0@mail-svr1.cs.utah.edu> References: <48AFF907.2080007@web.de> <20080823121225.26B0A6500E0@mail-svr1.cs.utah.edu> Message-ID: <48B008A0.602@web.de> Matthew Flatt wrote: > An R6RS pair and a PLT `scheme' pair are not the same datatype. An R6RS > corresponds to a PLT `scheme' mutable pair, a.k.a. "mpair". > [...] Ah, that explains everything. Thank you for the clarification! cu, Thomas From spdegabrielle at gmail.com Sat Aug 23 12:15:52 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:24 2009 Subject: [plt-scheme] tabbed editing In-Reply-To: <595b9ab20808230547n1d1d4112o5c8dfda28521c236@mail.gmail.com> References: <932b2f1f0808222212hbfa2922x95d4307fa186c2cb@mail.gmail.com> <595b9ab20808230547n1d1d4112o5c8dfda28521c236@mail.gmail.com> Message-ID: <595b9ab20808230915v59c0221ejad535febda1d9a5d@mail.gmail.com> Earlier threads on your question; saved window configurations http://list.cs.brown.edu/pipermail/plt-scheme/2007-September/thread.html#20726 message > http://list.cs.brown.edu/pipermail/plt-scheme/2007-September/020726.html "projects" http://list.cs.brown.edu/pipermail/plt-scheme/2007-September/thread.html#20787 message > http://list.cs.brown.edu/pipermail/plt-scheme/2007-September/020787.html I have quoted here; http://code.google.com/p/projects-project/wiki/ResumeFiles s. On Sat, Aug 23, 2008 at 1:47 PM, Stephen De Gabrielle wrote: > > This has come up before, and it's something thats on my 'to do oneday' > list , but the check syntax and module browser features give you most > of the benefits of a project facility, plus a little more IMHO. > for instance, you can use the syntax checker to open linked files by > right clicking their entry in the require form. > > the drsync extension also helps vc users, just not in a project. > > and feel free to start a project project, i'm sure many people would > support it in whatever way they could. > > stephen > > > On 8/23/08, Martin DeMello wrote: > > thanks! another feature request: it would be nice to have a "project" > > mode where i could save the set of tabs i had open, and open them all > > at once the next time. > > > > martin > > > > On Fri, Aug 22, 2008 at 10:12 PM, Robby Findler > > wrote: > >> Yes, in the preferences. Editing tab, and then General tab (if memory > >> serves). > >> > >> Robby > >> > >> On Sat, Aug 23, 2008 at 12:08 AM, Martin DeMello > >> wrote: > >>> Is there any way to put drscheme into a "tabbed editing" mode where > >>> all files are opened in new tabs rather than in new windows? > >>> > >>> martin > >>> _________________________________________________ > >>> For list-related administrative tasks: > >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme > >>> > >>> > >> > > _________________________________________________ > > For list-related administrative tasks: > > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > > > -- > Sent from Google Mail for mobile | mobile.google.com > > Cheers, > > Stephen > > -- > Stephen De Gabrielle > s.degabrielle@cs.ucl.ac.uk > Telephone +44 (0)20 7679 0693 (x30693) > Mobile 079 851 890 45 > Project: Making Sense of Information (MaSI) > Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html > Home:http://www.degabrielle.name/stephen > > > UCL Interaction Centre > MPEB 8th floor > University College London > Gower Street > London WC1E 6BT -- Cheers, Stephen -- Stephen De Gabrielle s.degabrielle@cs.ucl.ac.uk Telephone +44 (0)20 7679 0693 (x30693) Mobile 079 851 890 45 Project: Making Sense of Information (MaSI) Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html Home:http://www.degabrielle.name/stephen UCL Interaction Centre MPEB 8th floor University College London Gower Street London WC1E 6BT From geb_a at yahoo.com Sat Aug 23 14:14:33 2008 From: geb_a at yahoo.com (geb a) Date: Thu Mar 26 02:26:24 2009 Subject: [plt-scheme] Problems reading contracts Message-ID: <590977.3502.qm@web50910.mail.re2.yahoo.com> I am having trouble understanding the new documentation using contracts. I would like to overwrite a file that exists but I'm doing something improperly. my code: (with-output-to-file "foo.txt" (lambda() (write x)) 'truncate) The documentation says that mode-flag : (one-of/c 'binary 'text) = 'binary (one-of/c 'error 'append 'update 'replace 'truncate 'truncate/replace) I've tried many different combinations of flags but have not been able to land on the right one. Would someone explain the above notation to me so that I will be able to read the documenation a bit better? Thanks so much for your time. Sincerely, Dan From robby at cs.uchicago.edu Sat Aug 23 14:24:16 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:24 2009 Subject: [plt-scheme] Problems reading contracts In-Reply-To: <590977.3502.qm@web50910.mail.re2.yahoo.com> References: <590977.3502.qm@web50910.mail.re2.yahoo.com> Message-ID: <932b2f1f0808231124k7aae93f3w2fc73a67b19160b4@mail.gmail.com> The with-output-to-file function in the scheme language is different than the one in the mzscheme language. In the scheme language, you need a keyword #:exists 'truncate and in the mzscheme language, you just need the symbol. hth, Robby On Sat, Aug 23, 2008 at 1:14 PM, geb a wrote: > I am having trouble understanding the new documentation using contracts. I would like to overwrite a file that exists but I'm doing something improperly. > > my code: > (with-output-to-file "foo.txt" (lambda() (write x)) 'truncate) > > The documentation says that > mode-flag : (one-of/c 'binary 'text) = 'binary > (one-of/c 'error 'append 'update 'replace 'truncate 'truncate/replace) > > I've tried many different combinations of flags but have not been able to land on the right one. Would someone explain the above notation to me so that I will be able to read the documenation a bit better? > > Thanks so much for your time. > > Sincerely, > > Dan > > > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From robby at cs.uchicago.edu Sat Aug 23 15:31:44 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:24 2009 Subject: [plt-scheme] Completions from distinct manuals In-Reply-To: <44769BDDD74D40599E48BD68AC7A726A@IBMI> References: <932b2f1f0808151319m510dac70w9a0f5803f829497@mail.gmail.com> <44769BDDD74D40599E48BD68AC7A726A@IBMI> Message-ID: <932b2f1f0808231231m137f30o2428f3c0898b9a0d@mail.gmail.com> You want this: (text:get-completions/manuals (list 'mytest/mytest-elk)) what you have below gets the exports from the file "mytest/main.ss" not the file "mytest/mytest-elk.ss". hth, Robby On Sat, Aug 16, 2008 at 4:31 PM, Robert Matovinovic wrote: > I tried what you wrote, but can't confirm that it works. Actually I have the > same behavior as before. Obviously I wasn't clear enough about my test phase > editions to get-mytest-manual-keywords in mytest-tool: > > Only the first line of the of the following block which is an excerpt of > get-mytest-manual-keywords is the real one. All others are tests what > happens to the word list with other collections. The last one is the > "all-words" option which works anyway. So I assume you did not comment out > these parts, which yields in a completions list with all words including > that of my collection. As I already mentioned that I know works. Otherwise I > can't explain to myself why it worked for you. > > (set! words (text:get-completions/manuals (list 'mytest))) > ; (dbgprn "~n~nmytest words:~n~a" words) > ; (set! words (text:get-completions/manuals (list 'mysterx > 'mytest))) > ; (dbgprn "~n~nmysterx and mytest words:~n~a" words) > ; (set! words (text:get-completions/manuals (list 'frtime))) > ; (dbgprn "~n~nfrtime words:~n~a" words) > ; (set! words (text:get-completions/manuals (list 'mysterx))) > ; (dbgprn "~n~nmysterx words:~n~a" words) > ; (set! words (text:get-completions/manuals #f)) > ; (dbgprn "~n~nall words:~n~a" words) > > So there is still something to solve. I'd appreciate if you could look at it > again. I'll be away for the next 14 days so there is no hurry. > Thank you very much > Robert > >> -----Urspr?ngliche Nachricht----- >> Von: robby.findler@gmail.com [mailto:robby.findler@gmail.com] >> Im Auftrag von Robby Findler >> Gesendet: Freitag, 15. August 2008 22:19 >> An: Robert Matovinovic >> Cc: Matthew Flatt >> Betreff: Re: [plt-scheme] Completions from distinct manuals >> >> >> Thanks. It looks like you've run afoul of the wrong >> place/missing @defmodule declaration problem in Scribble. I'm >> not sure how, but there should probably be a better error >> message for this case. Anyways, this version of mytest.scrbl >> works. I'll also note that, when you use @defmodule, you'll >> see it underline the module in red when it is not linked up >> properly, which is also a useful clue sometimes. >> >> #lang scribble/doc >> @(require "common.ss") >> @title[#:style 'toc]{@bold{MrMytest}: A DrScheme Interface to >> MyTest} @defmodule[mytest/mytest-elk] >> >> @local-table-of-contents[#:style 'immediate-only] >> >> @defform[(mytest-cmd args)] >> >> @index-section[] >> >> >> hth, >> Robby >> >> On Fri, Aug 15, 2008 at 8:17 AM, Robert Matovinovic >> wrote: >> > It took a while to strip things down for a demo, but I'm >> grateful that >> > you will have a look at it. In mytest-tool.ss there is a function >> > get-mytest-manual-keywords which load completion lists. For demo >> > purposes it loads lists from several collections and prints >> the lists >> > to standard output. You will see that text:get-completions/manuals >> > gives back all the lists except the one for 'mytest. I combined for >> > example mysterx and mytest, but only for #f (all words)the single >> > command from my language mytest-cmd is in the list and will >> be shown >> > if it is a completion after pressing ctrl+/. You can check >> that after >> > compilation running DrScheme and select MyTest Compatible Mode as >> > language. >> > >> > BTW I found that F1 for help only works if the cursor is in >> front or >> > inside a word but not at the end. I find that somewhat annoying >> > because I mostly use it that way. If the cursor is at the end of a >> > word only the main page of Help Desk opens with no further >> actions. If >> > that's by purpose, I'd like to understand why. >> > >> > Robert >> > >> > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From spdegabrielle at gmail.com Sat Aug 23 19:42:09 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:25 2009 Subject: [plt-scheme] tabbed editing In-Reply-To: <595b9ab20808230915v59c0221ejad535febda1d9a5d@mail.gmail.com> References: <932b2f1f0808222212hbfa2922x95d4307fa186c2cb@mail.gmail.com> <595b9ab20808230547n1d1d4112o5c8dfda28521c236@mail.gmail.com> <595b9ab20808230915v59c0221ejad535febda1d9a5d@mail.gmail.com> Message-ID: <595b9ab20808231642m37bb878ck9623825c271f0225@mail.gmail.com> Hi, I finally pulled some bits together for a non-working tab-saver-resumer. problem: project.psp saves at '/' and I'm not successfully saving the path names, If anyone has a moment to take a look? s. -------------- next part -------------- A non-text attachment was scrubbed... Name: projects-project.zip Type: application/zip Size: 7015 bytes Desc: not available Url : http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080824/6c77f4c9/projects-project.zip From grettke at acm.org Sat Aug 23 23:45:30 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:25 2009 Subject: [plt-scheme] [maybe off-topic] The theory of testing Message-ID: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> Hi folks, I recently had a good chat with my friend about unit testing. His company is thinking of making unit testing part of the "standard process". I gave him my take on unit testing, that: 1. Most developers don't know why they exist. 2. They are usually not maintained, or only maintained to gain code coverage. 3. Project failure then "proves" that unit tests are pointless 4. Unit tests go away I suggested that this maybe combated with a "theory for development", primarily that there is some contract that comes from requirements and naturally translates into something that may be executed, namely a unit tests. This seems to be the critical link that %80 of developers haven't got, and that is why unit tests aren't written or maintained. Is it a simple idea? It seems that idea. I just want developers to have a reason for writing unit tests, a reason that they can understand and argue for or against. Such an approach seems like it is one of the seedlings for developing an overall theory for the development process. Is this what HTDP does, and leads to? I suspect it does. I will find out. Best wishes, Grant From lunarc.lists at gmail.com Sun Aug 24 01:46:07 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:26 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> Message-ID: 2008/8/21 Matthew Flatt : > The process representing the resource accepts reader requests and lets > them run them in parallel; when a reader asks to become a writer, then > the managing process waits for all the other readers to finish before > granting the conversion; if there's already a pending writer, then all > new writer-conversion requests are rejected. The process can see when a > reader/writer terminates, and it can adjust accordingly. The enclosed > "rwlock.ss" illustrates this implementation. I have a couple of questions: (so far =) 1) What is the purpose of 'reply'? The clients seem to read back from their accept channels right away, so what is to be lost by blocking on the calls to channel-put? 2) Looking at the documentation, 'remove' doesn't specify which argument to the 'equals?' function comes from the list, your use in removing a reader from the reader list assumes it is the second argument. Is this correct? (I find filter clearer here in any case, even if it does go through the whole list) Thanks for the help, Henk From lunarc.lists at gmail.com Sun Aug 24 01:55:40 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:26 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> Message-ID: 2008/8/21 Shriram Krishnamurthi : > Just fyi, it so happens your shiny new hammer actually has a hidden > crack in its handle, its head is made of untemepered steel, and the > joint between the pieces lacks any fastening so at some unpredictable > point during heavy use, the head will go flying and will smash a hole > in some precious object. But this will happen without you noticing > it, so you keep pounding away and will wonder why the nail isn't going > any further into the wall. Do you mean to say that there is something broken about semaphores or that they are simply not an adequately abstracted synchronization tool? Henk From mflatt at cs.utah.edu Sun Aug 24 07:11:24 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:26 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> Message-ID: <20080824111127.D095E6500D9@mail-svr1.cs.utah.edu> At Sun, 24 Aug 2008 01:46:07 -0400, "Henk Boom" wrote: > 2008/8/21 Matthew Flatt : > > The process representing the resource accepts reader requests and lets > > them run them in parallel; when a reader asks to become a writer, then > > the managing process waits for all the other readers to finish before > > granting the conversion; if there's already a pending writer, then all > > new writer-conversion requests are rejected. The process can see when a > > reader/writer terminates, and it can adjust accordingly. The enclosed > > "rwlock.ss" illustrates this implementation. > > I have a couple of questions: (so far =) > > 1) What is the purpose of 'reply'? The clients seem to read back from > their accept channels right away, so what is to be lost by blocking on > the calls to channel-put? The client might be delayed indefinitely, either due to scheduling or being explicitly suspended by some third party. You don't want to block the server (and all other threads that might talk to the server) while one client is delayed. > 2) Looking at the documentation, 'remove' doesn't specify which > argument to the 'equals?' function comes from the list, your use in > removing a reader from the reader list assumes it is the second > argument. Is this correct? (I find filter clearer here in any case, > even if it does go through the whole list) Yes. I meant to fix the `remove' docs to clarify the order, but `filter' seems like a good solution. Matthew From geoff at knauth.org Sun Aug 24 07:11:43 2008 From: geoff at knauth.org (Geoffrey S. Knauth) Date: Thu Mar 26 02:26:26 2009 Subject: [plt-scheme] [maybe off-topic] The theory of testing In-Reply-To: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> Message-ID: <79EDDCD3-464B-445C-A623-981CD4DE78C9@knauth.org> I think in my entire life there was only a brief period when I was young when I managed to crank out code in high volume without lots of tests and miraculously everything worked. The rest of the time I've been deservedly bitten for such recklessness. We are all human beings and the reality is we need something to check the soundness of our coding with wild abandon. Every time I write code quickly without bothering to test my assumptions I just know I'm asking for trouble and when I end up in the debugger I usually find something really stupid that would easily have been averted by slowing down a little, thinking more, and writing a contract and a test. As a pilot I wouldn't think of taking off without pre-flight checks-- you're never supposed to ASSume anything, you're supposed to use a checklist (design recipe). Lives depend on it. The FAA, insurance companies and lawyers eat you alive if you don't check before you leap. If a project fails, it doesn't prove unit tests are pointless; probably the project wasn't what the customer wanted or there was a higher level design flaw. Unit tests don't guarantee perfection, they just improve the odds. In my code, if I write more than a trivial amount of code and don't write tests, I'd say there's an 80% chance that something is broken. If I write just a few tests, maybe there's only a 5% chance. If I put a lot of thinking into my tests, I can get that percentage much closer to zero, but I know if I really want the holy grail of zero defects, I need help from mathematicians and formal methods. Then again, quantum physicists may tell me the slight chance of improbable events means I can never get to zero. Regarding advice for your friend, I can think of plenty of times when I worked at companies, people wrote a lot of code in a hurry, they wrote with different mind sets, they didn't write tests, and then the processing of tracking down flaws and bugs consumed painful months. It's a world of hurt. Geoff On Aug 23, 2008, at 23:45, Grant Rettke wrote: > Hi folks, > > I recently had a good chat with my friend about unit testing. His > company is thinking of making unit testing part of the "standard > process". I gave him my take on unit testing, that: > > 1. Most developers don't know why they exist. > 2. They are usually not maintained, or only maintained to gain code > coverage. > 3. Project failure then "proves" that unit tests are pointless > 4. Unit tests go away > > I suggested that this maybe combated with a "theory for development", > primarily that there is some contract that comes from requirements and > naturally translates into something that may be executed, namely a > unit tests. This seems to be the critical link that %80 of developers > haven't got, and that is why unit tests aren't written or maintained. > Is it a simple idea? It seems that idea. I just want developers to > have a reason for writing unit tests, a reason that they can > understand and argue for or against. Such an approach seems like it is > one of the seedlings for developing an overall theory for the > development process. > > Is this what HTDP does, and leads to? I suspect it does. I will find > out. > > Best wishes, > > Grant > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From toddobryan at gmail.com Sun Aug 24 09:18:30 2008 From: toddobryan at gmail.com (Todd O'Bryan) Date: Thu Mar 26 02:26:26 2009 Subject: [plt-scheme] Re: Any tips for avoiding intermittent freezing when navigating file system directories with mounted network volumes in DrScheme? In-Reply-To: <932b2f1f0808220714i44f92828jb27df60f58291a2@mail.gmail.com> References: <74jia4hvk0ena11cvch0neuq7hlfca7jh5@4ax.com> <74jia4hvk0ena11cvch0neuq7hlfca7jh5-e09XROE/p8c@public.gmane.org> <756daca50808181220r2e6dfd8fqaecdab70748016de@mail.gmail.com> <5bana45vi6vddqituc6fhl434psijor8rv@4ax.com> <904774730808211756o4065dd28sf465eb1269ce88e2@mail.gmail.com> <932b2f1f0808220714i44f92828jb27df60f58291a2@mail.gmail.com> Message-ID: <904774730808240618m27d23884xb6675e6bc50281b2@mail.gmail.com> I don't think so, because the freeze happens after clicking the Add teachpack to list... button, but before the file browser appears. The rest of the system is responsive and when I look in the system monitor, mred is marked as sleeping without using lots of CPU or memory. Let me know if I can provide more info that would be helpful, Todd On Fri, Aug 22, 2008 at 10:14 AM, Robby Findler wrote: > This is the lab with one central computer and all of the students > running DrScheme on it, right? Adding a teachpack can be a > computationally intensive task (since it compiles the teachpack) so it > may be that these freezes you're seeing are just the result of > thrashing. > > Robby > > On Thu, Aug 21, 2008 at 7:56 PM, Todd O'Bryan wrote: >> Just another data point. I have a Linux lab running DrScheme 4.1 and >> several students had freeze issues when they tried to add a user >> teachpack right after they clicked the "Add teachpack to list..." >> button. >> >> The OS kept working and they were able to kill MrEd, but DrScheme was >> completely frozen. >> >> It happened to probably 5 or 6 people in each class of 25 or so. >> >> Todd >> >> On Wed, Aug 20, 2008 at 1:22 AM, Benjamin L. Russell >> wrote: >>> On Mon, 18 Aug 2008 14:20:27 -0500, "Grant Rettke" >>> wrote: >>> >>>>> Does anybody have any tips on avoiding this intermittent freezing when >>>>> navigating local file system directories on a system with mounted >>>>> network volumes? >>>> >>>>Just wondering, is this a general Windows issue or a DrScheme specific issue? >>>> >>>>My machine at work has horrible, terrible hanging issues whenever I >>>>use Explorer. >>> >>> Since I can navigate those same directories in Windows Explorer and >>> other applications without any problems, but the intemittent freezing >>> always occurs in DrScheme, this issue appears to be DrScheme-specific. >>> >>> -- Benjamin L. Russell >>> >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> > From robby at cs.uchicago.edu Sun Aug 24 10:24:34 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:26 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: <20080824111127.D095E6500D9@mail-svr1.cs.utah.edu> References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> <20080824111127.D095E6500D9@mail-svr1.cs.utah.edu> Message-ID: <932b2f1f0808240724r650b5db5s5818decd17133bf1@mail.gmail.com> On Sun, Aug 24, 2008 at 6:11 AM, Matthew Flatt wrote: > At Sun, 24 Aug 2008 01:46:07 -0400, "Henk Boom" wrote: >> 2008/8/21 Matthew Flatt : >> > The process representing the resource accepts reader requests and lets >> > them run them in parallel; when a reader asks to become a writer, then >> > the managing process waits for all the other readers to finish before >> > granting the conversion; if there's already a pending writer, then all >> > new writer-conversion requests are rejected. The process can see when a >> > reader/writer terminates, and it can adjust accordingly. The enclosed >> > "rwlock.ss" illustrates this implementation. >> >> I have a couple of questions: (so far =) >> >> 1) What is the purpose of 'reply'? The clients seem to read back from >> their accept channels right away, so what is to be lost by blocking on >> the calls to channel-put? > > The client might be delayed indefinitely, either due to scheduling or > being explicitly suspended by some third party. You don't want to block > the server (and all other threads that might talk to the server) while > one client is delayed. But don't take Matthew's word for it! I bet you can make a particular group of readers/writers (affectionately known as a "unit test") and demonstrate the difference between the two possibilities. Robby From Ken.Dickey at whidbey.com Sun Aug 24 11:56:45 2008 From: Ken.Dickey at whidbey.com (Ken Dickey) Date: Thu Mar 26 02:26:26 2009 Subject: [plt-scheme] [maybe off-topic] The theory of testing In-Reply-To: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> Message-ID: <200808240856.45732.Ken.Dickey@whidbey.com> On Saturday 23 August 2008 20:45:30 Grant Rettke wrote: > Hi folks, > > I recently had a good chat with my friend about unit testing. His > company is thinking of making unit testing part of the "standard > process". I gave him my take on unit testing, that: > > 1. Most developers don't know why they exist. > 2. They are usually not maintained, or only maintained to gain code > coverage. 3. Project failure then "proves" that unit tests are pointless > 4. Unit tests go away Unit tests must be part of the development process. They are a safety net. Yes, you can walk over the void without one, but the winds of change are sudden and strong. Without unit tests, you end up with a very brittle product which is extremely expensive to change and maintain. Unit tests lower the cost and risk of change. For a commercial perspective see: http://xpdx.org/files/ExtremeSuccess/ [Note that Memetrics sold to Accenture recently]. $0.02, -KenD From grettke at acm.org Sun Aug 24 16:49:03 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:27 2009 Subject: [plt-scheme] [maybe off-topic] The theory of testing In-Reply-To: <200808240856.45732.Ken.Dickey@whidbey.com> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> <200808240856.45732.Ken.Dickey@whidbey.com> Message-ID: <756daca50808241349y8c990dam62c99f52e2f195f@mail.gmail.com> On Sun, Aug 24, 2008 at 10:56 AM, Ken Dickey wrote: > For a commercial perspective see: Did you guys expand your unit testing philosophy to differentiate unit and integration testing? Did you do any test-generation based on contracts, or did you revise your unit tests as the product definition changed? Based on the fact you "life on a small island" now I suspect it all turned out pretty well! :) From jos.koot at telefonica.net Sun Aug 24 17:31:44 2008 From: jos.koot at telefonica.net (Jos Koot) Date: Thu Mar 26 02:26:27 2009 Subject: [plt-scheme] [maybe off-topic] The theory of testing References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> Message-ID: <000a01c90630$ceba9120$2101a8c0@uw2b2dff239c4d> In my opinion, HtDP is one of the few books that do integrate specification, testing and coding. Yet I think that for a substantial software project even more has to be considered: 1: What are we aiming for? (a questions whose answer usually is not clear at the very beginning, but should be made clear during the early stages of the development) 2: A preliminary answer to question 1 (but not yet a complete specification) 3: Feasibility studies: do we have the apropriate algorithms and resources? Are they sufficient to do the job within constraints of space and time? 4: Repeat 1, 2 and 3 until something like a specification is obtained. 5: Specification includes: 5a: What will the user see: a user manual (in my opinion to be produced before going on to the steps to follow) The user manual can also be a test as to whether or not the product will satisfy the expectations of the user. Let the user judge. If necessary repeat from step 1. 5b: A design (programmers manual): what the programmer has to produce, what languages and software will be required. 5c: An essential part of the design is a testing suite (both correctness and measurements of required space and time) 5d: Tests must include normal use but also all situations at the very edge of the specification (where apropriate, bulk tests included; this may require the preparation of large data-sets, which have to be designed and produced too) 6: Although at this point we dont have any working code yet, the project is almost finished. Your boss may be nervous about the fact that there is nothing to show working yet, though. 7: Do the coding or have it done by programmers (programming is not the same as designing) 8: During coding of the product proper and its tests, apply the tests immediately as far as possible. If the project is well designed, tests can be applied to separate parts of the project. 9: Deliver: Finished (apart from maintenance) I followed this procedure for a major file-system project (some decades ago) I left the project during step 6 (my boss very stressed), but three months later the product was delivered (the person who did steps 7, 8 and 9, is stil a good friend of mine). As far as I know only once a bug was found after delivery (found by myself, identified within 5 minutes and fixed (+ tested and redelivered) within a day) In the above scheme I did not consider the aspects of costs and deadlines. These aspects may put a great stress on the correct evolvement of the process (I got engaged in the project after it was behind schedule by 400% already even without finishing step 1 properly. Some prestige was involved, therefore costs were not a main issue. The original deadline was one year. I took 9 months for steps 1-6. The remaining steps took 3 months: total 1 year when not counting the time wasted before I got into the project) Jos ----- Original Message ----- From: "Grant Rettke" To: "plt-scheme List" Sent: Sunday, August 24, 2008 5:45 AM Subject: [plt-scheme] [maybe off-topic] The theory of testing > Hi folks, > > I recently had a good chat with my friend about unit testing. His > company is thinking of making unit testing part of the "standard > process". I gave him my take on unit testing, that: > > 1. Most developers don't know why they exist. > 2. They are usually not maintained, or only maintained to gain code > coverage. > 3. Project failure then "proves" that unit tests are pointless > 4. Unit tests go away > > I suggested that this maybe combated with a "theory for development", > primarily that there is some contract that comes from requirements and > naturally translates into something that may be executed, namely a > unit tests. This seems to be the critical link that %80 of developers > haven't got, and that is why unit tests aren't written or maintained. > Is it a simple idea? It seems that idea. I just want developers to > have a reason for writing unit tests, a reason that they can > understand and argue for or against. Such an approach seems like it is > one of the seedlings for developing an overall theory for the > development process. > > Is this what HTDP does, and leads to? I suspect it does. I will find out. > > Best wishes, > > Grant > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From steve.huffman at gmail.com Sun Aug 24 20:00:45 2008 From: steve.huffman at gmail.com (Steve Huffman) Date: Thu Mar 26 02:26:27 2009 Subject: [plt-scheme] using custom readers Message-ID: <504d74030808241700n72ac3aeapef0b396d6cf6a05@mail.gmail.com> Hello, I have a module in "slice.scm" that provides versions of read and read-syntax that uses a custom readtable. If I say (require "slice.scm) then use #reader "slice.scm" I can use my custom readtable for the following expression, and all is well. What I'd really like to be able to do is define another module that uses my "slice" reader without having to say #reader "slice.scm" before every form. For example, it would really be really nice to start a module with "#lang slice" and have it use my reader. Right now when I do that I get an error similar to: default-load-handler: expected a `module' declaration for `foo', found: something else in: # Thanks, Steve From mflatt at cs.utah.edu Sun Aug 24 21:05:52 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:27 2009 Subject: [plt-scheme] using custom readers In-Reply-To: <504d74030808241700n72ac3aeapef0b396d6cf6a05@mail.gmail.com> References: <504d74030808241700n72ac3aeapef0b396d6cf6a05@mail.gmail.com> Message-ID: <20080825010554.3C4886500C6@mail-svr1.cs.utah.edu> At Sun, 24 Aug 2008 17:00:45 -0700, "Steve Huffman" wrote: > I have a module in "slice.scm" that provides versions of read and > read-syntax that uses a custom readtable. > > If I say (require "slice.scm) then use #reader "slice.scm" I can use > my custom readtable for the following expression, and all is well. > > What I'd really like to be able to do is define another module that > uses my "slice" reader without having to say #reader "slice.scm" > before every form. For example, it would really be really nice to > start a module with "#lang slice" and have it use my reader. Right now > when I do that I get an error similar to: > > default-load-handler: expected a `module' declaration for `foo', > found: something else in: # The `slide/lang/reader' module needs to provide a `read' that's a little different than the one from "slice.scm". Instead of reading a single expression, the reader from `slide/lang/reader' should read until it hits an EOF. Then it should package up the forms that it found (before EOF) into a `module' form. The `wrap-read-all' function from `syntax/module-reader' is useful for creating the latter kind of reader. As an example, see the R5RS reader in the `r5rs/lang/reader' module. Matthew From Ken.Dickey at whidbey.com Sun Aug 24 23:37:08 2008 From: Ken.Dickey at whidbey.com (Ken Dickey) Date: Thu Mar 26 02:26:27 2009 Subject: [plt-scheme] [maybe off-topic] The theory of testing In-Reply-To: <756daca50808241349y8c990dam62c99f52e2f195f@mail.gmail.com> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> <200808240856.45732.Ken.Dickey@whidbey.com> <756daca50808241349y8c990dam62c99f52e2f195f@mail.gmail.com> Message-ID: <200808242037.08775.Ken.Dickey@whidbey.com> On Sunday 24 August 2008 13:49:03 Grant Rettke wrote: > Did you guys expand your unit testing philosophy to differentiate unit > and integration testing? There were a separate set of system acceptance tests as well as a stress tester which had pre and post conditions (database setup/teardown stuff) to simulate various configurations and use cases, driven by a generative model (simulated customers w a bunch of parametrized randomness). > Did you do any test-generation based on contracts, or did you revise > your unit tests as the product definition changed? We did not use sw contracts, but did have a database of "user stories" (use cases), which changed over time based on changing business requirements. If you don't know eXtreme Programming, the scenario is that the "voice of the customer" defines "user stories" with engineering. Engineering supplies time estimates for the stories. The customer decides the order in which user stories are implemented. And the customer can change the order, add or remove stories at any time. These started as 8 x 5 cards, then grew to a spreadsheet, then to a web interface to a database. The shared stores as the "voice of the customer" gave a unifying language which sales/marketing, management and engineering could talk about features. Especially as sales could see what engineering was doing (which stories were being implemented this week and how fast we were moving) and could request features via the SSL encrypted web interface anywhere they were. As this was happening between, e.g. London, San Francisco, and Sydney, a unifying language was important. We actually had some non-actionable stories to capture constraints. For example multiple records of the same user could be in a database under different clients, but the different clients could not cross-access data; all data was encrypted, an so on. We were fairly strict. All non-trivial functions had unit tests for every failure case as well as a/the success case(s). As we ran the test suite quite a fer times each day--sometimes every few minutes--we did not feel the need for a separate "test generator" for "contracts". Again, we did have separate system tests and a stress test. The stress test was generative. One has to trust the process. I was worried initially. When we first started we seemed to be spending half to 2/3 of the time writing test cases, but this inverted as time went on and we got better at it. We were usually within a day on estimates of time to implement individual user stories. We also spent time re-writing working code to make it more clear what was going on. We knew we were winning when the total lines of code started going down as we continued to add features. [That was close to a year into the project, and, boy did it feel good!]. > Based on the fact you "live on a small island" now I suspect it all > turned out pretty well! :) It is actually a pretty big island, but I share it. ;^) No project is without its problems, not all of them small. But in 20 years of "pushing bits" (building sw products) for companies large and small it was the best run project I have seen. It was quite rare in the the management actually trusted engineering to make engineering decisions. Again, I think the process of developing a unified language to talk about "user stories" helped out here. Cheers, -KenD From spdegabrielle at gmail.com Mon Aug 25 04:45:59 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:27 2009 Subject: [plt-scheme] drscheme extension to save an load a set of tabs Message-ID: <595b9ab20808250145m2f08ce08u9b60b156ba5492cf@mail.gmail.com> Hi, this is a first run at this; projects-project.plt ProjectsMgr is a simple drscheme extension that provides buttons to save and reload tabs. (require (planet "project.scm" ("spdegabrielle" "projects-project.plt" 1 0))) install and restart scheme to get two new buttons save-project - saves the current set of tabs load-project - load the saved set let me know what you think source at http://code.google.com/p/projects-project/source/browse/#svn/trunk Cheers, Stephen From jensaxel at soegaard.net Mon Aug 25 04:12:25 2008 From: jensaxel at soegaard.net (Jens Axel Soegaard) Date: Thu Mar 26 02:26:28 2009 Subject: [plt-scheme] [maybe off-topic] The theory of testing In-Reply-To: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> Message-ID: <48B26969.6060501@soegaard.net> Hi Grant, > I recently had a good chat with my friend about unit testing. Give this talk with Kent Beck a chance. In it he tells som great stories. Some even related to your question ;-) > http://itc.conversationsnetwork.org/shows/detail3759.html /Jens Axel From grettke at acm.org Mon Aug 25 11:59:43 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:28 2009 Subject: [plt-scheme] drscheme extension to save an load a set of tabs In-Reply-To: <595b9ab20808250145m2f08ce08u9b60b156ba5492cf@mail.gmail.com> References: <595b9ab20808250145m2f08ce08u9b60b156ba5492cf@mail.gmail.com> Message-ID: <756daca50808250859v2f0c6150g8fabd0092f35bf5a@mail.gmail.com> Hi Stephen, > let me know what you think Your first run looks good. Here are some thoughts: Your icon looks good, but it is the wrong size. It should be 32x32. My icon in DrSync looks, ok, but not good. I used pov-ray. I wish I had an artist at my disposal. I like your use of pack.ss. I had used shell scripts to package everything up. I tested out the plugin, it works fine. Inevitably now people will tell you "You should...". Here is my contribution :). You could: * Add scribble documentation. * Put the buttons on the left near the file chooser/browser. Since you are performing file operations, this is the logical place to find it. * Upper-case the icon labels and remove the dash. * When loading a project, don't re-load files that are already open. * More clearly state your goals and vision of the plugin. Files grouped into a project using this plugin, and the ability to browse code dependencies using the module browser, seem to be complementary features. * Save more than 1 project You could also: * Use a different extension that .psp. That is associated to PSP image files (on Windows atleast). * Put the project file in the users home dir, use (find-system-path 'home-dir). * I used the predicate for whether a tab has a file is to apply file-path to the tab, rather than asking a tab for its filename and checking if it exists.Tabs are created in a state where they aren't associated with a file, the only way to associate them with a file is by creating a new one or one that already exists (to the best of my knowledge at least). * A menu in the menubar might be a better place rather than buttons. * The button icons don't show up for me, but I see them configured in the button. Best wishes, Grant From wookiz at hotmail.com Mon Aug 25 12:12:29 2008 From: wookiz at hotmail.com (wooks) Date: Thu Mar 26 02:26:28 2009 Subject: [plt-scheme] Re: [maybe off-topic] The theory of testing In-Reply-To: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> Message-ID: <8703ba3b-f9ba-440d-aa25-48562550b6d6@m45g2000hsb.googlegroups.com> On Aug 23, 10:45 pm, "Grant Rettke" wrote: > Hi folks, > > I recently had a good chat with my friend about unit testing. His > company is thinking of making unit testing part of the "standard > process". I gave him my take on unit testing, that: > > 1. Most developers don't know why they exist. Of course they do. If there was management support (time and resourcing) for a proper unit testing process programmers would do it and the ones that didn't would get found out. > 2. They are usually not maintained, or only maintained to gain code coverage. See above on management support. > 3. Project failure then "proves" that unit tests are pointless Doesn't follow. All other things being equal a project that doesn't unit test is more likely to fail than one that does. > 4. Unit tests go away > don't understand that one. There is alot to be said for having a set of readily runnable automated tests attached to each program you write and designing those tests before you write the code. Boris Beizer's leaves us in no doubt as to where he stands on the issue. "If I could I would legislate a minimum standard that required execution under test of every single line of code and every decision's direction. In case I haven't made myself clear, leaving untested code in a system is stupid, short-sighted, and irresponsible." From grettke at acm.org Mon Aug 25 14:07:26 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:29 2009 Subject: [plt-scheme] Re: [maybe off-topic] The theory of testing In-Reply-To: <8703ba3b-f9ba-440d-aa25-48562550b6d6@m45g2000hsb.googlegroups.com> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> <8703ba3b-f9ba-440d-aa25-48562550b6d6@m45g2000hsb.googlegroups.com> Message-ID: <756daca50808251107i582fabf6v6b9d0456d7a9926e@mail.gmail.com> Regarding my take on XP and Unit Testing, you're preaching to the choir! What I'm sharing with you guys is based on what I've seen on *many* projects. Wooks, here is what I meant: %80 of developers don't know why unit tests exist, don't trust them, won't do them. %80 of managers don't know why unit tests exist. Inevitably "issues" occur. Developers cite the unit tests as being "useless", which becomes the justification for no longer maintaining them. That is the norm. From wookiz at hotmail.com Mon Aug 25 15:24:10 2008 From: wookiz at hotmail.com (wooks) Date: Thu Mar 26 02:26:29 2009 Subject: [plt-scheme] Re: [maybe off-topic] The theory of testing In-Reply-To: <756daca50808251107i582fabf6v6b9d0456d7a9926e@mail.gmail.com> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> <8703ba3b-f9ba-440d-aa25-48562550b6d6@m45g2000hsb.googlegroups.com> <756daca50808251107i582fabf6v6b9d0456d7a9926e@mail.gmail.com> Message-ID: <7f8857b7-8a64-428e-bb82-dc9f20dcabb7@f63g2000hsf.googlegroups.com> On Aug 25, 1:07 pm, "Grant Rettke" wrote: > Regarding my take on XP and Unit Testing, you're preaching to the choir! > > What I'm sharing with you guys is based on what I've seen on *many* projects. > > Wooks, here is what I meant: > > %80 of developers don't know why unit tests exist, don't trust them, > won't do them. > %80 of managers don't know why unit tests exist. > Inevitably "issues" occur. Developers cite the unit tests as being > "useless", which becomes the justification for no longer maintaining > them. > > That is the norm. It may have been the norm 20-25 years ago, but it's not the norm today and hasn't been the norm for a long time. In the 70's and early - mid 80's the industry absorbed itself with problem of how to develop applications more quickly - hence you had the era of CASE tools, the emergence of "4GL's" , wizards and RAD tools. The major problem then shifted to one of knowing whether what had been developed was right, hence you saw the emergence of "QA" or "testing" as a software engineering (sub) discipline in the latter part of the 80's (or at least it became more common). Developers have always known they should unit test and why they should do so. There may be issues with the degree of formality and repeatability of the process but they know what they should do. So do project management. When there is a project deadline to meet and pressure from above to meet it, it's the testing that gets squeezed and management tend to takes a punt on releasing code thats not been tested as thoroughly as it ought. The decision to release then becomes an exercise in risk management - someone decides the likelihood of inadequate testing leading to a problem and tries to assess the impact if it does. That is the norm, albeit the testing and risk management are applied with varying degrees of formality from site to site. Everybody knows you should test (and not just unit test) and the consequences of not doing so and everybody knows what corners are cut in the face of project deadlines and everybody knows the consequences that follow. From kevin at hypotheticalabs.com Mon Aug 25 15:30:06 2008 From: kevin at hypotheticalabs.com (Kevin A. Smith) Date: Thu Mar 26 02:26:29 2009 Subject: [plt-scheme] Re: [maybe off-topic] The theory of testing In-Reply-To: <7f8857b7-8a64-428e-bb82-dc9f20dcabb7@f63g2000hsf.googlegroups.com> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> <8703ba3b-f9ba-440d-aa25-48562550b6d6@m45g2000hsb.googlegroups.com> <756daca50808251107i582fabf6v6b9d0456d7a9926e@mail.gmail.com> <7f8857b7-8a64-428e-bb82-dc9f20dcabb7@f63g2000hsf.googlegroups.com> Message-ID: On Aug 25, 2008, at 3:24 PM, wooks wrote: > On Aug 25, 1:07 pm, "Grant Rettke" wrote: >> Regarding my take on XP and Unit Testing, you're preaching to the >> choir! >> >> What I'm sharing with you guys is based on what I've seen on *many* >> projects. >> >> Wooks, here is what I meant: >> >> %80 of developers don't know why unit tests exist, don't trust them, >> won't do them. >> %80 of managers don't know why unit tests exist. >> Inevitably "issues" occur. Developers cite the unit tests as being >> "useless", which becomes the justification for no longer maintaining >> them. >> >> That is the norm. > > It may have been the norm 20-25 years ago, but it's not the norm today > and hasn't been the norm for a long time. > > In the 70's and early - mid 80's the industry absorbed itself with > problem of how to develop applications more quickly - hence you had > the era of CASE tools, the emergence of "4GL's" , wizards and RAD > tools. The major problem then shifted to one of knowing whether what > had been developed was right, hence you saw the emergence of "QA" or > "testing" as a software engineering (sub) discipline in the latter > part of the 80's (or at least it became more common). > > Developers have always known they should unit test and why they > should do so. There may be issues with the degree of formality and > repeatability of the process but they know what they should do. So do > project management. When there is a project deadline to meet and > pressure from above to meet it, it's the testing that gets squeezed > and management tend to takes a punt on releasing code thats not been > tested as thoroughly as it ought. The decision to release then > becomes an exercise in risk management - someone decides the > likelihood of inadequate testing leading to a problem and tries to > assess the impact if it does. That is the norm, albeit the testing and > risk management are applied with varying degrees of formality from > site to site. > > Everybody knows you should test (and not just unit test) and the > consequences of not doing so and everybody knows what corners are cut > in the face of project deadlines and everybody knows the consequences > that follow. > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme Sadly, it's been my experience that this line of thinking only applies to the *good* developers. There just aren't enough of those. . . --Kevin From spdegabrielle at gmail.com Mon Aug 25 15:47:33 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:29 2009 Subject: [plt-scheme] drscheme extension to save an load a set of tabs In-Reply-To: <756daca50808250859v2f0c6150g8fabd0092f35bf5a@mail.gmail.com> References: <595b9ab20808250145m2f08ce08u9b60b156ba5492cf@mail.gmail.com> <756daca50808250859v2f0c6150g8fabd0092f35bf5a@mail.gmail.com> Message-ID: <595b9ab20808251247wbd76a5cu9319cdd26ccebcf5@mail.gmail.com> Thanks, I owe you the double thanks because I used drsync to work out how to do this. Your feedback is much appreciated; > Your icon looks good, but it is the wrong size. It should be 32x32. My haha! I just used a screen grabber to capture part of the screen that had project written on it new icon fixed to 32x32 (same technique - but capture from module browser) > I like your use of pack.ss. I had used shell scripts to package everything up. I am lazy > You could: > * Add scribble documentation. I just don't have the time for scribble - of course this is an opinion from ignorance of scribble - I appear trapped... > * Put the buttons on the left near the file chooser/browser. Since you > are performing file operations, this is the logical place to find it. I can't work out how to do thid (HELP) > * Upper-case the icon labels and remove the dash. I Assume You Mean Title Case > * When loading a project, don't re-load files that are already open. (added to the to-do list) > * More clearly state your goals and vision of the plugin. Files > grouped into a project using this plugin, and the ability to browse > code dependencies using the module browser, seem to be complementary > features. Sorry, at this stage it has been about what I can achieve with the mimimal effort > * Save more than 1 project I need an open-project button that lets me select a file (and save project) > You could also: > * Use a different extension that .psp. That is associated to PSP image > files (on Windows atleast). suggestions - I have changed to .ss for the moment. > * Put the project file in the users home dir, use (find-system-path 'home-dir). done thanks for the tip :) > * I used the predicate for whether a tab has a file is to apply > file-path to the tab, rather than asking a tab for its filename and > checking if it exists.Tabs are created in a state where they aren't > associated with a file, the only way to associate them with a file is > by creating a new one or one that already exists (to the best of my > knowledge at least). Umm, could you elaborate? > * A menu in the menubar might be a better place rather than buttons. yes > * The button icons don't show up for me, but I see them configured in > the button. I can't work out how to get them working. (HELP) Any help appreciated... Thanks again, Stephen #lang scheme/base (require (lib "tool.ss" "drscheme") mred mrlib/switchable-button mzlib/unit scheme/class) (provide tool@) (define tool@ (unit (import drscheme:tool^) (export drscheme:tool-exports^) (define phase1 void) (define phase2 void) (define project-icon "project.png") (define project-icon-sm "project-sm.png") (define home-dir (find-system-path 'home-dir)) (define saved-tabs-file (string->path "saved-tabs-file.ss")) (define saved-tabs-file-path (build-path home-dir saved-tabs-file)) (define (save x) (call-with-output-file saved-tabs-file-path (lambda (i) (write x i)) #:exists 'replace )) (define (load) (for-each (lambda (filename) (drscheme:unit:open-drscheme-window filename)) (if (file-exists? saved-tabs-file-path) (call-with-input-file saved-tabs-file-path (lambda (i) (read i))) '() ))) (define (projects-unit-frame-mixin super%) (class super% (inherit get-button-panel) ;; each-tab -> list of files (define (get-tab-files) (map (lambda (tab) (let ([editor (send tab get-defs)]) (when (file-exists? (send editor get-filename)) (path->string (send editor get-filename))))) (send this get-tabs))) (super-new) (inherit register-toolbar-button) (define project-icon-bitmap (make-object bitmap% project-icon-sm 'png/mask)) (define save-project-button (new switchable-button% (label "save tabs") (parent (make-object vertical-pane% (get-button-panel))) (callback (lambda (button) (save (get-tab-files)))) [bitmap project-icon-bitmap] )) (register-toolbar-button save-project-button) (send (get-button-panel) change-children (lambda (_) (cons (send save-project-button get-parent) (remq (send save-project-button get-parent) _)))) (define load-project-button (new switchable-button% (label "reload tabs") (parent (make-object vertical-pane% (get-button-panel))) (callback (lambda (button) (load))) [bitmap project-icon-bitmap] )) (register-toolbar-button load-project-button) (send (get-button-panel) change-children (lambda (_) (cons (send load-project-button get-parent) (remq (send load-project-button get-parent) _)))) )) (drscheme:get/extend:extend-unit-frame projects-unit-frame-mixin) )) On Mon, Aug 25, 2008 at 4:59 PM, Grant Rettke wrote: > Hi Stephen, > >> let me know what you think > > Your first run looks good. Here are some thoughts: > > Your icon looks good, but it is the wrong size. It should be 32x32. My > icon in DrSync looks, ok, but not good. I used pov-ray. I wish I had > an artist at my disposal. > > I like your use of pack.ss. I had used shell scripts to package everything up. > > I tested out the plugin, it works fine. Inevitably now people will > tell you "You should...". Here is my contribution :). > > You could: > * Add scribble documentation. > * Put the buttons on the left near the file chooser/browser. Since you > are performing file operations, this is the logical place to find it. > * Upper-case the icon labels and remove the dash. > * When loading a project, don't re-load files that are already open. > * More clearly state your goals and vision of the plugin. Files > grouped into a project using this plugin, and the ability to browse > code dependencies using the module browser, seem to be complementary > features. > * Save more than 1 project > > You could also: > * Use a different extension that .psp. That is associated to PSP image > files (on Windows atleast). > * Put the project file in the users home dir, use (find-system-path 'home-dir). > * I used the predicate for whether a tab has a file is to apply > file-path to the tab, rather than asking a tab for its filename and > checking if it exists.Tabs are created in a state where they aren't > associated with a file, the only way to associate them with a file is > by creating a new one or one that already exists (to the best of my > knowledge at least). > * A menu in the menubar might be a better place rather than buttons. > * The button icons don't show up for me, but I see them configured in > the button. > > Best wishes, > > Grant > -- Cheers, Stephen From spdegabrielle at gmail.com Mon Aug 25 16:58:21 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:29 2009 Subject: [plt-scheme] drscheme extension to save an load a set of tabs In-Reply-To: <595b9ab20808251247wbd76a5cu9319cdd26ccebcf5@mail.gmail.com> References: <595b9ab20808250145m2f08ce08u9b60b156ba5492cf@mail.gmail.com> <756daca50808250859v2f0c6150g8fabd0092f35bf5a@mail.gmail.com> <595b9ab20808251247wbd76a5cu9319cdd26ccebcf5@mail.gmail.com> Message-ID: <595b9ab20808251358o6a611efbtce91c3c709fa55e2@mail.gmail.com> forgot to load; (require (planet "project.scm" ("spdegabrielle" "projects-project.plt" 1 1))) s. On Mon, Aug 25, 2008 at 8:47 PM, Stephen De Gabrielle wrote: > Thanks, > > I owe you the double thanks because I used drsync to work out how to do this. > > Your feedback is much appreciated; > >> Your icon looks good, but it is the wrong size. It should be 32x32. My > haha! I just used a screen grabber to capture part of the screen that > had project written on it > new icon fixed to 32x32 (same technique - but capture from module browser) > >> I like your use of pack.ss. I had used shell scripts to package everything up. > I am lazy > >> You could: >> * Add scribble documentation. > I just don't have the time for scribble - of course this is an opinion > from ignorance of scribble - I appear trapped... > >> * Put the buttons on the left near the file chooser/browser. Since you >> are performing file operations, this is the logical place to find it. > I can't work out how to do thid (HELP) > >> * Upper-case the icon labels and remove the dash. > I Assume You Mean Title Case > >> * When loading a project, don't re-load files that are already open. > (added to the to-do list) > >> * More clearly state your goals and vision of the plugin. Files >> grouped into a project using this plugin, and the ability to browse >> code dependencies using the module browser, seem to be complementary >> features. > Sorry, at this stage it has been about what I can achieve with the > mimimal effort > >> * Save more than 1 project > I need an open-project button that lets me select a file (and save project) > >> You could also: >> * Use a different extension that .psp. That is associated to PSP image >> files (on Windows atleast). > suggestions - I have changed to .ss for the moment. > >> * Put the project file in the users home dir, use (find-system-path 'home-dir). > done thanks for the tip :) > >> * I used the predicate for whether a tab has a file is to apply >> file-path to the tab, rather than asking a tab for its filename and >> checking if it exists.Tabs are created in a state where they aren't >> associated with a file, the only way to associate them with a file is >> by creating a new one or one that already exists (to the best of my >> knowledge at least). > Umm, could you elaborate? > >> * A menu in the menubar might be a better place rather than buttons. > yes > >> * The button icons don't show up for me, but I see them configured in >> the button. > I can't work out how to get them working. (HELP) > > Any help appreciated... > > Thanks again, > > Stephen > > > #lang scheme/base > (require (lib "tool.ss" "drscheme") > mred > mrlib/switchable-button > mzlib/unit > scheme/class) > > (provide tool@) > > (define tool@ > (unit > (import drscheme:tool^) > (export drscheme:tool-exports^) > (define phase1 void) > (define phase2 void) > > (define project-icon "project.png") > (define project-icon-sm "project-sm.png") > (define home-dir (find-system-path 'home-dir)) > (define saved-tabs-file (string->path "saved-tabs-file.ss")) > (define saved-tabs-file-path (build-path home-dir saved-tabs-file)) > (define (save x) > (call-with-output-file saved-tabs-file-path > (lambda (i) (write x i)) > #:exists 'replace > )) > > (define (load) > (for-each (lambda (filename) > (drscheme:unit:open-drscheme-window filename)) > (if (file-exists? saved-tabs-file-path) > (call-with-input-file saved-tabs-file-path > (lambda (i) (read i))) > '() > ))) > > > (define (projects-unit-frame-mixin super%) > (class super% > (inherit get-button-panel) > > ;; each-tab -> list of files > (define (get-tab-files) > (map > (lambda (tab) > (let ([editor (send tab get-defs)]) > (when (file-exists? (send editor get-filename)) > (path->string (send editor get-filename))))) > (send this get-tabs))) > > (super-new) > > (inherit register-toolbar-button) > > (define project-icon-bitmap (make-object bitmap% > project-icon-sm 'png/mask)) > > (define save-project-button > (new switchable-button% > (label "save tabs") > (parent (make-object vertical-pane% (get-button-panel))) > (callback (lambda (button) (save (get-tab-files)))) > [bitmap project-icon-bitmap] > > )) > (register-toolbar-button save-project-button) > > (send (get-button-panel) change-children > (lambda (_) > (cons (send save-project-button get-parent) > (remq (send save-project-button get-parent) _)))) > > (define load-project-button > (new switchable-button% > (label "reload tabs") > (parent (make-object vertical-pane% (get-button-panel))) > (callback (lambda (button) (load))) > [bitmap project-icon-bitmap] > )) > (register-toolbar-button load-project-button) > > (send (get-button-panel) change-children > (lambda (_) > (cons (send load-project-button get-parent) > (remq (send load-project-button get-parent) _)))) > )) > (drscheme:get/extend:extend-unit-frame projects-unit-frame-mixin) > )) > > > On Mon, Aug 25, 2008 at 4:59 PM, Grant Rettke wrote: >> Hi Stephen, >> >>> let me know what you think >> >> Your first run looks good. Here are some thoughts: >> >> Your icon looks good, but it is the wrong size. It should be 32x32. My >> icon in DrSync looks, ok, but not good. I used pov-ray. I wish I had >> an artist at my disposal. >> >> I like your use of pack.ss. I had used shell scripts to package everything up. >> >> I tested out the plugin, it works fine. Inevitably now people will >> tell you "You should...". Here is my contribution :). >> >> You could: >> * Add scribble documentation. >> * Put the buttons on the left near the file chooser/browser. Since you >> are performing file operations, this is the logical place to find it. >> * Upper-case the icon labels and remove the dash. >> * When loading a project, don't re-load files that are already open. >> * More clearly state your goals and vision of the plugin. Files >> grouped into a project using this plugin, and the ability to browse >> code dependencies using the module browser, seem to be complementary >> features. >> * Save more than 1 project >> >> You could also: >> * Use a different extension that .psp. That is associated to PSP image >> files (on Windows atleast). >> * Put the project file in the users home dir, use (find-system-path 'home-dir). >> * I used the predicate for whether a tab has a file is to apply >> file-path to the tab, rather than asking a tab for its filename and >> checking if it exists.Tabs are created in a state where they aren't >> associated with a file, the only way to associate them with a file is >> by creating a new one or one that already exists (to the best of my >> knowledge at least). >> * A menu in the menubar might be a better place rather than buttons. >> * The button icons don't show up for me, but I see them configured in >> the button. >> >> Best wishes, >> >> Grant >> > > > > -- > Cheers, > > Stephen > -- Cheers, Stephen -- Stephen De Gabrielle s.degabrielle@cs.ucl.ac.uk Telephone +44 (0)20 7679 0693 (x30693) Mobile 079 851 890 45 Project: Making Sense of Information (MaSI) Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html Home:http://www.degabrielle.name/stephen UCL Interaction Centre MPEB 8th floor University College London Gower Street London WC1E 6BT From clements at brinckerhoff.org Mon Aug 25 17:14:13 2008 From: clements at brinckerhoff.org (John Clements) Date: Thu Mar 26 02:26:30 2009 Subject: [plt-scheme] Going to ICFP? Message-ID: <42CF986C-6583-4062-9FD0-C73A1D9EFFB7@brinckerhoff.org> Anyone going to ICFP & want to share a room? John Clements -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 2484 bytes Desc: not available Url : http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080825/e9b5cd8f/smime.bin From spdegabrielle at gmail.com Mon Aug 25 17:53:20 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:30 2009 Subject: [plt-scheme] drscheme extension to save an load a set of tabs In-Reply-To: <595b9ab20808251358o6a611efbtce91c3c709fa55e2@mail.gmail.com> References: <595b9ab20808250145m2f08ce08u9b60b156ba5492cf@mail.gmail.com> <756daca50808250859v2f0c6150g8fabd0092f35bf5a@mail.gmail.com> <595b9ab20808251247wbd76a5cu9319cdd26ccebcf5@mail.gmail.com> <595b9ab20808251358o6a611efbtce91c3c709fa55e2@mail.gmail.com> Message-ID: <595b9ab20808251453h4aba6b63wa47b15f0840a9333@mail.gmail.com> Provides Save Tabs and Reload Tabs buttons in DrScheme your saved tabs are saved to; 'home-dir "saved-tabs-file.ss" I am lazy I use pack.ss to make the planet package Inspiration; http://www.eclipse.org/mylyn/ (via http://list.cs.brown.edu/pipermail/plt-scheme/2007-September/020755.html ) loading (require (planet "project.scm" ("spdegabrielle" "projects-project.plt" 1 2))) To do * Add scribble documentation. * Put the buttons on the left near the file chooser/browser. - I can't work out how to do this (HELP) * When loading a project, don't re-load files that are already open. * Save more than 1 project - I need an open-project button that lets me select a file (and save project) * A menu in the menubar might be a better place rather than buttons. * The button icons don't show up - I can't work out how to get them working. (HELP) Any help appreciated... Stephen On Mon, Aug 25, 2008 at 9:58 PM, Stephen De Gabrielle wrote: > forgot to load; > > (require (planet "project.scm" ("spdegabrielle" "projects-project.plt" 1 1))) > > s. > > On Mon, Aug 25, 2008 at 8:47 PM, Stephen De Gabrielle > wrote: >> Thanks, >> >> I owe you the double thanks because I used drsync to work out how to do this. >> >> Your feedback is much appreciated; >> >>> Your icon looks good, but it is the wrong size. It should be 32x32. My >> haha! I just used a screen grabber to capture part of the screen that >> had project written on it >> new icon fixed to 32x32 (same technique - but capture from module browser) >> >>> I like your use of pack.ss. I had used shell scripts to package everything up. >> I am lazy >> >>> You could: >>> * Add scribble documentation. >> I just don't have the time for scribble - of course this is an opinion >> from ignorance of scribble - I appear trapped... >> >>> * Put the buttons on the left near the file chooser/browser. Since you >>> are performing file operations, this is the logical place to find it. >> I can't work out how to do thid (HELP) >> >>> * Upper-case the icon labels and remove the dash. >> I Assume You Mean Title Case >> >>> * When loading a project, don't re-load files that are already open. >> (added to the to-do list) >> >>> * More clearly state your goals and vision of the plugin. Files >>> grouped into a project using this plugin, and the ability to browse >>> code dependencies using the module browser, seem to be complementary >>> features. >> Sorry, at this stage it has been about what I can achieve with the >> mimimal effort >> >>> * Save more than 1 project >> I need an open-project button that lets me select a file (and save project) >> >>> You could also: >>> * Use a different extension that .psp. That is associated to PSP image >>> files (on Windows atleast). >> suggestions - I have changed to .ss for the moment. >> >>> * Put the project file in the users home dir, use (find-system-path 'home-dir). >> done thanks for the tip :) >> >>> * I used the predicate for whether a tab has a file is to apply >>> file-path to the tab, rather than asking a tab for its filename and >>> checking if it exists.Tabs are created in a state where they aren't >>> associated with a file, the only way to associate them with a file is >>> by creating a new one or one that already exists (to the best of my >>> knowledge at least). >> Umm, could you elaborate? >> >>> * A menu in the menubar might be a better place rather than buttons. >> yes >> >>> * The button icons don't show up for me, but I see them configured in >>> the button. >> I can't work out how to get them working. (HELP) >> >> Any help appreciated... >> >> Thanks again, >> >> Stephen >> >> >> #lang scheme/base >> (require (lib "tool.ss" "drscheme") >> mred >> mrlib/switchable-button >> mzlib/unit >> scheme/class) >> >> (provide tool@) >> >> (define tool@ >> (unit >> (import drscheme:tool^) >> (export drscheme:tool-exports^) >> (define phase1 void) >> (define phase2 void) >> >> (define project-icon "project.png") >> (define project-icon-sm "project-sm.png") >> (define home-dir (find-system-path 'home-dir)) >> (define saved-tabs-file (string->path "saved-tabs-file.ss")) >> (define saved-tabs-file-path (build-path home-dir saved-tabs-file)) >> (define (save x) >> (call-with-output-file saved-tabs-file-path >> (lambda (i) (write x i)) >> #:exists 'replace >> )) >> >> (define (load) >> (for-each (lambda (filename) >> (drscheme:unit:open-drscheme-window filename)) >> (if (file-exists? saved-tabs-file-path) >> (call-with-input-file saved-tabs-file-path >> (lambda (i) (read i))) >> '() >> ))) >> >> >> (define (projects-unit-frame-mixin super%) >> (class super% >> (inherit get-button-panel) >> >> ;; each-tab -> list of files >> (define (get-tab-files) >> (map >> (lambda (tab) >> (let ([editor (send tab get-defs)]) >> (when (file-exists? (send editor get-filename)) >> (path->string (send editor get-filename))))) >> (send this get-tabs))) >> >> (super-new) >> >> (inherit register-toolbar-button) >> >> (define project-icon-bitmap (make-object bitmap% >> project-icon-sm 'png/mask)) >> >> (define save-project-button >> (new switchable-button% >> (label "save tabs") >> (parent (make-object vertical-pane% (get-button-panel))) >> (callback (lambda (button) (save (get-tab-files)))) >> [bitmap project-icon-bitmap] >> >> )) >> (register-toolbar-button save-project-button) >> >> (send (get-button-panel) change-children >> (lambda (_) >> (cons (send save-project-button get-parent) >> (remq (send save-project-button get-parent) _)))) >> >> (define load-project-button >> (new switchable-button% >> (label "reload tabs") >> (parent (make-object vertical-pane% (get-button-panel))) >> (callback (lambda (button) (load))) >> [bitmap project-icon-bitmap] >> )) >> (register-toolbar-button load-project-button) >> >> (send (get-button-panel) change-children >> (lambda (_) >> (cons (send load-project-button get-parent) >> (remq (send load-project-button get-parent) _)))) >> )) >> (drscheme:get/extend:extend-unit-frame projects-unit-frame-mixin) >> )) >> >> >> On Mon, Aug 25, 2008 at 4:59 PM, Grant Rettke wrote: >>> Hi Stephen, >>> >>>> let me know what you think >>> >>> Your first run looks good. Here are some thoughts: >>> >>> Your icon looks good, but it is the wrong size. It should be 32x32. My >>> icon in DrSync looks, ok, but not good. I used pov-ray. I wish I had >>> an artist at my disposal. >>> >>> I like your use of pack.ss. I had used shell scripts to package everything up. >>> >>> I tested out the plugin, it works fine. Inevitably now people will >>> tell you "You should...". Here is my contribution :). >>> >>> You could: >>> * Add scribble documentation. >>> * Put the buttons on the left near the file chooser/browser. Since you >>> are performing file operations, this is the logical place to find it. >>> * Upper-case the icon labels and remove the dash. >>> * When loading a project, don't re-load files that are already open. >>> * More clearly state your goals and vision of the plugin. Files >>> grouped into a project using this plugin, and the ability to browse >>> code dependencies using the module browser, seem to be complementary >>> features. >>> * Save more than 1 project >>> >>> You could also: >>> * Use a different extension that .psp. That is associated to PSP image >>> files (on Windows atleast). >>> * Put the project file in the users home dir, use (find-system-path 'home-dir). >>> * I used the predicate for whether a tab has a file is to apply >>> file-path to the tab, rather than asking a tab for its filename and >>> checking if it exists.Tabs are created in a state where they aren't >>> associated with a file, the only way to associate them with a file is >>> by creating a new one or one that already exists (to the best of my >>> knowledge at least). >>> * A menu in the menubar might be a better place rather than buttons. >>> * The button icons don't show up for me, but I see them configured in >>> the button. >>> >>> Best wishes, >>> >>> Grant >>> >> >> >> >> -- >> Cheers, >> >> Stephen >> > > > > -- > Cheers, > > Stephen > > -- > Stephen De Gabrielle > s.degabrielle@cs.ucl.ac.uk > Telephone +44 (0)20 7679 0693 (x30693) > Mobile 079 851 890 45 > Project: Making Sense of Information (MaSI) > Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html > Home:http://www.degabrielle.name/stephen > > > UCL Interaction Centre > MPEB 8th floor > University College London > Gower Street > London WC1E 6BT > -- Cheers, Stephen -- Stephen De Gabrielle s.degabrielle@cs.ucl.ac.uk Telephone +44 (0)20 7679 0693 (x30693) Mobile 079 851 890 45 Project: Making Sense of Information (MaSI) Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html Home:http://www.degabrielle.name/stephen UCL Interaction Centre MPEB 8th floor University College London Gower Street London WC1E 6BT From wookiz at hotmail.com Mon Aug 25 19:10:02 2008 From: wookiz at hotmail.com (wooks) Date: Thu Mar 26 02:26:31 2009 Subject: [plt-scheme] Re: [maybe off-topic] The theory of testing In-Reply-To: References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> <8703ba3b-f9ba-440d-aa25-48562550b6d6@m45g2000hsb.googlegroups.com> <756daca50808251107i582fabf6v6b9d0456d7a9926e@mail.gmail.com> <7f8857b7-8a64-428e-bb82-dc9f20dcabb7@f63g2000hsf.googlegroups.com> Message-ID: On Aug 25, 2:30 pm, "Kevin A. Smith" wrote: > On Aug 25, 2008, at 3:24 PM, wooks wrote: > > > > > On Aug 25, 1:07 pm, "Grant Rettke" wrote: > >> Regarding my take on XP and Unit Testing, you're preaching to the > >> choir! > > >> What I'm sharing with you guys is based on what I've seen on *many* > >> projects. > > >> Wooks, here is what I meant: > > >> %80 of developers don't know why unit tests exist, don't trust them, > >> won't do them. > >> %80 of managers don't know why unit tests exist. > >> Inevitably "issues" occur. Developers cite the unit tests as being > >> "useless", which becomes the justification for no longer maintaining > >> them. > > >> That is the norm. > > > It may have been the norm 20-25 years ago, but it's not the norm today > > and hasn't been the norm for a long time. > > > In the 70's and early - mid 80's the industry absorbed itself with > > problem of how to develop applications more quickly - hence you had > > the era of CASE tools, the emergence of "4GL's" , wizards and RAD > > tools. The major problem then shifted to one of knowing whether what > > had been developed was right, hence you saw the emergence of "QA" or > > "testing" as a software engineering (sub) discipline in the latter > > part of the 80's (or at least it became more common). > > > Developers have always known they should unit test and why they > > should do so. There may be issues with the degree of formality and > > repeatability of the process but they know what they should do. So do > > project management. When there is a project deadline to meet and > > pressure from above to meet it, it's the testing that gets squeezed > > and management tend to takes a punt on releasing code thats not been > > tested as thoroughly as it ought. The decision to release then > > becomes an exercise in risk management - someone decides the > > likelihood of inadequate testing leading to a problem and tries to > > assess the impact if it does. That is the norm, albeit the testing and > > risk management are applied with varying degrees of formality from > > site to site. > > > Everybody knows you should test (and not just unit test) and the > > consequences of not doing so and everybody knows what corners are cut > > in the face of project deadlines and everybody knows the consequences > > that follow. > > _________________________________________________ > > For list-related administrative tasks: > > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > Sadly, it's been my experience that this line of thinking only applies > to the *good* developers. There just aren't enough of those. . . > I worked as a testing contractor for the best part of 14 years and did so on both sides of the Atlantic. It was extremely rare to come across a developer who either didn't know to/believe in testing their code. That they may not always do so is more to do with the way they were managed and how their productivity was assessed, than how "good" a developer they were. Their management may have focused on how quickly code was turned around or how many lines of code per day they produced and ignored their bug counts or the number of times they had to correct and release a piece of code. You've heard the phrase "There's always time to do it over but never time to do it right". Some management may have encouraged a lax attitude to unit testing on the misguided grounds that there would be a testing phase later in the project that would catch those bugs or that there was no time for it. My experience was that developer who didn't believe in testing their code, quickly changed their attitude after a series of bugs were exposed in code they had written. People do what they like on personal projects, but in an industrial setting, testing practices and their success and failure are determined and driven by the project management and their perceived priorities, not an individual developers beliefs. From anesward at mac.com Mon Aug 25 19:33:48 2008 From: anesward at mac.com (mike) Date: Thu Mar 26 02:26:31 2009 Subject: [plt-scheme] problem Message-ID: I'm presently working through the exercises and have a question about 6.6.1; it concerns making a structure definition for circle and i simply did by (define-struct circface (x y radius color)) and was able to draw the circle by: (define (draw-a-circle a-circface) (draw-circle (make-posn (circface-x a-circface) (circface-y a- circface)) (circface-radius a-circface) (circface-color a-circface))) What i tried to do initially was to define the circle structure by imbedding a posn structure within the definition but it just did not seem to work. So my question is: can you imbed a data structure within a new data structure definition? If so can i have a small hint? oh example of circle structure used for drawing was defined by: (define example1 (make-circface 100 100 50 'red)) thanks for any input mike From kevin at hypotheticalabs.com Mon Aug 25 20:27:46 2008 From: kevin at hypotheticalabs.com (Kevin A. Smith) Date: Thu Mar 26 02:26:31 2009 Subject: [plt-scheme] Re: [maybe off-topic] The theory of testing In-Reply-To: References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> <8703ba3b-f9ba-440d-aa25-48562550b6d6@m45g2000hsb.googlegroups.com> <756daca50808251107i582fabf6v6b9d0456d7a9926e@mail.gmail.com> <7f8857b7-8a64-428e-bb82-dc9f20dcabb7@f63g2000hsf.googlegroups.com> Message-ID: <8217689B-09D8-48E7-BF8B-6FBA25AAD2BB@hypotheticalabs.com> On Aug 25, 2008, at 7:10 PM, wooks wrote: > On Aug 25, 2:30 pm, "Kevin A. Smith" > wrote: >> On Aug 25, 2008, at 3:24 PM, wooks wrote: >> >> >> >>> On Aug 25, 1:07 pm, "Grant Rettke" wrote: >>>> Regarding my take on XP and Unit Testing, you're preaching to the >>>> choir! >> >>>> What I'm sharing with you guys is based on what I've seen on *many* >>>> projects. >> >>>> Wooks, here is what I meant: >> >>>> %80 of developers don't know why unit tests exist, don't trust >>>> them, >>>> won't do them. >>>> %80 of managers don't know why unit tests exist. >>>> Inevitably "issues" occur. Developers cite the unit tests as being >>>> "useless", which becomes the justification for no longer >>>> maintaining >>>> them. >> >>>> That is the norm. >> >>> It may have been the norm 20-25 years ago, but it's not the norm >>> today >>> and hasn't been the norm for a long time. >> >>> In the 70's and early - mid 80's the industry absorbed itself with >>> problem of how to develop applications more quickly - hence you had >>> the era of CASE tools, the emergence of "4GL's" , wizards and RAD >>> tools. The major problem then shifted to one of knowing whether what >>> had been developed was right, hence you saw the emergence of "QA" or >>> "testing" as a software engineering (sub) discipline in the latter >>> part of the 80's (or at least it became more common). >> >>> Developers have always known they should unit test and why they >>> should do so. There may be issues with the degree of formality and >>> repeatability of the process but they know what they should do. So >>> do >>> project management. When there is a project deadline to meet and >>> pressure from above to meet it, it's the testing that gets squeezed >>> and management tend to takes a punt on releasing code thats not >>> been >>> tested as thoroughly as it ought. The decision to release then >>> becomes an exercise in risk management - someone decides the >>> likelihood of inadequate testing leading to a problem and tries to >>> assess the impact if it does. That is the norm, albeit the testing >>> and >>> risk management are applied with varying degrees of formality from >>> site to site. >> >>> Everybody knows you should test (and not just unit test) and the >>> consequences of not doing so and everybody knows what corners are >>> cut >>> in the face of project deadlines and everybody knows the >>> consequences >>> that follow. >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> Sadly, it's been my experience that this line of thinking only >> applies >> to the *good* developers. There just aren't enough of those. . . >> > > I worked as a testing contractor for the best part of 14 years and did > so on both sides of the Atlantic. > > It was extremely rare to come across a developer who either didn't > know to/believe in testing their code. That they may not always do so > is more to do with the way they were managed and how their > productivity was assessed, than how "good" a developer they were. > > Their management may have focused on how quickly code was turned > around or how many lines of code per day they produced and ignored > their bug counts or the number of times they had to correct and > release a piece of code. You've heard the phrase "There's always time > to do it over but never time to do it right". Some management may have > encouraged a lax attitude to unit testing on the misguided grounds > that there would be a testing phase later in the project that would > catch those bugs or that there was no time for it. > > My experience was that developer who didn't believe in testing their > code, quickly changed their attitude after a series of bugs were > exposed in code they had written. On well-run projects with good people my experience mirrors yours exactly. On less well-run projects with mediocre-to-fair developers I've experienced almost the opposite. I've had "seasoned" developers with years of experience look at me like I've got two heads when I discuss the merits of unit testing. Some of these "two-head" conversations happened even after bugs were found said seasoned developer's code. The lengths these developers will go to "save" a few minutes because they see writing unit tests as "slowing them down" is truly mind-boggling. I've been programming professionally for almost 15 years and I'm still surprised when it happens. > > > People do what they like on personal projects, but in an industrial > setting, testing practices and their success and failure are > determined and driven by the project management and their perceived > priorities, not an individual developers beliefs. I think it comes down to the culture of the individual project team . If the team places value in unit testing practices then testing occurs. If not. no-one, not project managers nor edicts from management can make it happen. People will come up with a thousand reasons why they don't need unit testing. If you force them they'll pay it lip service at best and write crappy tests which fulfill their own "unit tests are bad" prophecies. > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From grettke at acm.org Mon Aug 25 20:52:03 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:31 2009 Subject: [plt-scheme] drscheme extension to save an load a set of tabs In-Reply-To: <595b9ab20808251247wbd76a5cu9319cdd26ccebcf5@mail.gmail.com> References: <595b9ab20808250145m2f08ce08u9b60b156ba5492cf@mail.gmail.com> <756daca50808250859v2f0c6150g8fabd0092f35bf5a@mail.gmail.com> <595b9ab20808251247wbd76a5cu9319cdd26ccebcf5@mail.gmail.com> Message-ID: <756daca50808251752r4b53201anefe8e773d48f5e1@mail.gmail.com> On Mon, Aug 25, 2008 at 2:47 PM, Stephen De Gabrielle wrote: >> * Upper-case the icon labels and remove the dash. > I Assume You Mean Title Case Yes. >> * I used the predicate for whether a tab has a file is to apply >> file-path to the tab, rather than asking a tab for its filename and >> checking if it exists.Tabs are created in a state where they aren't >> associated with a file, the only way to associate them with a file is >> by creating a new one or one that already exists (to the best of my >> knowledge at least). > Umm, could you elaborate? Sure, before you save the project, you check each editor to see whether or not it has got a file loaded. Rather than ask it for its filename, you can just call file-path. It will return false if the current editor is not associated with a file. From wookiz at hotmail.com Mon Aug 25 21:50:50 2008 From: wookiz at hotmail.com (wooks) Date: Thu Mar 26 02:26:31 2009 Subject: [plt-scheme] Re: [maybe off-topic] The theory of testing In-Reply-To: <8217689B-09D8-48E7-BF8B-6FBA25AAD2BB@hypotheticalabs.com> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> <8703ba3b-f9ba-440d-aa25-48562550b6d6@m45g2000hsb.googlegroups.com> <756daca50808251107i582fabf6v6b9d0456d7a9926e@mail.gmail.com> <7f8857b7-8a64-428e-bb82-dc9f20dcabb7@f63g2000hsf.googlegroups.com> <8217689B-09D8-48E7-BF8B-6FBA25AAD2BB@hypotheticalabs.com> Message-ID: <08cea1f7-3d3d-4971-a5f3-aa2df5a04399@8g2000hse.googlegroups.com> > > On well-run projects with good people my experience mirrors yours > exactly. On less well-run projects with mediocre-to-fair developers > I've experienced almost the opposite. I've had "seasoned" developers > with years of experience look at me like I've got two heads when I > discuss the merits of unit testing. Some of these "two-head" > conversations happened even after bugs were found said seasoned > developer's code. The lengths these developers will go to "save" a few > minutes because they see writing unit tests as "slowing them down" is > truly mind-boggling. I've been programming professionally for almost > 15 years and I'm still surprised when it happens. > Yep I can well believe it, but as you say they think unit testing will slow them down, which goes back to their perception of how their productivity is being assessed which goes back to how they are being managed. I see Test Driven Design as a means of hoodwinking programmers into testing by making it seem and feel like a coding activity - which is consistent with their pre-conceived notions of productivity which derive from how they are managed. > > > People do what they like on personal projects, but in an industrial > > setting, testing practices and their success and failure are > > determined and driven by the project management and their perceived > > priorities, not an individual developers beliefs. > > I think it comes down to the culture of the individual project team . > If the team places value in unit testing practices then testing > occurs. If not. no-one, not project managers nor edicts from > management can make it happen. People will come up with a thousand > reasons why they don't need unit testing. > Again I agree, but the thousand reasons they come up with are usually variations on time constraints (imposed by you know who) or the subsequent testing phase that will supposedly bail them out. Another (and this is more difficult to argue against) is that change is inevitable so in effect they are developing a throwaway prototype so there's no point in testing it. > > If you force them they'll > pay it lip service at best and write crappy tests which fulfill their > own "unit tests are bad" prophecies. > If you lay out a procedure for how things should be done and people circumvent that and something goes wrong that is traceable to their code then the question is whether such developers should prosper or even survive in the organisation. If you have a culture where the speed to release was rewarded above the correctness of the code, I can well see it happening. You talk about the culture of individual project teams, you can afford that on small projects, but not on large ones where a project teams contribution is one cog in a big wheel of development. There you need some homogenity across project team practices. If a project team is involved in some greenfield project that maybe no- one else understands, an individual culture may also hold sway, but generally I still think these things trace back to management and what developers perceive their values to be. From skyo at ccs.neu.edu Tue Aug 26 00:03:13 2008 From: skyo at ccs.neu.edu (Sky O'Mara) Date: Thu Mar 26 02:26:32 2009 Subject: [plt-scheme] problem In-Reply-To: References: Message-ID: <35B5F3EC-7C3A-41E7-B538-4B4CFEA31BA5@ccs.neu.edu> As far as I know, there shouldn't be a problem with using a structure within another structure. In what way is it not working? Here's an example of using a posn inside another structure: (define-struct foo (a)) (define my-foo (make-foo (make-posn 1 2))) (foo-a my-foo) ;; -> (make-posn 1 2) (posn-x (foo-a my-foo)) ;; -> 1 - Sky O. On Aug 25, 2008, at 7:33 PM, mike wrote: > I'm presently working through the exercises and have a question about > 6.6.1; > it concerns making a structure definition for circle and i simply did > by > (define-struct circface (x y radius color)) > and was able to draw the circle by: > (define (draw-a-circle a-circface) > (draw-circle (make-posn (circface-x a-circface) (circface-y a- > circface)) > (circface-radius a-circface) (circface-color > a-circface))) > What i tried to do initially was to define the circle structure by > imbedding > a posn structure within the definition but it just did not seem to > work. So > my question is: can you imbed a data structure within a new data > structure > definition? If so can i have a small hint? > oh example of circle structure used for drawing was defined by: > (define example1 (make-circface 100 100 50 'red)) > thanks for any input > mike > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From matthias at ccs.neu.edu Tue Aug 26 08:00:57 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:32 2009 Subject: [plt-scheme] problem In-Reply-To: <35B5F3EC-7C3A-41E7-B538-4B4CFEA31BA5@ccs.neu.edu> References: <35B5F3EC-7C3A-41E7-B538-4B4CFEA31BA5@ccs.neu.edu> Message-ID: <6CEA3286-93BC-4C8A-B5BF-13A7084BDE3C@ccs.neu.edu> Mike Aneward, Sky gave you the correct answer to your specific question. I do recommend that instead of using the draw.ss teachpack and working your way your HtDP, take a look at http://www.ccs.neu.edu/home/matthias/HtDP/Prologue/book.html read it, and use real images in drscheme together with the world.ss teachpack. Do the book exercises that don't involve drawing and otherwise look at the material linked to the above site for "drawing" exercises. -- Matthias On Aug 26, 2008, at 12:03 AM, Sky O'Mara wrote: > As far as I know, there shouldn't be a problem with using a > structure within another structure. In what way is it not working? > > Here's an example of using a posn inside another structure: > (define-struct foo (a)) > (define my-foo (make-foo (make-posn 1 2))) > (foo-a my-foo) ;; -> (make-posn 1 2) > (posn-x (foo-a my-foo)) ;; -> 1 > > - Sky O. > > On Aug 25, 2008, at 7:33 PM, mike wrote: > >> I'm presently working through the exercises and have a question about >> 6.6.1; >> it concerns making a structure definition for circle and i simply did >> by >> (define-struct circface (x y radius color)) >> and was able to draw the circle by: >> (define (draw-a-circle a-circface) >> (draw-circle (make-posn (circface-x a-circface) (circface-y a- >> circface)) >> (circface-radius a-circface) (circface-color >> a-circface))) >> What i tried to do initially was to define the circle structure by >> imbedding >> a posn structure within the definition but it just did not seem to >> work. So >> my question is: can you imbed a data structure within a new data >> structure >> definition? If so can i have a small hint? >> oh example of circle structure used for drawing was defined by: >> (define example1 (make-circface 100 100 50 'red)) >> thanks for any input >> mike >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From mike at sharedlogic.ca Tue Aug 26 08:50:25 2008 From: mike at sharedlogic.ca (Michael Forster) Date: Thu Mar 26 02:26:32 2009 Subject: [plt-scheme] Multi-column list box control? Message-ID: Hi, Back in 2003, Rian Douglas asked whether any work had been done on a multi-column list box for the GUI library: http://www.cs.brown.edu/pipermail/plt-scheme/2003-July/003251.html I'm in need of one for a database application, and, no, arranging multiple list boxes side-by-side won't suffice. Of course, I'm quite willing to hack one myself. However, being a hack for myself, it likely wouldn't be fit for public consumption, and I wouldn't want to have to maintain it under the mred collection directory in the face of PLT updates on my various computers. Given that, has anyone any advice on how to pull the various private mred bits (kernel.ss, etc.) into a separate library directory structure. Or, would this be as much trouble maintenance- wise? Thanks, Mike From farr at MIT.EDU Tue Aug 26 09:55:39 2008 From: farr at MIT.EDU (Will Farr) Date: Thu Mar 26 02:26:32 2009 Subject: [plt-scheme] Question About FFI Callbacks Message-ID: Hello all, I have a quick question about FFI Callbacks. I'm trying to wrap up some more of the GSL (the parts involving integration and numerical differentiation) which require the user to supply a procedure that implements the function to be integrated or differentiated. This requires callbacks. These functions want to get a pointer to a C struct defined as struct gsl_function_struct { double (* function) (double x, void * params); void * params; }; typedef struct gsl_function_struct gsl_function ; This is a manually-created closure (which I won't need because the FFI will take care of closing over local scope when it creates a callback, but is still a nice gesture on the part of the GSL designers). I would like to wrap it up in a cstruct object in the FFI as follows: (define-cstruct _gsl-function ((function (_fun _double _pointer -> _double)) (params _pointer))) But, when I do, trying to create a _gsl-function struct gives the following error: (make-gsl-function (lambda (x junk) x) #f) => ptr-set!: setting fpointer value with extra arguments Am I doing something wrong? Is this an FFI bug? Have I just missed the boat on callbacks, and the FFI is not as amazing as it sounds about automagically handling everything? Thanks for any help you can give me. Will P.S.---This would also be a good time for somebody to recoil in horror about the possibility of memory-management issues (i.e. function pointers moving during callbacks and not getting corrected on the GSL stack, etc), if that's an issue. Thanks again! From S.Scholz at herts.ac.uk Tue Aug 26 13:28:13 2008 From: S.Scholz at herts.ac.uk (Sven-Bodo Scholz) Date: Thu Mar 26 02:26:32 2009 Subject: [plt-scheme] Final CFP and extended deadline IFL 2008 Message-ID: <20080826172813.GD10945@herts.ac.uk> ******************************************************************************** * * FINAL CALL FOR PAPERS -- EXTENDED DEADLINE!! * CALL FOR PARTICIPATION * * 20th International Symposium on the * Implementation and Application of Functional Languages * IFL 2008 * 10-12.Sept 2008, Hatfield UK * * http://events.sac-home.org/ifl2008/ * ******************************************************************************** UPDATED DEADLINES: * Submission for draft proceedings: NOW 1. Sept * Early Registration: NOW 2. Sept Please note, that the draft proceedings do NOT require full papers; extended abstracts will be considered too. ******************************************************************************** The aim of the IFL symposia is to bring together researchers actively engaged in the implementation and application of functional and function-based programming languages. They provide an open forum for researchers who wish to present and discuss new ideas and concepts, work in progress, preliminary results, etc. related primarily but not exclusively to the implementation and application of functional languages. Formal proceedings are produced after the symposium, so that authors can incorporate the feedback from discussions at the symposium in their published papers. Topics ====== Topics of interest include, but are not limited to: * language concepts * type checking * compilation techniques * (abstract) interpretation * generic programming techniques * automatic program generation * array processing * concurrent/parallel programming * concurrent/parallel program execution * functional programming on embedded systems * functional programming on multi-cores/ many-cores * heap management * runtime profiling * performance measurements * debugging and tracing * (abstract) machine architectures * verification * formal aspects * tools and programming techniques Papers on applications or tools demonstrating the suitability of novel ideas in any of the above areas and contributions on related theoretical work are also welcomed. The change of the symposium name adding the term application, introduced in 2004, is to reflect the broader scope IFL has gained over the years. Paper Submissions ================= Prospective authors are encouraged to submit papers to be published in the draft proceedings and to present them at the symposium. All contributions must be written in English, conform to the Springer-Verlag LNCS series format and not exceed 16 pages. The draft proceedings will appear as a Technical Report of the School of Computer Science of the University of Hertfordshire. Attendees of IFL 2008 will have the opportunity to submit a revised version of their paper for post-symposium reviewing. As in previous years, we hope that selected papers will be published by Springer Verlag in the Lecture Notes in Computer Science (LNCS) Series. The Peter Landin Prize ====================== Since 2002 every year the Peter Landin Prize of 150 GBP is awarded to the best paper presented at the symposium, as selected by the program committee. Important Dates =============== * Submission for draft proceedings: NOW 1. Sept. * Early Registration: NOW 2. Sept. * Symposium: 10-12. September * Submission for post-refereeing: 14. November * Notification of acceptance / rejection: 23. January 2009 * Submission of a camera ready version: 20. February 2009 Contact ======= For further details see or contact us by email: events sac-home.org From gregory.woodhouse at gmail.com Tue Aug 26 13:56:54 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:26:33 2009 Subject: [plt-scheme] [maybe off-topic] The theory of testing In-Reply-To: <000a01c90630$ceba9120$2101a8c0@uw2b2dff239c4d> References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> <000a01c90630$ceba9120$2101a8c0@uw2b2dff239c4d> Message-ID: <10CBB6A5-C622-4760-901C-A7FB7F682091@gmail.com> On Aug 24, 2008, at 2:31 PM, Jos Koot wrote: > In my opinion, HtDP is one of the few books that do integrate > specification, testing and coding. Yet I think that for a > substantial software project even more has to be considered: In all fairness, HtDP is a book about writing programs, not managing (or developing) large projects. It seems to me that this entirely appropriate for a first course - though I fully agree that unit tests and contracts fall within the scope of a text such as this. That being said, the transition from school projects involving maybe hundreds of lines of code, to commercial applications with tens of thousands (or even millions) of lines of code can be a bit daunting. It's also an area where most programmers end up learning "on the job", or at least this has been my experience. This brings up another point. The OO community has generally been successful in selling the idea that OO is the appropriate paradigm for complex projects, and there is tool support out there, such as the Rational/IBM suite of tools, making languages like Java much more attractive to industry. "You can't win if you don't finish the race." --Richard Petty http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080826/6b732c78/attachment.htm From grettke at acm.org Tue Aug 26 14:07:52 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:34 2009 Subject: [plt-scheme] Planet is not working Message-ID: <756daca50808261107web8a5b6j2ee970020d40e09e@mail.gmail.com> Get the message: The servlet terminated abnormally. Please ask the author to fix the problem based on the details in the Web server's log file. Powered by PLT From gregory.woodhouse at gmail.com Tue Aug 26 14:10:05 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:26:34 2009 Subject: [plt-scheme] Persistence solutions for v4.1 Message-ID: What is the current situation with persistence solutions in v4.1? I've looked in Planet but don't see anything that works with the current version. I'd be happy with something I could use with SQLite for the time being, though I'd eventually like to be able to work with MySQL, PostgreSQL or (maybe) Oracle. "Those who are enamored of practice without theory are like a pilot who goes into a ship without rudder or compass." --Leonardo da Vinci (1452-1519) http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080826/eb834eee/attachment.html From grettke at acm.org Tue Aug 26 14:10:54 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:35 2009 Subject: [plt-scheme] Re: Planet is not working In-Reply-To: <756daca50808261107web8a5b6j2ee970020d40e09e@mail.gmail.com> References: <756daca50808261107web8a5b6j2ee970020d40e09e@mail.gmail.com> Message-ID: <756daca50808261110q3060e5dej2bfd52a238034b42@mail.gmail.com> Now it works fine. On Tue, Aug 26, 2008 at 1:07 PM, Grant Rettke wrote: > Get the message: > > The servlet terminated abnormally. > Please ask the author to fix the problem based on the details in the > Web server's log file. > > Powered by PLT > From gregory.woodhouse at gmail.com Tue Aug 26 14:18:50 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:26:35 2009 Subject: [plt-scheme] Multi-column list box control? In-Reply-To: References: Message-ID: <56A7994E-37BD-43F6-B55A-1C7988F7BF3B@gmail.com> On Aug 26, 2008, at 5:50 AM, Michael Forster wrote: > Hi, > > Back in 2003, Rian Douglas asked whether any work had been done > on a multi-column list box for the GUI library: > > http://www.cs.brown.edu/pipermail/plt-scheme/2003-July/003251.html > > I'm in need of one for a database application, and, no, arranging > multiple > list boxes side-by-side won't suffice. > > Of course, I'm quite willing to hack one myself. However, being a > hack for > myself, it likely wouldn't be fit for public consumption, and I > wouldn't want to > have to maintain it under the mred collection directory in the face > of PLT > updates on my various computers. Given that, has anyone any advice on > how to pull the various private mred bits (kernel.ss, etc.) into a > separate > library directory structure. Or, would this be as much trouble > maintenance- > wise? > > Thanks, > > Mike We ran into something like this. Some developers wrote their own multi-column list box (in Delphi, not Scheme). It turned out to cause all kind of problems with screen readers and so had to be replaced. But my point is simply that there is demand for such a thing, particularly in data intensive applications. "Mathematics is the science of patterns." --Lynn Arthur Steen, 1988 http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080826/790a6b64/attachment.htm From jay.mccarthy at gmail.com Tue Aug 26 14:51:10 2008 From: jay.mccarthy at gmail.com (Jay McCarthy) Date: Thu Mar 26 02:26:35 2009 Subject: [plt-scheme] Persistence solutions for v4.1 In-Reply-To: References: Message-ID: Check out Snooze. It may be up your alley. There is also a PostgreSQL library. (Snooze uses it and the SQLite library internally.) Jay On Tue, Aug 26, 2008 at 12:10 PM, Woodhouse Gregory wrote: > What is the current situation with persistence solutions in v4.1? I've > looked in Planet but don't see anything that works with the current version. > I'd be happy with something I could use with SQLite for the time being, > though I'd eventually like to be able to work with MySQL, PostgreSQL or > (maybe) Oracle. > > > > "Those who are enamored of practice > without theory are like a pilot who goes > into a ship without rudder or compass." > --Leonardo da Vinci (1452-1519) > http://www.gwoodhouse.com > http://GregWoodhouse.ImageKind.com > > > > > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > -- Jay McCarthy Assistant Professor / Brigham Young University http://jay.teammccarthy.org "The glory of God is Intelligence" - D&C 93 From noelwelsh at gmail.com Tue Aug 26 14:54:26 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:26:36 2009 Subject: [plt-scheme] Persistence solutions for v4.1 In-Reply-To: References: Message-ID: I plan to update Snooze on Thursday. HTH, N. On Tue, Aug 26, 2008 at 7:10 PM, Woodhouse Gregory wrote: > What is the current situation with persistence solutions in v4.1? I've > looked in Planet but don't see anything that works with the current version. > I'd be happy with something I could use with SQLite for the time being, > though I'd eventually like to be able to work with MySQL, PostgreSQL or > (maybe) Oracle. From mike at sharedlogic.ca Tue Aug 26 15:00:35 2008 From: mike at sharedlogic.ca (Michael Forster) Date: Thu Mar 26 02:26:36 2009 Subject: [plt-scheme] Multi-column list box control? In-Reply-To: <56A7994E-37BD-43F6-B55A-1C7988F7BF3B@gmail.com> References: <56A7994E-37BD-43F6-B55A-1C7988F7BF3B@gmail.com> Message-ID: <477646D0-5EB2-44FF-907A-ECC334B13C72@sharedlogic.ca> On 26-Aug-08, at 1:18 PM, Woodhouse Gregory wrote: > > On Aug 26, 2008, at 5:50 AM, Michael Forster wrote: > >> Hi, >> >> Back in 2003, Rian Douglas asked whether any work had been done >> on a multi-column list box for the GUI library: >> >> http://www.cs.brown.edu/pipermail/plt-scheme/2003-July/003251.html >> >> I'm in need of one for a database application, and, no, arranging >> multiple >> list boxes side-by-side won't suffice. >> >> Of course, I'm quite willing to hack one myself. However, being a >> hack for >> myself, it likely wouldn't be fit for public consumption, and I >> wouldn't want to >> have to maintain it under the mred collection directory in the face >> of PLT >> updates on my various computers. Given that, has anyone any advice >> on >> how to pull the various private mred bits (kernel.ss, etc.) into a >> separate >> library directory structure. Or, would this be as much trouble >> maintenance- >> wise? >> >> Thanks, >> >> Mike > > We ran into something like this. Some developers wrote their own > multi-column list box (in Delphi, not Scheme). It turned out to > cause all kind of problems with screen readers and so had to be > replaced. But my point is simply that there is demand for such a > thing, particularly in data intensive applications. Yeah, LispWorks had a nice one. Hmmm... continuations, multi-column list panel, continuations, multi... -Mike -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080826/7bcb27c6/attachment.html From jos.koot at telefonica.net Tue Aug 26 15:06:43 2008 From: jos.koot at telefonica.net (Jos Koot) Date: Thu Mar 26 02:26:37 2009 Subject: [plt-scheme] [maybe off-topic] The theory of testing References: <756daca50808232045g22e337a0i8513c830a73d633@mail.gmail.com> <000a01c90630$ceba9120$2101a8c0@uw2b2dff239c4d> <10CBB6A5-C622-4760-901C-A7FB7F682091@gmail.com> Message-ID: <001001c907ae$e1a1efc0$2101a8c0@uw2b2dff239c4d> You are right about by making the distinction between writing programs and managing large projects. I did not mean to underestimate HtDP. I do not, realy. But we should be aware of the fact that some of the students we learn how to program will end up managing large projects. And even for those that will not do large scale projects: even a small project done in the capacity of a professional producing software for another party, should attack their job along the same lines: - First make sure what the costomer expects. - Then provide material that can prove that the costomer will receive what he/she expects. - Finally provide the product according to the specs of the first step and apply the prove that it is what the consumer expects. - Also make sure that the previous three steps are followed during maintenance. May be nowadays there are following up courses in managing large scale projects, but I have never seen them. What I did experience is that managers are put in charge without any substantial knowledge of the techniques required to produce the product. Too often I have seen managers that did courses in managing without having any idea about what they are managing. Programming is an art. Managing is a skill (may be even an art too), but managing without substantial knowledge of what is to be managed is evil. Well, that's somewhat obtrusive, I am aware of that, but I hate managers that tell me what to do when it is obvious that they haven't the slightest idea what I am doing or what I should do. In short: a manager must have substantial knowledge of the product to be delivered and the techniques required to make the product. In my humble opinion, management must not be abstracted from what is being managed. Oh yes, there may be some general rules that apply to all kinds of management, but ultimately, management without substance is vain. Just my humble opinion. Jos ----- Original Message ----- From: Woodhouse Gregory To: Jos Koot Cc: Grant Rettke ; plt-scheme List Sent: Tuesday, August 26, 2008 7:56 PM Subject: Re: [plt-scheme] [maybe off-topic] The theory of testing On Aug 24, 2008, at 2:31 PM, Jos Koot wrote: In my opinion, HtDP is one of the few books that do integrate specification, testing and coding. Yet I think that for a substantial software project even more has to be considered: In all fairness, HtDP is a book about writing programs, not managing (or developing) large projects. It seems to me that this entirely appropriate for a first course - though I fully agree that unit tests and contracts fall within the scope of a text such as this. That being said, the transition from school projects involving maybe hundreds of lines of code, to commercial applications with tens of thousands (or even millions) of lines of code can be a bit daunting. It's also an area where most programmers end up learning "on the job", or at least this has been my experience. This brings up another point. The OO community has generally been successful in selling the idea that OO is the appropriate paradigm for complex projects, and there is tool support out there, such as the Rational/IBM suite of tools, making languages like Java much more attractive to industry. "You can't win if you don't finish the race." --Richard Petty http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080826/afd06bf5/attachment.htm From goetter at mazama.net Tue Aug 26 15:12:23 2008 From: goetter at mazama.net (Ben Goetter) Date: Thu Mar 26 02:26:37 2009 Subject: [plt-scheme] Very basic problem requiring (planet untyped/unlib/string) Message-ID: <48B45597.4050906@mazama.net> The sequence #lang scheme (require (planet untyped/unlib/string)) yields the following diagnostics: Welcome to DrScheme, version 4.1 [3m]. Language: Module; memory limit: 128 megabytes. compile: unbound variable in module setup-plt: error: during making for /untyped/unlib.plt/3/8 (unlib) setup-plt: compile: unbound variable in module Flushing the planet cache doesn't seem to help. Starting from an empty cache (assuming that "planet show" tells the truth), the above require pulls in Normally-installed packages: dherman test.plt 1 3 ryanc require.plt 1 3 ryanc scripting.plt 1 1 schematics macro.plt 1 2 schematics namespace.plt 1 0 schematics schemeunit.plt 2 10 schematics schemeunit.plt 3 3 untyped unlib.plt 3 8 I'm new to planet, and not sure how to proceed from here. The unlib.plt 3.8 string.ss looks fine to me. What could I do to chase this problem down? Thanks, Ben From matthias at ccs.neu.edu Tue Aug 26 15:19:20 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:38 2009 Subject: [plt-scheme] Multi-column list box control? In-Reply-To: <477646D0-5EB2-44FF-907A-ECC334B13C72@sharedlogic.ca> References: <56A7994E-37BD-43F6-B55A-1C7988F7BF3B@gmail.com> <477646D0-5EB2-44FF-907A-ECC334B13C72@sharedlogic.ca> Message-ID: Why don't you point someone to the LispWorks code, which I believe is freeware now, and see whether someone on the list wishes to contribute a port to Planet? -- Matthias On Aug 26, 2008, at 3:00 PM, Michael Forster wrote: > > On 26-Aug-08, at 1:18 PM, Woodhouse Gregory wrote: > >> >> On Aug 26, 2008, at 5:50 AM, Michael Forster wrote: >> >>> Hi, >>> >>> Back in 2003, Rian Douglas asked whether any work had been done >>> on a multi-column list box for the GUI library: >>> >>> http://www.cs.brown.edu/pipermail/plt-scheme/2003-July/003251.html >>> >>> I'm in need of one for a database application, and, no, arranging >>> multiple >>> list boxes side-by-side won't suffice. >>> >>> Of course, I'm quite willing to hack one myself. However, being >>> a hack for >>> myself, it likely wouldn't be fit for public consumption, and I >>> wouldn't want to >>> have to maintain it under the mred collection directory in the >>> face of PLT >>> updates on my various computers. Given that, has anyone any >>> advice on >>> how to pull the various private mred bits (kernel.ss, etc.) into >>> a separate >>> library directory structure. Or, would this be as much trouble >>> maintenance- >>> wise? >>> >>> Thanks, >>> >>> Mike >> >> We ran into something like this. Some developers wrote their own >> multi-column list box (in Delphi, not Scheme). It turned out to >> cause all kind of problems with screen readers and so had to be >> replaced. But my point is simply that there is demand for such a >> thing, particularly in data intensive applications. > > Yeah, LispWorks had a nice one. Hmmm... continuations, multi- > column list panel, continuations, multi... > > -Mike > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080826/b7794c11/attachment.html From robby at cs.uchicago.edu Tue Aug 26 15:24:07 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:38 2009 Subject: [plt-scheme] Re: Planet is not working In-Reply-To: <756daca50808261110q3060e5dej2bfd52a238034b42@mail.gmail.com> References: <756daca50808261107web8a5b6j2ee970020d40e09e@mail.gmail.com> <756daca50808261110q3060e5dej2bfd52a238034b42@mail.gmail.com> Message-ID: <932b2f1f0808261224r69597ec8gd3299d0c2f0e89e6@mail.gmail.com> Thanks for the report. There will be a little bit more downtime at some point today (and then hopefully back up with some new functionality). Apologies. Robby On Tue, Aug 26, 2008 at 1:10 PM, Grant Rettke wrote: > Now it works fine. > > On Tue, Aug 26, 2008 at 1:07 PM, Grant Rettke wrote: >> Get the message: >> >> The servlet terminated abnormally. >> Please ask the author to fix the problem based on the details in the >> Web server's log file. >> >> Powered by PLT >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From mike at sharedlogic.ca Tue Aug 26 15:35:56 2008 From: mike at sharedlogic.ca (Michael Forster) Date: Thu Mar 26 02:26:38 2009 Subject: [plt-scheme] Multi-column list box control? In-Reply-To: References: <56A7994E-37BD-43F6-B55A-1C7988F7BF3B@gmail.com> <477646D0-5EB2-44FF-907A-ECC334B13C72@sharedlogic.ca> Message-ID: <619963EA-F9BB-4A33-8A35-BA4CB2F662BB@sharedlogic.ca> On 26-Aug-08, at 2:19 PM, Matthias Felleisen wrote: > > Why don't you point someone to the LispWorks code, which I believe > is freeware now, and see whether someone on the list wishes to > contribute a port to Planet? -- Matthias > LispWorks is still a commercial CL :-) For now, I've defined a class with an interface very similar to the existing list-box%, and implemented it, crudely, using horizontal panels and text fields. Should be fine for my immediate application prototyping purposes. In a month or two, after I've had some time to look more closely at mred and mred extensions (maybe mrdesigner as an example), I'll take a stab at implementing something better. Thanks, Mike From martindemello at gmail.com Tue Aug 26 15:42:50 2008 From: martindemello at gmail.com (Martin DeMello) Date: Thu Mar 26 02:26:39 2009 Subject: [plt-scheme] openoffice xml Message-ID: Has anyone done work on using scheme to generate openoffice.org xml documents? Would mirrors [http://planet.plt-scheme.org/display.ss?package=mirrors.plt&owner=untyped] make a good starting point? I'm primarily interested in generating powerpoint via scheme -> ooffice -> ppt, porting http://technocrat.net/d/2006/10/31/9800 as a starting point if there's no existing code out there. martin From noelwelsh at gmail.com Tue Aug 26 15:59:03 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:26:39 2009 Subject: [plt-scheme] Very basic problem requiring (planet untyped/unlib/string) In-Reply-To: <48B45597.4050906@mazama.net> References: <48B45597.4050906@mazama.net> Message-ID: I'm getting no problems with the development version of unlib, so I'll make a release when I get time (probably Thursday). In the meantime you can probably use the current version of Unlib, but you won't have compiled files so things will load a bit more slowly. HTH, Noel On Tue, Aug 26, 2008 at 8:12 PM, Ben Goetter wrote: > The sequence > > #lang scheme > (require (planet untyped/unlib/string)) > > yields the following diagnostics: > > Welcome to DrScheme, version 4.1 [3m]. > Language: Module; memory limit: 128 megabytes. > compile: unbound variable in module > setup-plt: error: during making for /untyped/unlib.plt/3/8 (unlib) > setup-plt: compile: unbound variable in module > > Flushing the planet cache doesn't seem to help. Starting from an empty > cache (assuming that "planet show" tells the truth), the above require pulls > in > > Normally-installed packages: > dherman test.plt 1 3 > ryanc require.plt 1 3 > ryanc scripting.plt 1 1 > schematics macro.plt 1 2 > schematics namespace.plt 1 0 > schematics schemeunit.plt 2 10 > schematics schemeunit.plt 3 3 > untyped unlib.plt 3 8 > > I'm new to planet, and not sure how to proceed from here. The unlib.plt 3.8 > string.ss looks fine to me. What could I do to chase this problem down? > > Thanks, > Ben From grettke at acm.org Tue Aug 26 16:06:12 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:39 2009 Subject: [plt-scheme] Currency and rounding? Message-ID: <756daca50808261306y71e71bc1i75027f49695ecde1@mail.gmail.com> Hi folks, How do you normally handle working with currency and rounding inexact numbers? Best wishes, Grant From samth at ccs.neu.edu Tue Aug 26 16:10:57 2008 From: samth at ccs.neu.edu (Sam TH) Date: Thu Mar 26 02:26:39 2009 Subject: [plt-scheme] Currency and rounding? In-Reply-To: <756daca50808261306y71e71bc1i75027f49695ecde1@mail.gmail.com> References: <756daca50808261306y71e71bc1i75027f49695ecde1@mail.gmail.com> Message-ID: <63bb19ae0808261310k63a05402q5597dcd9ccf04407@mail.gmail.com> On Tue, Aug 26, 2008 at 4:06 PM, Grant Rettke wrote: > Hi folks, > > How do you normally handle working with currency and rounding inexact numbers? For currency, you should *never* use inexact numbers. The are a few possibilities here: - Store everything in cents - Use Scheme's exact rationals - Implement your own exact base-10 numbers And probably more that I haven't thought of. Thanks, -- sam th samth@ccs.neu.edu From patrickli_2001 at hotmail.com Mon Aug 25 09:57:35 2008 From: patrickli_2001 at hotmail.com (CuppoJava) Date: Thu Mar 26 02:26:39 2009 Subject: [plt-scheme] Programming without Objects Message-ID: Hi, I'm in the midst of learning Scheme right now, and just need a major shift in thinking. What is the basic structure behind Schemes that don't use objects? ie. in an OO language: A function that takes a list of objects, and then calls quack() on each object in turn. Therefore, any object that implements quack() can be used with that function. How would you structure a similar program in Scheme without OO? Thanks for the help -Patrick From sk at cs.brown.edu Tue Aug 26 17:14:28 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:26:40 2009 Subject: [plt-scheme] Programming without Objects In-Reply-To: References: Message-ID: Instead of asking how to translate a Java program into Scheme, why don't you do what you said you want to do -- undertake "a major shift in thinking" -- by telling us what program you want to write in the first place, and see how Schemers would do it? [Note that that isn't what you already told us. You told us how you would write the program you have in mind, not the problem behind the solution.] Shriram From troelskn at gmail.com Tue Aug 26 17:28:29 2008 From: troelskn at gmail.com (troels knak-nielsen) Date: Thu Mar 26 02:26:40 2009 Subject: [plt-scheme] Programming without Objects In-Reply-To: References: Message-ID: <98b8086f0808261428x39a3abd9odea922657df1cee3@mail.gmail.com> On Mon, Aug 25, 2008 at 3:57 PM, CuppoJava wrote: > ie. in an OO language: > > A function that takes a list of objects, and then calls quack() on > each object in turn. > > Therefore, any object that implements quack() can be used with that > function. > > How would you structure a similar program in Scheme without OO? > In Scheme: A function takes a list of functions and then calls each of them in turn. Therefore, any function can be used with that function. See also: http://people.csail.mit.edu/gregs/ll1-discuss-archive-html/msg03277.html -- troels From gregory.woodhouse at gmail.com Tue Aug 26 17:29:39 2008 From: gregory.woodhouse at gmail.com (Woodhouse Gregory) Date: Thu Mar 26 02:26:41 2009 Subject: [plt-scheme] How does a GUI application terminate? Message-ID: <0877E411-42D2-4626-B198-3BA6317D4847@gmail.com> I'm trying to get my feet wet with GUI applications, and one thing that's not clear to me is how to ask an application to close. Right now, I have code that looks like this for the "Close" menu item (define mi-quit (new menu-item% [label "Quit"] [callback (lambda (item evt) (printf "Invoking ~s menu...~n" (send item get-label)) (send f show #f))] [parent m-file])) but then it seems that I ought to signal that event processing should stop. My first thought was something like (send f close), but there is no close method in frame%. "Judge a man by his questions not his answers." --Voltaire http://www.gwoodhouse.com http://GregWoodhouse.ImageKind.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080826/de192e44/attachment.htm From cce at ccs.neu.edu Tue Aug 26 17:38:32 2008 From: cce at ccs.neu.edu (Carl Eastlund) Date: Thu Mar 26 02:26:41 2009 Subject: [plt-scheme] How does a GUI application terminate? In-Reply-To: <0877E411-42D2-4626-B198-3BA6317D4847@gmail.com> References: <0877E411-42D2-4626-B198-3BA6317D4847@gmail.com> Message-ID: <990e0c030808261438u653970a0t97e02eba2c4d2be1@mail.gmail.com> On Tue, Aug 26, 2008 at 5:29 PM, Woodhouse Gregory wrote: > I'm trying to get my feet wet with GUI applications, and one thing that's > not clear to me is how to ask an application to close. Right now, I have > code that looks like this for the "Close" menu item > (define mi-quit (new menu-item% [label "Quit"] > [callback > (lambda (item evt) > (printf "Invoking ~s menu...~n" (send > item get-label)) > (send f show #f))] > [parent m-file])) > but then it seems that I ought to signal that event processing should stop. > My first thought was something like (send f close), but there is no close > method in frame%. I'm fairly certain the GUI knows that when a window closes, it can no longer receive events. Your code looks reasonable to me. -- Carl Eastlund From mflatt at cs.utah.edu Tue Aug 26 17:47:44 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:41 2009 Subject: [plt-scheme] How does a GUI application terminate? In-Reply-To: <0877E411-42D2-4626-B198-3BA6317D4847@gmail.com> References: <0877E411-42D2-4626-B198-3BA6317D4847@gmail.com> Message-ID: <20080826214744.EA2BC65008D@mail-svr1.cs.utah.edu> At Tue, 26 Aug 2008 14:29:39 -0700, Woodhouse Gregory wrote: > I'm trying to get my feet wet with GUI applications, and one thing > that's not clear to me is how to ask an application to close. Right > now, I have code that looks like this for the "Close" menu item > > (define mi-quit (new menu-item% [label "Quit"] > [callback > (lambda (item evt) > (printf "Invoking ~s > menu...~n" (send item get-label)) > (send f show #f))] > [parent m-file])) > > but then it seems that I ought to signal that event processing should > stop. MrEd essentially adds (yield 'sync) to the end of any program that it runs. As a result, the process waits until there are no visible top-level windows, no timers running, and no functions previously queued with `queue-callback' that are still waiting to be called. So, `(send f show #f)' is probably all you need, though you might want (when (send f can-close?) (send f on-close) (send f show #f)) > My first thought was something like (send f close), but there > is no close method in frame%. For some reason (probably just history), a `close' method that performs the above sequence is added by the Framework's `frame:basic-mixin' instead of being built into `frame%'. Matthew From grettke at acm.org Tue Aug 26 23:35:48 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:41 2009 Subject: [plt-scheme] HTDP: Error highlighting question Message-ID: <756daca50808262035s5c32a37cgf362cd3506e3440a@mail.gmail.com> Hi folks, In HTDP beginner language on problem 2.2.1, when I evaluate it, DrScheme complains that there isn't a test and proceeds to highlight it by setting to define text to black and body to red. With the "white on black" syntax coloring, this makes the define text "disappear"! Is there a way to tell DrScheme to use a different error highlighting or should I just make sure folks use black-on-white for now? Best wishes, Grant From grettke at acm.org Tue Aug 26 23:39:09 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:41 2009 Subject: [plt-scheme] HTDP: Testing programs Message-ID: <756daca50808262039x634d2540y43a7a876a1f16686@mail.gmail.com> Hi folks, In HTDP beginner language on problem 2.2.1, when I evaluate it, DrScheme complains that "This program should be tested". is the intention that students start testing immediately, or we ill add tests later on? I used check-expect for now. Best wishes, Grant From grettke at acm.org Tue Aug 26 23:49:04 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:42 2009 Subject: [plt-scheme] HTDP: Fahrenheit to celsius testing question 2.2.1 Message-ID: <756daca50808262049v83f692g62290446f93149ac@mail.gmail.com> Hi folks, I added the test: (check-expect (Fahrenheit->Celsius 96) 35.5) and got the error message: "The actual value 35.5 differs from 35.5, the expected value." Why aren't they equal? I thought if both are exact that they *can* be equal. Best wishes, Grant From grettke at acm.org Tue Aug 26 23:52:08 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:42 2009 Subject: [plt-scheme] Re: HTDP: Fahrenheit to celsius testing question 2.2.1 In-Reply-To: <756daca50808262049v83f692g62290446f93149ac@mail.gmail.com> References: <756daca50808262049v83f692g62290446f93149ac@mail.gmail.com> Message-ID: <756daca50808262052k5b0b3fcbt8128c319347bec71@mail.gmail.com> Ok, thanks for "listening". I see that there is a bar over that first value. They aren't the same. Duh, anyway. On Tue, Aug 26, 2008 at 10:49 PM, Grant Rettke wrote: > Hi folks, > > I added the test: (check-expect (Fahrenheit->Celsius 96) 35.5) > > and got the error message: > > "The actual value 35.5 differs from 35.5, the expected value." > > Why aren't they equal? I thought if both are exact that they *can* be equal. > > Best wishes, > > Grant > -- http://www.wisdomandwonder.com/ From robby at cs.uchicago.edu Wed Aug 27 00:43:04 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:42 2009 Subject: [plt-scheme] HTDP: Error highlighting question In-Reply-To: <756daca50808262035s5c32a37cgf362cd3506e3440a@mail.gmail.com> References: <756daca50808262035s5c32a37cgf362cd3506e3440a@mail.gmail.com> Message-ID: <932b2f1f0808262143m55e44d5dna81398c15fff0435@mail.gmail.com> That's fixed (in SVN). Thanks, Robby On Tue, Aug 26, 2008 at 10:35 PM, Grant Rettke wrote: > Hi folks, > > In HTDP beginner language on problem 2.2.1, when I evaluate it, > DrScheme complains that there isn't a test and proceeds to highlight > it by setting to define text to black and body to red. > > With the "white on black" syntax coloring, this makes the define text > "disappear"! > > Is there a way to tell DrScheme to use a different error highlighting > or should I just make sure folks use black-on-white for now? > > Best wishes, > > Grant > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From noelwelsh at gmail.com Wed Aug 27 06:55:44 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:26:42 2009 Subject: [plt-scheme] openoffice xml In-Reply-To: References: Message-ID: I have no experience creating OpenOffice docs, but some with using Mirrors. I think it would be a good fit for this project mainly due to the useful extensions, like raw blocks, it provides. N. On Tue, Aug 26, 2008 at 8:42 PM, Martin DeMello wrote: > Has anyone done work on using scheme to generate openoffice.org xml > documents? Would mirrors > [http://planet.plt-scheme.org/display.ss?package=mirrors.plt&owner=untyped] > make a good starting point? I'm primarily interested in generating > powerpoint via scheme -> ooffice -> ppt, porting > http://technocrat.net/d/2006/10/31/9800 as a starting point if there's > no existing code out there. > > martin > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From spdegabrielle at gmail.com Wed Aug 27 07:07:19 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:42 2009 Subject: [plt-scheme] DrScheme development plugins/tools Message-ID: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> Hi, I recently put some tools on planet save/load sets of tabs in DrScheme; (the intention is to eventually associate tasks with sets of tabs ala mylyn) - http://planet.plt-scheme.org/display.ss?package=valet.plt&owner=spdegabrielle make the current directory as a planet package; - http://planet.plt-scheme.org/display.ss?package=projects-project.plt&owner=spdegabrielle Perhaps excessively, both add menu-items and buttons to the DrScheme interface. any comments on plugins appreciated; - do they fill a need? (apart from my own) - what should they do? (that they don't) what other developer/projectey features? - what would improve the interface? - bugs! - how should I integrate tasks? Cheers, Stephen From sk at cs.brown.edu Wed Aug 27 07:19:22 2008 From: sk at cs.brown.edu (Shriram Krishnamurthi) Date: Thu Mar 26 02:26:42 2009 Subject: [plt-scheme] HTDP: Testing programs In-Reply-To: <756daca50808262039x634d2540y43a7a876a1f16686@mail.gmail.com> References: <756daca50808262039x634d2540y43a7a876a1f16686@mail.gmail.com> Message-ID: The intent is that you write test cases *before* you write your functions. If you had done this, and your test cases covered your program, DrScheme would not complain at you. Bad boy! (-: Shriram On Tue, Aug 26, 2008 at 11:39 PM, Grant Rettke wrote: > Hi folks, > > In HTDP beginner language on problem 2.2.1, when I evaluate it, > DrScheme complains that "This program should be tested". > > is the intention that students start testing immediately, or we ill > add tests later on? > > I used check-expect for now. > > Best wishes, > > Grant > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From matthias at ccs.neu.edu Wed Aug 27 07:54:46 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:43 2009 Subject: [plt-scheme] Re: HTDP: Fahrenheit to celsius testing question 2.2.1 In-Reply-To: <756daca50808262052k5b0b3fcbt8128c319347bec71@mail.gmail.com> References: <756daca50808262049v83f692g62290446f93149ac@mail.gmail.com> <756daca50808262052k5b0b3fcbt8128c319347bec71@mail.gmail.com> Message-ID: <46700F2A-03F6-4BC1-84C3-292E616075EB@ccs.neu.edu> check-within is your friend. and it is essential that we teach students that numeric comparisons are complex (oops) and not simple. -- Matthias On Aug 26, 2008, at 11:52 PM, Grant Rettke wrote: > Ok, thanks for "listening". I see that there is a bar over that > first value. > > They aren't the same. Duh, anyway. > > On Tue, Aug 26, 2008 at 10:49 PM, Grant Rettke > wrote: >> Hi folks, >> >> I added the test: (check-expect (Fahrenheit->Celsius 96) 35.5) >> >> and got the error message: >> >> "The actual value 35.5 differs from 35.5, the expected value." >> >> Why aren't they equal? I thought if both are exact that they *can* >> be equal. >> >> Best wishes, >> >> Grant >> > > > > -- > http://www.wisdomandwonder.com/ > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From matthias at ccs.neu.edu Wed Aug 27 09:18:23 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:43 2009 Subject: [plt-scheme] HTDP: Testing programs In-Reply-To: References: <756daca50808262039x634d2540y43a7a876a1f16686@mail.gmail.com> Message-ID: <596869A6-DB65-46D5-AE41-EC6405CFDCE2@ccs.neu.edu> Shriram's saying that the design recipe demands the creation of examples *before* you create the function. The idea is that this scales up to larger development efforts, too. In principle, a design looks like this: ;; f->c : Number -> Number ;; convert a fahrenheit temperature to a celsius temperature (check-expect (f->c 32) 0) (check-expect (f->c 212) 100) (define (f->c f-temp) (cond [(= f-temp 32) 0] [(= f-temp 212) 100] [else f-temp])) ;; --- Over the years, HtDP and drscheme have gotten a bit out of hand. One day we'll catch up. -- Matthias On Aug 27, 2008, at 7:19 AM, Shriram Krishnamurthi wrote: > The intent is that you write test cases *before* you > write your functions. If you had done this, and your > test cases covered your program, DrScheme would > not complain at you. Bad boy! (-: > > Shriram > > On Tue, Aug 26, 2008 at 11:39 PM, Grant Rettke > wrote: >> Hi folks, >> >> In HTDP beginner language on problem 2.2.1, when I evaluate it, >> DrScheme complains that "This program should be tested". >> >> is the intention that students start testing immediately, or we ill >> add tests later on? >> >> I used check-expect for now. >> >> Best wishes, >> >> Grant >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From grettke at acm.org Wed Aug 27 12:12:31 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:43 2009 Subject: [plt-scheme] HTDP: Testing programs In-Reply-To: References: <756daca50808262039x634d2540y43a7a876a1f16686@mail.gmail.com> Message-ID: <756daca50808270912h6c275c85jd17855503776eba0@mail.gmail.com> On Wed, Aug 27, 2008 at 6:19 AM, Shriram Krishnamurthi wrote: > The intent is that you write test cases *before* you > write your functions. I see! I assumed we wouldn't do that until section 2.5. I would promise to stop assuming, but history has proven me wrong here. > If you had done this, and your test cases covered your program, DrScheme would > not complain at you. Bad boy! (-: No disagreement here hahaha. From grettke at acm.org Wed Aug 27 12:14:32 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:43 2009 Subject: [plt-scheme] HTDP: Testing programs In-Reply-To: <596869A6-DB65-46D5-AE41-EC6405CFDCE2@ccs.neu.edu> References: <756daca50808262039x634d2540y43a7a876a1f16686@mail.gmail.com> <596869A6-DB65-46D5-AE41-EC6405CFDCE2@ccs.neu.edu> Message-ID: <756daca50808270914m41b04528o690740276ce8250a@mail.gmail.com> On Wed, Aug 27, 2008 at 8:18 AM, Matthias Felleisen wrote: > Shriram's saying that the design recipe demands the creation of examples > *before* you create the function. The idea is that this scales up to larger > development efforts, too. I will introduce folks to some new friends: http://download.plt-scheme.org/doc/4.0.2/html/htdp-langs/Test_Cases.html#(form._((lib._lang/htdp-beginner..ss)._check-expect)) From deinst at gmail.com Wed Aug 27 13:30:16 2008 From: deinst at gmail.com (David Einstein) Date: Thu Mar 26 02:26:44 2009 Subject: Fwd: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <56750b780808271029t60d26c83yd27a2c1743ec465a@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> <56750b780808271029t60d26c83yd27a2c1743ec465a@mail.gmail.com> Message-ID: <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> ---------- Forwarded message ---------- From: David Einstein Date: Wed, Aug 27, 2008 at 1:29 PM Subject: Re: [plt-scheme] DrScheme development plugins/tools To: Stephen De Gabrielle On Wed, Aug 27, 2008 at 7:07 AM, Stephen De Gabrielle < spdegabrielle@gmail.com> wrote: > Hi, > > I recently put some tools on planet > > save/load sets of tabs in DrScheme; (the intention is to eventually > associate tasks with sets of tabs ala mylyn) > - > http://planet.plt-scheme.org/display.ss?package=valet.plt&owner=spdegabrielle > make the current directory as a planet package; > - > http://planet.plt-scheme.org/display.ss?package=projects-project.plt&owner=spdegabrielle > > Perhaps excessively, both add menu-items and buttons to the DrScheme > interface. > > any comments on plugins appreciated; > - do they fill a need? (apart from my own) Yes. Just being able to save and restore tabs is a great help. > > - what should they do? (that they don't) what other > developer/projectey features? I would love to find a way of having 'run' and/or 'Check syntax' ask me to save unsaved files in other tabs. I've looked a bit at this, but cannot see a simple way to do it. Version control would be great. > > - what would improve the interface? > - bugs! > - how should I integrate tasks? > > Cheers, > > Stephen > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080827/67dea645/attachment.html From grettke at acm.org Wed Aug 27 13:46:38 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:44 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> <56750b780808271029t60d26c83yd27a2c1743ec465a@mail.gmail.com> <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> Message-ID: <756daca50808271046s4212c97epbbfe54144e326ce0@mail.gmail.com> > I would love to find a way of having 'run' and/or 'Check syntax' ask me to > save unsaved files in other tabs. I've looked a bit at this, but cannot see > a simple way to do it. The code to iterate tabs and save files is in DrSync (not that it is complex, but I asked Robby enough questions, and it works so you don't have to reinvent the wheel). Maybe there is a hook before run or check syntax are executed, which could call the file saving code. From robby at cs.uchicago.edu Wed Aug 27 13:54:21 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:44 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <756daca50808271046s4212c97epbbfe54144e326ce0@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> <56750b780808271029t60d26c83yd27a2c1743ec465a@mail.gmail.com> <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> <756daca50808271046s4212c97epbbfe54144e326ce0@mail.gmail.com> Message-ID: <932b2f1f0808271054x4b0ba42crd2252b1228db7f65@mail.gmail.com> There's not an explicit hook, but you can override the callback. Robby On Wed, Aug 27, 2008 at 12:46 PM, Grant Rettke wrote: >> I would love to find a way of having 'run' and/or 'Check syntax' ask me to >> save unsaved files in other tabs. I've looked a bit at this, but cannot see >> a simple way to do it. > > The code to iterate tabs and save files is in DrSync (not that it is > complex, but I asked Robby enough questions, and it works so you don't > have to reinvent the wheel). Maybe there is a hook before run or check > syntax are executed, which could call the file saving code. > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From martindemello at gmail.com Wed Aug 27 13:58:42 2008 From: martindemello at gmail.com (Martin DeMello) Date: Thu Mar 26 02:26:44 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> Message-ID: On Wed, Aug 27, 2008 at 4:07 AM, Stephen De Gabrielle wrote: > > any comments on plugins appreciated; > - do they fill a need? (apart from my own) They definitely fill my need! My preferred method of development is to have code in one file when I'm working on it, then split it out into its own module when it's reasonably concrete. But then I need a whole list of files open, and I want them open all at once so that I don't have to stop and think about what file to open when I'm in the middle of doing something. > - what should they do? (that they don't) what other > developer/projectey features? Having the tablist saved in and picked up from the current working directory, rather than globally, would be nice > - what would improve the interface? Nameable tabsets and a dropdown list of project files in the 'restore' button. I like vim's model of one default clipboard if you don't specify, and multiple named ones. martin From grettke at acm.org Wed Aug 27 14:43:33 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:45 2009 Subject: [plt-scheme] Currency and rounding? In-Reply-To: <63bb19ae0808261310k63a05402q5597dcd9ccf04407@mail.gmail.com> References: <756daca50808261306y71e71bc1i75027f49695ecde1@mail.gmail.com> <63bb19ae0808261310k63a05402q5597dcd9ccf04407@mail.gmail.com> Message-ID: <756daca50808271143x7877e587heda5ef97c4c6f4c7@mail.gmail.com> On Tue, Aug 26, 2008 at 3:10 PM, Sam TH wrote: > For currency, you should *never* use inexact numbers. The are a few > possibilities here: Thanks Sam. What are the standards and norm for handling things like rounding, for example? From spdegabrielle at gmail.com Wed Aug 27 14:50:37 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:45 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> Message-ID: <595b9ab20808271150o76e98c54sa7731cad450aa6f7@mail.gmail.com> Thanks Martin, On Wed, Aug 27, 2008 at 6:58 PM, Martin DeMello wrote: > Having the tablist saved in and picked up from the current working > directory, rather than globally, would be nice get the latest version; you can do as many as you like, one per dir, or even one per task (require (planet "project.scm" ("spdegabrielle" "projects-project.plt" 1 5))) >> - what would improve the interface? > Nameable tabsets Filenames at the moment! > and a dropdown list of project files in the 'restore' > button. good idea - I'll try that. > I like vim's model of one default clipboard if you don't > specify, and multiple named ones. I've never used it - can you elaborate? 1.5 defaults to your home dir, I think the filename has a default too. Thanks, I appreciate your feedback, Stephen -- From matthias at ccs.neu.edu Wed Aug 27 14:54:01 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:45 2009 Subject: [plt-scheme] Currency and rounding? In-Reply-To: <756daca50808271143x7877e587heda5ef97c4c6f4c7@mail.gmail.com> References: <756daca50808261306y71e71bc1i75027f49695ecde1@mail.gmail.com> <63bb19ae0808261310k63a05402q5597dcd9ccf04407@mail.gmail.com> <756daca50808271143x7877e587heda5ef97c4c6f4c7@mail.gmail.com> Message-ID: That depends on the monetary context. At the stock exchange they used to go the closest fraction 1/16 or 1/8. Now they go round to a decimal. Warning: you can't really stick to pennies with integers in Scheme either (as Sam recommended). You need to live up to your "contract" (commercial), meaning check how they want decimals to be treated. Example: you maintain a stock portfolio with fractional shares (say a DRIP account) and you promise to keep track up to 4 digits (.9999). Then the question becomes how a daily close of 42.98 and 87.9981 shares relate to "current value". You see integers don't work here by themselves. You need a legal agreement, too. -- Matthias On Aug 27, 2008, at 2:43 PM, Grant Rettke wrote: > On Tue, Aug 26, 2008 at 3:10 PM, Sam TH wrote: >> For currency, you should *never* use inexact numbers. The are a few >> possibilities here: > > Thanks Sam. > > What are the standards and norm for handling things like rounding, > for example? > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From spdegabrielle at gmail.com Wed Aug 27 14:55:34 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:45 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> <56750b780808271029t60d26c83yd27a2c1743ec465a@mail.gmail.com> <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> Message-ID: <595b9ab20808271155m56d26b46ufc22d2614958d214@mail.gmail.com> Hi David, On Wed, Aug 27, 2008 at 6:30 PM, David Einstein wrote: >> - what should they do? (that they don't) what other >> developer/projectey features? > > I would love to find a way of having 'run' and/or 'Check syntax' ask me to > save unsaved files in other tabs. I've looked a bit at this, but cannot see > a simple way to do it. Yeah, but I'm not sure how to get plugins to call each other ??? > Version control would be great. tab filenames are currently full paths, so not vc friendly, unless you have exactly the same setup as your co-workers, but the next version 1.6 will use paths that are relative to the location of the save tabs file, so should work happily across VC. Cheers, Stephen -- Stephen De Gabrielle From spdegabrielle at gmail.com Wed Aug 27 15:03:13 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:45 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <932b2f1f0808271054x4b0ba42crd2252b1228db7f65@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> <56750b780808271029t60d26c83yd27a2c1743ec465a@mail.gmail.com> <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> <756daca50808271046s4212c97epbbfe54144e326ce0@mail.gmail.com> <932b2f1f0808271054x4b0ba42crd2252b1228db7f65@mail.gmail.com> Message-ID: <595b9ab20808271203t79c86327h30557de556503d34@mail.gmail.com> Hi, Is there a 'good' way to let plugins call each other? I understand that eclipse uses OSGi, but I don't know anything about it. Does anyone have any suggestions on how to handle this? Cheers, Stephen On Wed, Aug 27, 2008 at 6:54 PM, Robby Findler wrote: > There's not an explicit hook, but you can override the callback. > > Robby > > On Wed, Aug 27, 2008 at 12:46 PM, Grant Rettke wrote: >>> I would love to find a way of having 'run' and/or 'Check syntax' ask me to >>> save unsaved files in other tabs. I've looked a bit at this, but cannot see >>> a simple way to do it. >> >> The code to iterate tabs and save files is in DrSync (not that it is >> complex, but I asked Robby enough questions, and it works so you don't >> have to reinvent the wheel). Maybe there is a hook before run or check >> syntax are executed, which could call the file saving code. >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > -- From robby at cs.uchicago.edu Wed Aug 27 15:07:02 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:45 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <595b9ab20808271203t79c86327h30557de556503d34@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> <56750b780808271029t60d26c83yd27a2c1743ec465a@mail.gmail.com> <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> <756daca50808271046s4212c97epbbfe54144e326ce0@mail.gmail.com> <932b2f1f0808271054x4b0ba42crd2252b1228db7f65@mail.gmail.com> <595b9ab20808271203t79c86327h30557de556503d34@mail.gmail.com> Message-ID: <932b2f1f0808271207wb3b3603n2afe33e528873327@mail.gmail.com> I think that you want to just have your tool depend on the presence of Check Syntax. DrScheme, unfortunatly, doesn't have a way for tools to declare those dependencies, but the dependencies can still exist. Both the Run button and the Check Syntax button invoke methods of the frame, which you can override. Robby On Wed, Aug 27, 2008 at 2:03 PM, Stephen De Gabrielle wrote: > Hi, > > Is there a 'good' way to let plugins call each other? > I understand that eclipse uses OSGi, but I don't know anything about it. > > Does anyone have any suggestions on how to handle this? > > Cheers, > > Stephen > > > On Wed, Aug 27, 2008 at 6:54 PM, Robby Findler wrote: >> There's not an explicit hook, but you can override the callback. >> >> Robby >> >> On Wed, Aug 27, 2008 at 12:46 PM, Grant Rettke wrote: >>>> I would love to find a way of having 'run' and/or 'Check syntax' ask me to >>>> save unsaved files in other tabs. I've looked a bit at this, but cannot see >>>> a simple way to do it. >>> >>> The code to iterate tabs and save files is in DrSync (not that it is >>> complex, but I asked Robby enough questions, and it works so you don't >>> have to reinvent the wheel). Maybe there is a hook before run or check >>> syntax are executed, which could call the file saving code. >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>> >>> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> > > > > -- > > From grettke at acm.org Wed Aug 27 15:12:27 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:46 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <932b2f1f0808271207wb3b3603n2afe33e528873327@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> <56750b780808271029t60d26c83yd27a2c1743ec465a@mail.gmail.com> <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> <756daca50808271046s4212c97epbbfe54144e326ce0@mail.gmail.com> <932b2f1f0808271054x4b0ba42crd2252b1228db7f65@mail.gmail.com> <595b9ab20808271203t79c86327h30557de556503d34@mail.gmail.com> <932b2f1f0808271207wb3b3603n2afe33e528873327@mail.gmail.com> Message-ID: <756daca50808271212u1e804d30gde5d60834bd9cdde@mail.gmail.com> See here: http://docs.plt-scheme.org/tools/implementing-tools.html and here: http://docs.plt-scheme.org/tools/Extending_the_Existing_DrScheme_Classes.html On Wed, Aug 27, 2008 at 2:07 PM, Robby Findler wrote: > I think that you want to just have your tool depend on the presence of > Check Syntax. DrScheme, unfortunatly, doesn't have a way for tools to > declare those dependencies, but the dependencies can still exist. Both > the Run button and the Check Syntax button invoke methods of the > frame, which you can override. > > Robby > > On Wed, Aug 27, 2008 at 2:03 PM, Stephen De Gabrielle > wrote: >> Hi, >> >> Is there a 'good' way to let plugins call each other? >> I understand that eclipse uses OSGi, but I don't know anything about it. >> >> Does anyone have any suggestions on how to handle this? >> >> Cheers, >> >> Stephen >> >> >> On Wed, Aug 27, 2008 at 6:54 PM, Robby Findler wrote: >>> There's not an explicit hook, but you can override the callback. >>> >>> Robby >>> >>> On Wed, Aug 27, 2008 at 12:46 PM, Grant Rettke wrote: >>>>> I would love to find a way of having 'run' and/or 'Check syntax' ask me to >>>>> save unsaved files in other tabs. I've looked a bit at this, but cannot see >>>>> a simple way to do it. >>>> >>>> The code to iterate tabs and save files is in DrSync (not that it is >>>> complex, but I asked Robby enough questions, and it works so you don't >>>> have to reinvent the wheel). Maybe there is a hook before run or check >>>> syntax are executed, which could call the file saving code. >>>> _________________________________________________ >>>> For list-related administrative tasks: >>>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>>> >>>> >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>> >> >> >> >> -- >> >> > -- http://www.wisdomandwonder.com/ From spdegabrielle at gmail.com Wed Aug 27 15:41:19 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:46 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <756daca50808271212u1e804d30gde5d60834bd9cdde@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> <56750b780808271029t60d26c83yd27a2c1743ec465a@mail.gmail.com> <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> <756daca50808271046s4212c97epbbfe54144e326ce0@mail.gmail.com> <932b2f1f0808271054x4b0ba42crd2252b1228db7f65@mail.gmail.com> <595b9ab20808271203t79c86327h30557de556503d34@mail.gmail.com> <932b2f1f0808271207wb3b3603n2afe33e528873327@mail.gmail.com> <756daca50808271212u1e804d30gde5d60834bd9cdde@mail.gmail.com> Message-ID: <595b9ab20808271241p58d6f091x5bb3316660982c29@mail.gmail.com> Thanks guys, BTW, does anyone happen to know offhand... 1. what the name of the widget that is used to implement the file, (define ...) menu-buttons at the top of the frame and the recent language selector at the bottom. 2. how to get the button icons to work. (mine just don't work for me - save and load tabs should have icons) my code; (inherit register-toolbar-button) (define project-icon-bitmap (make-object bitmap% project-icon-sm 'png/mask)) (define save-project-button (new switchable-button% (label "Save Tabs") (parent (make-object vertical-pane% (get-button-panel))) (callback save-tabs) [bitmap project-icon-bitmap] )) (register-toolbar-button save-project-button) Cheers, Stephen On Wed, Aug 27, 2008 at 8:12 PM, Grant Rettke wrote: > See here: > > http://docs.plt-scheme.org/tools/implementing-tools.html > > and here: > > http://docs.plt-scheme.org/tools/Extending_the_Existing_DrScheme_Classes.html > > On Wed, Aug 27, 2008 at 2:07 PM, Robby Findler wrote: >> I think that you want to just have your tool depend on the presence of >> Check Syntax. DrScheme, unfortunatly, doesn't have a way for tools to >> declare those dependencies, but the dependencies can still exist. Both >> the Run button and the Check Syntax button invoke methods of the >> frame, which you can override. >> >> Robby >> >> On Wed, Aug 27, 2008 at 2:03 PM, Stephen De Gabrielle >> wrote: >>> Hi, >>> >>> Is there a 'good' way to let plugins call each other? >>> I understand that eclipse uses OSGi, but I don't know anything about it. >>> >>> Does anyone have any suggestions on how to handle this? >>> >>> Cheers, >>> >>> Stephen >>> >>> >>> On Wed, Aug 27, 2008 at 6:54 PM, Robby Findler wrote: >>>> There's not an explicit hook, but you can override the callback. >>>> >>>> Robby >>>> >>>> On Wed, Aug 27, 2008 at 12:46 PM, Grant Rettke wrote: >>>>>> I would love to find a way of having 'run' and/or 'Check syntax' ask me to >>>>>> save unsaved files in other tabs. I've looked a bit at this, but cannot see >>>>>> a simple way to do it. >>>>> >>>>> The code to iterate tabs and save files is in DrSync (not that it is >>>>> complex, but I asked Robby enough questions, and it works so you don't >>>>> have to reinvent the wheel). Maybe there is a hook before run or check >>>>> syntax are executed, which could call the file saving code. >>>>> _________________________________________________ >>>>> For list-related administrative tasks: >>>>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>>>> >>>>> >>>> _________________________________________________ >>>> For list-related administrative tasks: >>>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>>> >>> >>> >>> >>> -- >>> >>> >> > > > > -- > http://www.wisdomandwonder.com/ > -- Cheers, Stephen -- Stephen De Gabrielle s.degabrielle@cs.ucl.ac.uk Telephone +44 (0)20 7679 0693 (x30693) Mobile 079 851 890 45 Project: Making Sense of Information (MaSI) Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html Home:http://www.degabrielle.name/stephen UCL Interaction Centre MPEB 8th floor University College London Gower Street London WC1E 6BT From spdegabrielle at gmail.com Wed Aug 27 15:48:52 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:46 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <595b9ab20808271241p58d6f091x5bb3316660982c29@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> <56750b780808271029t60d26c83yd27a2c1743ec465a@mail.gmail.com> <56750b780808271030l5b4bafc6hb99785f1aa5ac921@mail.gmail.com> <756daca50808271046s4212c97epbbfe54144e326ce0@mail.gmail.com> <932b2f1f0808271054x4b0ba42crd2252b1228db7f65@mail.gmail.com> <595b9ab20808271203t79c86327h30557de556503d34@mail.gmail.com> <932b2f1f0808271207wb3b3603n2afe33e528873327@mail.gmail.com> <756daca50808271212u1e804d30gde5d60834bd9cdde@mail.gmail.com> <595b9ab20808271241p58d6f091x5bb3316660982c29@mail.gmail.com> Message-ID: <595b9ab20808271248n681c8634s67907aee3408b7cd@mail.gmail.com> I almost forgot; what file extenstion should I use? I was thinking 'Scheme Project ' *.sp or a 'scheme data' extension? *.sd if such a thing already exists for files that can be read by the scheme reader. Thanks again for all your fine assistance, Stephen P. De Gabrielle On Wed, Aug 27, 2008 at 8:41 PM, Stephen De Gabrielle wrote: > Thanks guys, > > BTW, does anyone happen to know offhand... > 1. what the name of the widget that is used to implement the file, > (define ...) menu-buttons at the top of the frame and the recent > language selector at the bottom. > 2. how to get the button icons to work. (mine just don't work for me - > save and load tabs should have icons) > my code; > (inherit register-toolbar-button) > > (define project-icon-bitmap (make-object bitmap% > project-icon-sm 'png/mask)) > > (define save-project-button > (new switchable-button% > (label "Save Tabs") > (parent (make-object vertical-pane% (get-button-panel))) > (callback save-tabs) > [bitmap project-icon-bitmap] > )) > (register-toolbar-button save-project-button) > > Cheers, > > Stephen > > > > On Wed, Aug 27, 2008 at 8:12 PM, Grant Rettke wrote: >> See here: >> >> http://docs.plt-scheme.org/tools/implementing-tools.html >> >> and here: >> >> http://docs.plt-scheme.org/tools/Extending_the_Existing_DrScheme_Classes.html >> >> On Wed, Aug 27, 2008 at 2:07 PM, Robby Findler wrote: >>> I think that you want to just have your tool depend on the presence of >>> Check Syntax. DrScheme, unfortunatly, doesn't have a way for tools to >>> declare those dependencies, but the dependencies can still exist. Both >>> the Run button and the Check Syntax button invoke methods of the >>> frame, which you can override. >>> >>> Robby >>> >>> On Wed, Aug 27, 2008 at 2:03 PM, Stephen De Gabrielle >>> wrote: >>>> Hi, >>>> >>>> Is there a 'good' way to let plugins call each other? >>>> I understand that eclipse uses OSGi, but I don't know anything about it. >>>> >>>> Does anyone have any suggestions on how to handle this? >>>> >>>> Cheers, >>>> >>>> Stephen >>>> >>>> >>>> On Wed, Aug 27, 2008 at 6:54 PM, Robby Findler wrote: >>>>> There's not an explicit hook, but you can override the callback. >>>>> >>>>> Robby >>>>> >>>>> On Wed, Aug 27, 2008 at 12:46 PM, Grant Rettke wrote: >>>>>>> I would love to find a way of having 'run' and/or 'Check syntax' ask me to >>>>>>> save unsaved files in other tabs. I've looked a bit at this, but cannot see >>>>>>> a simple way to do it. >>>>>> >>>>>> The code to iterate tabs and save files is in DrSync (not that it is >>>>>> complex, but I asked Robby enough questions, and it works so you don't >>>>>> have to reinvent the wheel). Maybe there is a hook before run or check >>>>>> syntax are executed, which could call the file saving code. >>>>>> _________________________________________________ >>>>>> For list-related administrative tasks: >>>>>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>>>>> >>>>>> >>>>> _________________________________________________ >>>>> For list-related administrative tasks: >>>>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>>>> >>>> >>>> >>>> >>>> -- >>>> >>>> >>> >> >> >> >> -- >> http://www.wisdomandwonder.com/ >> > > > > -- > Cheers, > > Stephen > > -- > Stephen De Gabrielle > s.degabrielle@cs.ucl.ac.uk > Telephone +44 (0)20 7679 0693 (x30693) > Mobile 079 851 890 45 > Project: Making Sense of Information (MaSI) > Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html > Home:http://www.degabrielle.name/stephen > > > UCL Interaction Centre > MPEB 8th floor > University College London > Gower Street > London WC1E 6BT > -- Cheers, Stephen -- Stephen De Gabrielle s.degabrielle@cs.ucl.ac.uk Telephone +44 (0)20 7679 0693 (x30693) Mobile 079 851 890 45 Project: Making Sense of Information (MaSI) Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html Home:http://www.degabrielle.name/stephen UCL Interaction Centre MPEB 8th floor University College London Gower Street London WC1E 6BT From noelwelsh at gmail.com Wed Aug 27 16:48:17 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:26:46 2009 Subject: [plt-scheme] DrScheme development plugins/tools In-Reply-To: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> References: <595b9ab20808270407u8fe58c0ld71b9f20092ece45@mail.gmail.com> Message-ID: On Wed, Aug 27, 2008 at 12:07 PM, Stephen De Gabrielle wrote: > make the current directory as a planet package; > - http://planet.plt-scheme.org/display.ss?package=projects-project.plt&owner=spdegabrielle Having an editor for info.ss files would be handy. Currently you have to search a lot of docs for all the different fields, or copy an existing file. N. From jos.koot at telefonica.net Wed Aug 27 16:51:47 2008 From: jos.koot at telefonica.net (Jos Koot) Date: Thu Mar 26 02:26:47 2009 Subject: [plt-scheme] HTDP: Testing programs References: <756daca50808262039x634d2540y43a7a876a1f16686@mail.gmail.com> <596869A6-DB65-46D5-AE41-EC6405CFDCE2@ccs.neu.edu> Message-ID: <001401c90886$b8fb8120$2101a8c0@uw2b2dff239c4d> ----- Original Message ----- From: "Matthias Felleisen" To: "Shriram Krishnamurthi" Cc: "PLT List" Sent: Wednesday, August 27, 2008 3:18 PM Subject: Re: [plt-scheme] HTDP: Testing programs > > Shriram's saying that the design recipe demands the creation of examples > *before* you create the function. The idea is that this scales up to > larger development efforts, too. > > In principle, a design looks like this: > > ;; f->c : Number -> Number > ;; convert a fahrenheit temperature to a celsius temperature Nitting a little bit I say that in most systems of dimensional units a temperature is not a number. It is a number times a unit of temperature relative to an offset temperature. f -> c : Real Number -> Real Number convert real number f to real number c such that f degrees Farhenheit = c degrees Celcius, where "=" is exact when f is exact and "=" is approximative when f is inexact. I say this because I am a little bit concerned about the many examples in books about mathematics and programming that do not consistently apply the theory of dimensions. Imho it is wrong to say that the surface of a square with side 10 is 100. This can only be correct in a system of units in which lengths have no dimensional unit, but I never have seen such a system (on the contrary, the *simplest* system of units I know of, has one dimensional unit, namely for length) This is important for progarammers too. We may *represent* a temperature by a number with respect to a chosen scale of units but while programming we should be aware of the fact that the representation is not the same as the represented quantity. Jos > > (check-expect (f->c 32) 0) > (check-expect (f->c 212) 100) > > (define (f->c f-temp) > (cond > [(= f-temp 32) 0] > [(= f-temp 212) 100] > [else f-temp])) > > ;; --- > > Over the years, HtDP and drscheme have gotten a bit out of hand. One day > we'll catch up. -- Matthias > > > > > > > > > > On Aug 27, 2008, at 7:19 AM, Shriram Krishnamurthi wrote: > >> The intent is that you write test cases *before* you >> write your functions. If you had done this, and your >> test cases covered your program, DrScheme would >> not complain at you. Bad boy! (-: >> >> Shriram >> >> On Tue, Aug 26, 2008 at 11:39 PM, Grant Rettke wrote: >>> Hi folks, >>> >>> In HTDP beginner language on problem 2.2.1, when I evaluate it, >>> DrScheme complains that "This program should be tested". >>> >>> is the intention that students start testing immediately, or we ill >>> add tests later on? >>> >>> I used check-expect for now. >>> >>> Best wishes, >>> >>> Grant >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From matthias at ccs.neu.edu Wed Aug 27 17:28:12 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:26:47 2009 Subject: [plt-scheme] HTDP: Testing programs In-Reply-To: <001401c90886$b8fb8120$2101a8c0@uw2b2dff239c4d> References: <756daca50808262039x634d2540y43a7a876a1f16686@mail.gmail.com> <596869A6-DB65-46D5-AE41-EC6405CFDCE2@ccs.neu.edu> <001401c90886$b8fb8120$2101a8c0@uw2b2dff239c4d> Message-ID: In principle, I agree with you. Sadly I suspect it's beyond beginners. -- Matthias On Aug 27, 2008, at 4:51 PM, Jos Koot wrote: > > ----- Original Message ----- From: "Matthias Felleisen" > > To: "Shriram Krishnamurthi" > Cc: "PLT List" > Sent: Wednesday, August 27, 2008 3:18 PM > Subject: Re: [plt-scheme] HTDP: Testing programs > > >> >> Shriram's saying that the design recipe demands the creation of >> examples *before* you create the function. The idea is that this >> scales up to larger development efforts, too. >> >> In principle, a design looks like this: >> >> ;; f->c : Number -> Number >> ;; convert a fahrenheit temperature to a celsius temperature > > Nitting a little bit I say that in most systems of dimensional > units a temperature is not a number. It is a number times a unit of > temperature relative to an offset temperature. > f -> c : Real Number -> Real Number > convert real number f to real number c such that f degrees > Farhenheit = c degrees Celcius, > where "=" is exact when f is exact and "=" is approximative when f > is inexact. > > I say this because I am a little bit concerned about the many > examples in books about mathematics and programming that do not > consistently apply the theory of dimensions. > Imho it is wrong to say that the surface of a square with side 10 > is 100. This can only be correct in a system of units in which > lengths have no dimensional unit, but I never have seen such a > system (on the contrary, the *simplest* system of units I know of, > has one dimensional unit, namely for length) > > This is important for progarammers too. We may *represent* a > temperature by a number with respect to a chosen scale of units but > while programming we should be aware of the fact that the > representation is not the same as the represented quantity. > Jos > > >> >> (check-expect (f->c 32) 0) >> (check-expect (f->c 212) 100) >> >> (define (f->c f-temp) >> (cond >> [(= f-temp 32) 0] >> [(= f-temp 212) 100] >> [else f-temp])) >> >> ;; --- >> >> Over the years, HtDP and drscheme have gotten a bit out of hand. >> One day we'll catch up. -- Matthias >> >> >> >> >> >> >> >> >> >> On Aug 27, 2008, at 7:19 AM, Shriram Krishnamurthi wrote: >> >>> The intent is that you write test cases *before* you >>> write your functions. If you had done this, and your >>> test cases covered your program, DrScheme would >>> not complain at you. Bad boy! (-: >>> >>> Shriram >>> >>> On Tue, Aug 26, 2008 at 11:39 PM, Grant Rettke >>> wrote: >>>> Hi folks, >>>> >>>> In HTDP beginner language on problem 2.2.1, when I evaluate it, >>>> DrScheme complains that "This program should be tested". >>>> >>>> is the intention that students start testing immediately, or we ill >>>> add tests later on? >>>> >>>> I used check-expect for now. >>>> >>>> Best wishes, >>>> >>>> Grant >>>> _________________________________________________ >>>> For list-related administrative tasks: >>>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>>> >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme > From jos.koot at telefonica.net Wed Aug 27 18:03:26 2008 From: jos.koot at telefonica.net (Jos Koot) Date: Thu Mar 26 02:26:47 2009 Subject: [plt-scheme] HTDP: Testing programs References: <756daca50808262039x634d2540y43a7a876a1f16686@mail.gmail.com> <596869A6-DB65-46D5-AE41-EC6405CFDCE2@ccs.neu.edu> <001401c90886$b8fb8120$2101a8c0@uw2b2dff239c4d> Message-ID: <004401c90890$bb73a180$2101a8c0@uw2b2dff239c4d> ----- Original Message ----- From: "Matthias Felleisen" To: "Jos Koot" Cc: "Shriram Krishnamurthi" ; "PLT List" Sent: Wednesday, August 27, 2008 11:28 PM Subject: Re: [plt-scheme] HTDP: Testing programs > > In principle, I agree with you. Sadly I suspect it's beyond beginners. -- > Matthias That's probably true in the present situation. Things could be made different, though, when requiring some mathematical background before starting lessons in programming. (I assume that is the case, presently) Then, if the mathematical background would indeed include some discussions about units (which is by no means too complicated), I assume it would not be beyond beginners. However, such a perspective would require cooperation between a number of disciplines (Mathematics, Physics and Programming) I have some experience in teaching mathematics. My experience is that adding some discussion about units is not an extra burden upon the student. On the contrary, it may clarify a lot. (In fact the extra discussion should not be needed, for units are/should already be discussed at primary schools (I hope that's still the case, though sometimes I meet students that make me wonder)) Jos > > > > > > On Aug 27, 2008, at 4:51 PM, Jos Koot wrote: > >> >> ----- Original Message ----- From: "Matthias Felleisen" >> >> To: "Shriram Krishnamurthi" >> Cc: "PLT List" >> Sent: Wednesday, August 27, 2008 3:18 PM >> Subject: Re: [plt-scheme] HTDP: Testing programs >> >> >>> >>> Shriram's saying that the design recipe demands the creation of >>> examples *before* you create the function. The idea is that this >>> scales up to larger development efforts, too. >>> >>> In principle, a design looks like this: >>> >>> ;; f->c : Number -> Number >>> ;; convert a fahrenheit temperature to a celsius temperature >> >> Nitting a little bit I say that in most systems of dimensional units a >> temperature is not a number. It is a number times a unit of temperature >> relative to an offset temperature. >> f -> c : Real Number -> Real Number >> convert real number f to real number c such that f degrees Farhenheit = >> c degrees Celcius, >> where "=" is exact when f is exact and "=" is approximative when f is >> inexact. >> >> I say this because I am a little bit concerned about the many examples >> in books about mathematics and programming that do not consistently >> apply the theory of dimensions. >> Imho it is wrong to say that the surface of a square with side 10 is >> 100. This can only be correct in a system of units in which lengths have >> no dimensional unit, but I never have seen such a system (on the >> contrary, the *simplest* system of units I know of, has one dimensional >> unit, namely for length) >> >> This is important for progarammers too. We may *represent* a temperature >> by a number with respect to a chosen scale of units but while >> programming we should be aware of the fact that the representation is >> not the same as the represented quantity. >> Jos >> >> >>> >>> (check-expect (f->c 32) 0) >>> (check-expect (f->c 212) 100) >>> >>> (define (f->c f-temp) >>> (cond >>> [(= f-temp 32) 0] >>> [(= f-temp 212) 100] >>> [else f-temp])) >>> >>> ;; --- >>> >>> Over the years, HtDP and drscheme have gotten a bit out of hand. One >>> day we'll catch up. -- Matthias >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> On Aug 27, 2008, at 7:19 AM, Shriram Krishnamurthi wrote: >>> >>>> The intent is that you write test cases *before* you >>>> write your functions. If you had done this, and your >>>> test cases covered your program, DrScheme would >>>> not complain at you. Bad boy! (-: >>>> >>>> Shriram >>>> >>>> On Tue, Aug 26, 2008 at 11:39 PM, Grant Rettke >>>> wrote: >>>>> Hi folks, >>>>> >>>>> In HTDP beginner language on problem 2.2.1, when I evaluate it, >>>>> DrScheme complains that "This program should be tested". >>>>> >>>>> is the intention that students start testing immediately, or we ill >>>>> add tests later on? >>>>> >>>>> I used check-expect for now. >>>>> >>>>> Best wishes, >>>>> >>>>> Grant >>>>> _________________________________________________ >>>>> For list-related administrative tasks: >>>>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>>>> >>>> _________________________________________________ >>>> For list-related administrative tasks: >>>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >>> >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> > From alan at alan-watson.org Wed Aug 27 23:18:59 2008 From: alan at alan-watson.org (Alan Watson) Date: Thu Mar 26 02:26:47 2009 Subject: [plt-scheme] HTDP: Testing programs In-Reply-To: References: <756daca50808262039x634d2540y43a7a876a1f16686@mail.gmail.com> <596869A6-DB65-46D5-AE41-EC6405CFDCE2@ccs.neu.edu> <001401c90886$b8fb8120$2101a8c0@uw2b2dff239c4d> Message-ID: At times, it even seems beyond my postgraduate astrophysics students. Alan -- Alan Watson http://www.alan-watson.org/ From lunarc.lists at gmail.com Wed Aug 27 23:39:13 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:47 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: <932b2f1f0808240724r650b5db5s5818decd17133bf1@mail.gmail.com> References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> <20080824111127.D095E6500D9@mail-svr1.cs.utah.edu> <932b2f1f0808240724r650b5db5s5818decd17133bf1@mail.gmail.com> Message-ID: 2008/8/24 Robby Findler : > On Sun, Aug 24, 2008 at 6:11 AM, Matthew Flatt wrote: >> The client might be delayed indefinitely, either due to scheduling or >> being explicitly suspended by some third party. You don't want to block >> the server (and all other threads that might talk to the server) while >> one client is delayed. > > But don't take Matthew's word for it! I bet you can make a particular > group of readers/writers (affectionately known as a "unit test") and > demonstrate the difference between the two possibilities. Good idea, I hope I can find the time to try this out! Henk From lunarc.lists at gmail.com Wed Aug 27 23:45:17 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:47 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> Message-ID: 2008/8/21 Matthew Flatt : > Depending on the domain, though, there's one more problem beyond > granting read and write access in a kill-safe way. What if a thread is > terminated while it's in write mode? The "rwlock.ss" implementation > treats termination the same as the completion, but that's valid only if > each atomic step in writing keeps the relevant data consistent. > Otherwise, you need some way to ensure that the write completes so that > the data is consistent. > > If all you have is locks, then you're stuck on this second problem. If > you have a process, though, the solution is pretty easy: delegate the > writing work to the process that handles read and write access. (The > writing work has to be trusted in this case, in the sense that it won't > raise unexpected exceptions or things like that.) The enclosed > "rwlock-complete-write.ss" illustrates the generalization or > "rwlock.ss" to solve that problem. I have another question in response to this. What if the thread which is terminated was the last thread using this resourse? Then the server thread is suspended and may never finish the write in that case either, leaving the database in an inconsistent state. Henk From lunarc.lists at gmail.com Thu Aug 28 00:09:36 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:48 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> Message-ID: I've wrapped my head around the code you have supplied, basically by re-writing the code in a style I am more comfortable with, and customizing it a bit for use with sqlite (I've attached my version). My biggest change was splitting 'serve' into smaller functions to make its overall behaviour clearer. I have a couple of issues though. First, the server will still be killed if the last process using it is terminated. This means that the sqlite transaction may be held open indefinitely, and the next server instantiated will not be able to access the database. I can see one easy way to fix this, which would be to call 'start-server' from the thread I use to start the web server initially, effectively anchoring the server thread. Is there a better way? A separate issue is cleaning up sqlite resources allocated during reading/writing. I use prepared statements as a simple means to guard against SQL injection attacks, as they separate code from data in an SQL query. For example, to do a select query I actually have the following: (define (prepared-select query . params) (let ((statement (prepare db query))) (dynamic-wind void (lambda () (apply load-params statement params) (step* statement)) (lambda () (finalize statement))))) The kicker is that if the statement is not finalized, the sqlite transaction will fail to close, so if a thread is terminated at the wrong time I could lose access to my database. I could let the server handle this whole process as well, but that doesn't sound like the right solution to the problem. Is there a way to make this function atomic, without manually putting it in a separate .c file and using the ffi? Thanks a lot for the help so far, Henk -------------- next part -------------- A non-text attachment was scrubbed... Name: monitor.ss Type: application/octet-stream Size: 7709 bytes Desc: not available Url : http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080828/521c1d2e/monitor.obj From lunarc.lists at gmail.com Thu Aug 28 00:12:20 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:48 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: References: Message-ID: 2008/8/21 Noel Welsh : > We've had bad experiences with timeout based servlets. I would use > the LRU manager, and implement my own timeouts. This way you can send > a "timeout" events to your database process and tell it to release all > locks. > > Hopefully that help; I'm not sure I'm fully understood your problem. This is a distinction which affects only continuation-based servlets, correct? I am not using continuations for this purpose, the timeout is to prevent an accidental infinite loop or other delay in non-core servlet code from bringing down the entire server. Henk From mflatt at cs.utah.edu Thu Aug 28 05:23:01 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:48 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> Message-ID: <20080828092303.4FC51650091@mail-svr1.cs.utah.edu> At Thu, 28 Aug 2008 00:09:36 -0400, "Henk Boom" wrote: > First, the server will still be killed if the last process using it is > terminated. This means that the sqlite transaction may be held open > indefinitely, and the next server instantiated will not be able to > access the database. That's true. > I can see one easy way to fix this, which would > be to call 'start-server' from the thread I use to start the web > server initially, effectively anchoring the server thread. Is there a > better way? That sounds like the right solution to me. > A separate issue is cleaning up sqlite resources allocated during > reading/writing. I use prepared statements as a simple means to guard > against SQL injection attacks, as they separate code from data in an > SQL query. For example, to do a select query I actually have the > following: > > (define (prepared-select query . params) > (let ((statement (prepare db query))) > (dynamic-wind > void > (lambda () > (apply load-params statement params) > (step* statement)) > (lambda () (finalize statement))))) > > The kicker is that if the statement is not finalized, the sqlite > transaction will fail to close, so if a thread is terminated at the > wrong time I could lose access to my database. I could let the server > handle this whole process as well, but that doesn't sound like the > right solution to the problem. Why not? More generally, you could run it in any thread that has the same capability to run as the server thread --- perhaps another thread that is created when the web server is started. > Is there a way to make this function > atomic, without manually putting it in a separate .c file and using > the ffi? Using the FFI, you could call scheme_start_atomic() and scheme_end_atomic(), but I recommend the other approach. A comment on your version of the code: A writer posts to `fail-s' even after succeeding and posting to `done-s'. When both semaphores are posted, there's no guarantee that the server will see `done-s' before `fail-s', since it `sync's on both at the same time. That is, if both are available before the server actually picks (perhaps even before the server manages to call the `sync' function), then it might pick `fail-s' even though `done-s' is available. Also, you still need to use something like `reply' instead of `channel-put' to accept a reader/writer, but I think you know about that problem (and probably you're waiting to create a test that demonstrates the problem before fixing it). Matthew From jamiemmt at plt-scheme.org Thu Aug 28 11:15:01 2008 From: jamiemmt at plt-scheme.org (Jamie Morgenstern) Date: Thu Mar 26 02:26:49 2009 Subject: [plt-scheme] PLaneT bug tracking In-Reply-To: References: Message-ID: PLaneT now includes an installation of trac. Please use it for submitting any PLaneT-package bug reports. http://planet.plt-scheme.org/trac/the-submit-a-bug-url Note that if you already have an account on PLaneT, you now also have a trac account, but you will need to set your password. Do this by setting your PLaneT password (even to its current value) and the trac side password will also be changed. -Jamie Morgenstern From jamiemmt at plt-scheme.org Thu Aug 28 11:20:29 2008 From: jamiemmt at plt-scheme.org (Jamie Morgenstern) Date: Thu Mar 26 02:26:49 2009 Subject: [plt-scheme] PLaneT bug tracking Message-ID: PLaneT now includes an installation of trac. Please use it for submitting any PLaneT-package bug reports. http://planet.plt-scheme.org/trac/the-submit-a-bug-url Note that if you already have an account on PLaneT, you now also have a trac account, but you will need to set your password. Do this by setting your PLaneT password (even to its current value) and the trac side password will also be changed. From robby at cs.uchicago.edu Thu Aug 28 11:26:57 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:49 2009 Subject: [plt-scheme] PLaneT bug tracking In-Reply-To: References: Message-ID: <932b2f1f0808280826n349710fcpfc02a8115fecc038@mail.gmail.com> A note: the url below should be: http://planet.plt-scheme.org/trac/newticket (and trac is, of course, linked into the planet web pages in various ways). Robby On Thu, Aug 28, 2008 at 10:20 AM, Jamie Morgenstern wrote: > PLaneT now includes an installation of trac. Please use it for > submitting any PLaneT-package bug reports. > > http://planet.plt-scheme.org/trac/the-submit-a-bug-url > > Note that if you already have an account on PLaneT, you now also have > a trac account, but you will need to set your password. Do this by > setting your PLaneT password (even to its current value) and the trac > side password will also be changed. > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From jos.koot at telefonica.net Thu Aug 28 11:48:11 2008 From: jos.koot at telefonica.net (Jos Koot) Date: Thu Mar 26 02:26:50 2009 Subject: [plt-scheme] r6rs timer Message-ID: <001201c90925$7a072ba0$2101a8c0@uw2b2dff239c4d> For myself I usually use #lang scheme (because it is so compete) However, sometimes I am asked to provide R6RS conformant code. Then I use #!r6rs (with an anoying long list of imports) But I can't find something like PLT's "time" macro in any of the R6RS libraries. Does something alike live in R5RS? If so I would be much obliged if you would provide me a pointer. Thanks, Jos -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080828/cb9e9794/attachment.html From jos.koot at telefonica.net Thu Aug 28 11:54:48 2008 From: jos.koot at telefonica.net (Jos Koot) Date: Thu Mar 26 02:26:50 2009 Subject: Fw: [plt-scheme] r6rs timer Message-ID: <001001c90926$66d5baa0$2101a8c0@uw2b2dff239c4d> ----- Original Message ----- From: Jos Koot To: plt-scheme@list.cs.brown.edu Sent: Thursday, August 28, 2008 5:48 PM Subject: [plt-scheme] r6rs timer For myself I usually use #lang scheme (because it is so compete) However, sometimes I am asked to provide R6RS conformant code. Then I use #!r6rs (with an anoying long list of imports) But I can't find something like PLT's "time" macro in any of the R6RS libraries. Does something alike live in R5RS? If so I would be much obliged if you would provide me a pointer. R6RS (correction, sorry) Thanks, Jos -------------------------------------------------------------------------------- _________________________________________________ For list-related administrative tasks: http://list.cs.brown.edu/mailman/listinfo/plt-scheme -------------- next part -------------- An HTML attachment was scrubbed... URL: http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080828/e140ae40/attachment.htm From dherman at ccs.neu.edu Thu Aug 28 12:02:22 2008 From: dherman at ccs.neu.edu (Dave Herman) Date: Thu Mar 26 02:26:51 2009 Subject: [plt-scheme] PLaneT bug tracking In-Reply-To: References: Message-ID: <48B6CC0E.10501@ccs.neu.edu> > PLaneT now includes an installation of trac. Please use it for > submitting any PLaneT-package bug reports. > > http://planet.plt-scheme.org/trac/the-submit-a-bug-url I got this error: Error: Not Found No handler matched request to /the-submit-a-bug-url > Note that if you already have an account on PLaneT, you now also have > a trac account, but you will need to set your password. Do this by > setting your PLaneT password (even to its current value) and the trac > side password will also be changed. I reset my password on PLaneT and then tried logging in to /trac and it said invalid username or password. Dave From jamiemmt at plt-scheme.org Thu Aug 28 12:16:40 2008 From: jamiemmt at plt-scheme.org (Jamie Morgenstern) Date: Thu Mar 26 02:26:51 2009 Subject: [plt-scheme] PLaneT bug tracking In-Reply-To: <48B6CC0E.10501@ccs.neu.edu> References: <48B6CC0E.10501@ccs.neu.edu> Message-ID: The password resetting is now live; there was a small glitch before. From jamiemmt at plt-scheme.org Thu Aug 28 12:17:47 2008 From: jamiemmt at plt-scheme.org (Jamie Morgenstern) Date: Thu Mar 26 02:26:51 2009 Subject: [plt-scheme] PLaneT bug tracking In-Reply-To: References: <48B6CC0E.10501@ccs.neu.edu> Message-ID: Also, the url is http://planet.plt-scheme.org/trac/newticket From dherman at ccs.neu.edu Thu Aug 28 13:05:47 2008 From: dherman at ccs.neu.edu (Dave Herman) Date: Thu Mar 26 02:26:51 2009 Subject: [plt-scheme] PLaneT bug tracking In-Reply-To: References: <48B6CC0E.10501@ccs.neu.edu> Message-ID: <48B6DAEB.2040306@ccs.neu.edu> Great! Thank you for setting this up. I've received a number of bug reports over the last year or two and I've not been good about dealing with them. Hopefully this will help me keep on top of them better. Many thanks, Dave Jamie Morgenstern wrote: > Also, the url is > > http://planet.plt-scheme.org/trac/newticket From jos.koot at telefonica.net Thu Aug 28 14:00:41 2008 From: jos.koot at telefonica.net (Jos Koot) Date: Thu Mar 26 02:26:51 2009 Subject: [plt-scheme] r6rs timer References: <001201c90925$7a072ba0$2101a8c0@uw2b2dff239c4d> <48B6DA6F.5050404@web.de> Message-ID: <001101c90937$fc588240$2101a8c0@uw2b2dff239c4d> Thanks for replying. Much obliged indeed.But as the implementation of SRFI 19 depends on PLT Scheme, I may as well directly import macro "time" from scheme/base. I was looking for a timing tool that is available in all R6RS implementations. Apparently such a timer is not included in R6RS or any of its libraries. An omission? (I tend to think so :) Jos ----- Original Message ----- From: "Thomas Chust" To: "Jos Koot" Sent: Thursday, August 28, 2008 7:03 PM Subject: Re: [plt-scheme] r6rs timer > Jos Koot wrote: > >> [...] >> But I can't find something like PLT's "time" macro in any of the R6RS >> libraries. >> Does something alike live in R5RS? If so I would be much obliged if you >> would provide me a pointer. >> [...] > > Hello, > > it should be possible to code something roughly equivalent to PLT's time > macro using SRF-19's (current-time 'time-thread) and (current-time > 'time-utc). > > But I don't know of a convenient macro like time in any of the SRFIs or > R6RS standard libraries. > > cu, > Thomas From jamiemmt at plt-scheme.org Thu Aug 28 14:07:14 2008 From: jamiemmt at plt-scheme.org (Jamie Morgenstern) Date: Thu Mar 26 02:26:51 2009 Subject: [plt-scheme] Trac still up, Old PLaneT for now Message-ID: The old PLaneT site is up for now (so I can bugs) but the Trac server is still running at http://planet.plt-scheme.org/trac -Jamie From Ken.Dickey at whidbey.com Thu Aug 28 14:18:27 2008 From: Ken.Dickey at whidbey.com (Ken Dickey) Date: Thu Mar 26 02:26:54 2009 Subject: [plt-scheme] r6rs timer In-Reply-To: <001201c90925$7a072ba0$2101a8c0@uw2b2dff239c4d> References: <001201c90925$7a072ba0$2101a8c0@uw2b2dff239c4d> Message-ID: <200808281118.28083.Ken.Dickey@whidbey.com> On Thursday 28 August 2008 08:48:11 Jos Koot wrote: > For myself I usually use #lang scheme (because it is so compete) > However, sometimes I am asked to provide R6RS conformant code. > Then I use #!r6rs (with an anoying long list of imports) > But I can't find something like PLT's "time" macro in any of the R6RS > libraries. Does something alike live in R5RS? If so I would be much obliged > if you would provide me a pointer. Thanks, > Jos R6RS library compatibility is still a bit in flux, but the basic strategy for importing implementation specific features is to define a *-compat..ss file and have your program import library *-compat. You still need to set the the implementation specific search paths and possibly symbolic links. E.g. see attached process-compat.*.sls files which live in my "kend" directory. Use: (import (kend process-compat) ;; ... ) Close enough? Cheers, -KenD PS: Note SRFI 97: "SRFI Libraries" http://srfi.schemers.org/srfi-97/srfi-97.html -------------- next part -------------- A non-text attachment was scrubbed... Name: process-compat.mzscheme.sls Type: text/scheme source Size: 2084 bytes Desc: not available Url : http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080828/a2b7461d/process-compat.mzscheme.bin -------------- next part -------------- A non-text attachment was scrubbed... Name: process-compat.ikarus.sls Type: text/scheme source Size: 1790 bytes Desc: not available Url : http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080828/a2b7461d/process-compat.ikarus.bin -------------- next part -------------- A non-text attachment was scrubbed... Name: process-compat.larceny.sls Type: text/scheme source Size: 2295 bytes Desc: not available Url : http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080828/a2b7461d/process-compat.larceny.bin -------------- next part -------------- A non-text attachment was scrubbed... Name: process-compat.ypsilon.sls Type: text/scheme source Size: 1983 bytes Desc: not available Url : http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080828/a2b7461d/process-compat.ypsilon.bin From lunarc.lists at gmail.com Thu Aug 28 15:07:36 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:54 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: <20080828092303.4FC51650091@mail-svr1.cs.utah.edu> References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> <20080828092303.4FC51650091@mail-svr1.cs.utah.edu> Message-ID: On 2008-08-28, Matthew Flatt wrote: > At Thu, 28 Aug 2008 00:09:36 -0400, "Henk Boom" wrote: > > A separate issue is cleaning up sqlite resources allocated during > > reading/writing. I use prepared statements as a simple means to guard > > against SQL injection attacks, as they separate code from data in an > > SQL query. For example, to do a select query I actually have the > > following: > > > > (define (prepared-select query . params) > > (let ((statement (prepare db query))) > > (dynamic-wind > > void > > (lambda () > > (apply load-params statement params) > > (step* statement)) > > (lambda () (finalize statement))))) > > > > The kicker is that if the statement is not finalized, the sqlite > > transaction will fail to close, so if a thread is terminated at the > > wrong time I could lose access to my database. I could let the server > > handle this whole process as well, but that doesn't sound like the > > right solution to the problem. > > > Why not? Simply because this feels like an atomicity problem rather than a synchronization problem. Not really an important reason, but an intuitive one. > More generally, you could run it in any thread that has the same > capability to run as the server thread --- perhaps another thread that > is created when the web server is started. Except that if it's not atomic I have to make sure that the monitor doesn't attempt to close the transaction while the query is running, so I either need to use the same thread or introduce a new lock. I think using the same thread is the simpler solution. Important question: what is the overhead of blocking on inter-process communication? I'm guessing it's much less than the time it takes to make the database query, so it would be OK to use this every time, but I don't know. > A comment on your version of the code: A writer posts to `fail-s' even > after succeeding and posting to `done-s'. When both semaphores are > posted, there's no guarantee that the server will see `done-s' before > `fail-s', since it `sync's on both at the same time. That is, if both > are available before the server actually picks (perhaps even before the > server manages to call the `sync' function), then it might pick > `fail-s' even though `done-s' is available. Right, thanks. I was planning on checking the status of done-s when handling the fail-s event, but I forgot. Now that I think about it, that would be unintuitive behaviour for fail-s, so I've changed it to set! fail-s to #f after posting done-s so that I know not to post it as well. > Also, you still need to use something like `reply' instead of > `channel-put' to accept a reader/writer, but I think you know about > that problem (and probably you're waiting to create a test that > demonstrates the problem before fixing it). I'm curious about the behaviour of this, so I'd like to try it out. Wouldn't the same sort of delays happen when trying to send through a channel to the server? (Obviously the same workaround does not work in that case) Henk From grettke at acm.org Thu Aug 28 15:24:35 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:54 2009 Subject: [plt-scheme] HTDP Study group Message-ID: <756daca50808281224j3957f86cu7dbe2d13e16f9c09@mail.gmail.com> Hi folks, I set up a HTDP study group for myself, some co-workers, and some friends here, but anyone and everyone is invited: http://groups.google.com/group/study-htdp?hl=en We are doing self-study with common goals. Best wishes, Grant -- http://www.wisdomandwonder.com/ From dherman at ccs.neu.edu Thu Aug 28 15:34:33 2008 From: dherman at ccs.neu.edu (Dave Herman) Date: Thu Mar 26 02:26:54 2009 Subject: [plt-scheme] PLaneT bug tracking In-Reply-To: <48B6DAEB.2040306@ccs.neu.edu> References: <48B6CC0E.10501@ccs.neu.edu> <48B6DAEB.2040306@ccs.neu.edu> Message-ID: <48B6FDC9.4090505@ccs.neu.edu> I've started using the Trac database, and it's great. A few requests: 1) Can you make it so the default package associated with a bug is empty? Otherwise poor abromfile/drocaml.plt is gonna get a lot of unwanted attention. 2) I thought the sorting of the package list was screwy, but now I can't find anything wrong with it. I may be on crack, I can't be sure. ;) 3) Trac supports some plugins that do language-specific syntax highlighting in the Wiki markup. It would be nice if you could install one of the plugins that recognizes Scheme (and as the maintainer of dherman/java.plt and dherman/javascript.plt, I'd add that Java and JavaScript would be nice too). I know configuring Trac is obnoxious 'cause you end up having to hack into the Python, but it would be really nice. Thanks! Dave Dave Herman wrote: > Great! Thank you for setting this up. I've received a number of bug > reports over the last year or two and I've not been good about dealing > with them. Hopefully this will help me keep on top of them better. > > Many thanks, > Dave > > Jamie Morgenstern wrote: >> Also, the url is >> >> http://planet.plt-scheme.org/trac/newticket > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From robby at cs.uchicago.edu Thu Aug 28 16:05:00 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:54 2009 Subject: [plt-scheme] Trac still up, Old PLaneT for now In-Reply-To: References: Message-ID: <932b2f1f0808281305j7781d7b7i9a75388050e7ce5c@mail.gmail.com> The bug that trigger the reversion is now fixed and trac is back in planet. Robby On Thu, Aug 28, 2008 at 1:07 PM, Jamie Morgenstern wrote: > The old PLaneT site is up for now (so I can bugs) but the Trac server > is still running at http://planet.plt-scheme.org/trac > > -Jamie > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From robby at cs.uchicago.edu Thu Aug 28 16:56:29 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:55 2009 Subject: [plt-scheme] PLaneT bug tracking In-Reply-To: <48B6FDC9.4090505@ccs.neu.edu> References: <48B6CC0E.10501@ccs.neu.edu> <48B6DAEB.2040306@ccs.neu.edu> <48B6FDC9.4090505@ccs.neu.edu> Message-ID: <932b2f1f0808281356n55e3176ar45b2eebf179413fc@mail.gmail.com> On Thu, Aug 28, 2008 at 2:34 PM, Dave Herman wrote: > 1) Can you make it so the default package associated with a bug is empty? > Otherwise poor abromfile/drocaml.plt is gonna get a lot of unwanted > attention. I didn't see a very good way to do this, so I've added a dummy component that I'm responsible for, and made that the default. (I also fixed planet's interface to trac so that the right component is selected by default when you come from a planet package page.) There doesn't seem to be a good way to deal with version numbers, either, so I'll probably just get rid of that field or try to make it just an editable text field at some point. > 3) Trac supports some plugins that do language-specific syntax highlighting > in the Wiki markup. It would be nice if you could install one of the plugins > that recognizes Scheme (and as the maintainer of dherman/java.plt and > dherman/javascript.plt, I'd add that Java and JavaScript would be nice too). How are you looking at source code in trac? Thanks, Robby From jensaxel at soegaard.net Thu Aug 28 16:57:30 2008 From: jensaxel at soegaard.net (Jens Axel Soegaard) Date: Thu Mar 26 02:26:55 2009 Subject: [plt-scheme] Trac still up, Old PLaneT for now In-Reply-To: <932b2f1f0808281305j7781d7b7i9a75388050e7ce5c@mail.gmail.com> References: <932b2f1f0808281305j7781d7b7i9a75388050e7ce5c@mail.gmail.com> Message-ID: <48B7113A.8010002@soegaard.net> Robby Findler wrote: Am I supposed to receive the bug report in Trac by email? (I didn't get any for the two test tickets I created) /Jens Axel From robby at cs.uchicago.edu Thu Aug 28 16:59:14 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:55 2009 Subject: [plt-scheme] Trac still up, Old PLaneT for now In-Reply-To: <48B7113A.8010002@soegaard.net> References: <932b2f1f0808281305j7781d7b7i9a75388050e7ce5c@mail.gmail.com> <48B7113A.8010002@soegaard.net> Message-ID: <932b2f1f0808281359i245d2f26i2a273eb3fc5515d9@mail.gmail.com> No, apparently that has been disabled. I'm not sure why it was, tho, so I'll try to figure that out before I try to figure out how to reenable it. Sorry for the delay. Robby On Thu, Aug 28, 2008 at 3:57 PM, Jens Axel Soegaard wrote: > Robby Findler wrote: > > Am I supposed to receive the bug report in Trac by email? > > (I didn't get any for the two test tickets I created) > > /Jens Axel > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From dherman at ccs.neu.edu Thu Aug 28 17:04:54 2008 From: dherman at ccs.neu.edu (Dave Herman) Date: Thu Mar 26 02:26:55 2009 Subject: [plt-scheme] PLaneT bug tracking In-Reply-To: <932b2f1f0808281356n55e3176ar45b2eebf179413fc@mail.gmail.com> References: <48B6CC0E.10501@ccs.neu.edu> <48B6DAEB.2040306@ccs.neu.edu> <48B6FDC9.4090505@ccs.neu.edu> <932b2f1f0808281356n55e3176ar45b2eebf179413fc@mail.gmail.com> Message-ID: <48B712F6.8060307@ccs.neu.edu> > I didn't see a very good way to do this, so I've added a dummy > component that I'm responsible for, and made that the default. Thanks! > How are you looking at source code in trac? In the text of bug reports, I often write snippets of code. With Trac you can write preformatted text by writing: {{{ (define foo 42) }}} But with the right plugins, you can also write: {{{ #!scheme (define foo 42) }}} and it formats the text nicely. Thanks, Dave From spdegabrielle at gmail.com Thu Aug 28 19:26:47 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:56 2009 Subject: [plt-scheme] scribblings error Message-ID: <595b9ab20808281626u4096cea0q6f42f068e8d4a8e5@mail.gmail.com> Hi, I'm trying to use a simple scribble file, but planet is not letting me sp:PLT Scheme Full v4.0.2.6 spdegabrielle$ bin/planet create /Users/spdegabrielle/Documents/Development/scheme/subversion/projects-project/projectmgr/ Building: project.scrbl PLaneT packager: Error generating scribble documentation: procedure application: expected procedure, given: #f; arguments were: scribblings Refusing to continue packaging. sp:PLT Scheme Full v4.0.2.6 spdegabrielle$ The worst thing is it used to work, before I changed my code. Cheers, Stephen PS ProjectMgr updated 1.6 -------------- next part -------------- A non-text attachment was scrubbed... Name: info.ss Type: application/octet-stream Size: 791 bytes Desc: not available Url : http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080829/57c3a798/info.obj -------------- next part -------------- A non-text attachment was scrubbed... Name: project.scrbl Type: application/octet-stream Size: 4537 bytes Desc: not available Url : http://list.cs.brown.edu/pipermail/plt-scheme/attachments/20080829/57c3a798/project.obj From robby at cs.uchicago.edu Thu Aug 28 23:56:31 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:56 2009 Subject: [plt-scheme] scribblings error In-Reply-To: <595b9ab20808281626u4096cea0q6f42f068e8d4a8e5@mail.gmail.com> References: <595b9ab20808281626u4096cea0q6f42f068e8d4a8e5@mail.gmail.com> Message-ID: <932b2f1f0808282056meceeb24o27f44f1b70739129@mail.gmail.com> I've improved planet's error handling in SVN and here is the current error message, now with stack trace information (this error message is different, I guess because I'm running a newer version of PLT Scheme than you are Stephen?). I don't know what this error message, but the stack trace indicates to me that it is at least a missing check earlier? Does that seem right? [alishan] ~/Desktop% planet create projectmgr/ Building: project.scrbl PLaneT packager: Error generating scribble documentation: main-doc-relative->path: expected argument of type ; given (#) === context === /Users/robby/svn/plt/collects/scribble/html-render.ss:263:4: relative->path /Users/robby/svn/plt/collects/scribble/html-render.ss:371:6: toc-item->title+num /Users/robby/svn/plt/collects/scribble/html-render.ss:387:6: toc-item->block /Users/robby/svn/plt/collects/scribble/html-render.ss:434:6: toc-content /Users/robby/svn/plt/collects/scribble/html-render.ss:357:4: render-toc-view method in ...ibble/html-render.ss:226:2 /Users/robby/svn/plt/collects/scribble/html-render.ss:554:4: render-one-part method in ...ibble/html-render.ss:226:2 /Users/robby/svn/plt/collects/planet/util.ss:269:0: render /Users/robby/svn/plt/collects/planet/util.ss:308:2: make-planet-archive Refusing to continue packaging. Robby On Thu, Aug 28, 2008 at 6:26 PM, Stephen De Gabrielle wrote: > Hi, > > I'm trying to use a simple scribble file, but planet is not letting me > > sp:PLT Scheme Full v4.0.2.6 spdegabrielle$ bin/planet create > /Users/spdegabrielle/Documents/Development/scheme/subversion/projects-project/projectmgr/ > Building: project.scrbl > PLaneT packager: Error generating scribble documentation: procedure > application: expected procedure, given: #f; arguments were: > scribblings > Refusing to continue packaging. > sp:PLT Scheme Full v4.0.2.6 spdegabrielle$ > > The worst thing is it used to work, before I changed my code. > > Cheers, > > Stephen > > PS ProjectMgr updated 1.6 > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From lunarc.lists at gmail.com Fri Aug 29 01:55:56 2008 From: lunarc.lists at gmail.com (Henk Boom) Date: Thu Mar 26 02:26:57 2009 Subject: [plt-scheme] Cleanup on Servlet Timeout (Again) In-Reply-To: References: <20080821155854.E1B406500CF@mail-svr1.cs.utah.edu> <20080828092303.4FC51650091@mail-svr1.cs.utah.edu> Message-ID: 2008/8/28 Henk Boom : > Right, thanks. I was planning on checking the status of done-s when > handling the fail-s event, but I forgot. Now that I think about it, > that would be unintuitive behaviour for fail-s, so I've changed it to > set! fail-s to #f after posting done-s so that I know not to post it > as well. . . . which will of course fail when the thread finishes its job and then terminates, causing both the done-s and thread-dead-evt events to be available almost at once, and giving me a 50-50 chance of rolling back changes every time. . . Looks like the other way was better. This is tricky! Henk From jos.koot at telefonica.net Fri Aug 29 03:08:01 2008 From: jos.koot at telefonica.net (Jos Koot) Date: Thu Mar 26 02:26:57 2009 Subject: [plt-scheme] r6rs timer References: <001201c90925$7a072ba0$2101a8c0@uw2b2dff239c4d> <200808281118.28083.Ken.Dickey@whidbey.com> Message-ID: <001701c909a5$f9c1c7d0$2101a8c0@uw2b2dff239c4d> Many thanks. Very clear. When I said R6RS conformant, I ment source code that runs on all R6RS implementations, not restricted to PLT only. The two R6RS documents do mention "time" in their indices, nor anything alike. Hence when using "time" in a performance test suit, I must include a dummy time macro, which I replace by an import from scheme/base when running with PLT. When the user runs the code with another implementation that does provide a timer, she may replace the dummy macro by an import of that timer. When the user runs the code with an implementation that does not provide a timer, the dummy time macro evaluates its expression without producing timing info. Jos ----- Original Message ----- From: "Ken Dickey" To: "Jos Koot" Cc: Sent: Thursday, August 28, 2008 8:18 PM Subject: Re: [plt-scheme] r6rs timer > On Thursday 28 August 2008 08:48:11 Jos Koot wrote: >> For myself I usually use #lang scheme (because it is so compete) >> However, sometimes I am asked to provide R6RS conformant code. >> Then I use #!r6rs (with an anoying long list of imports) >> But I can't find something like PLT's "time" macro in any of the R6RS >> libraries. Does something alike live in R5RS? If so I would be much >> obliged >> if you would provide me a pointer. Thanks, >> Jos > > R6RS library compatibility is still a bit in flux, but the basic strategy > for > importing implementation specific features is to define a > *-compat..ss > file and have your program import library *-compat. > > You still need to set the the implementation specific search paths and > possibly symbolic links. > > E.g. see attached process-compat.*.sls files which live in my "kend" > directory. > > Use: > (import (kend process-compat) > ;; ... > ) > > > Close enough? > > Cheers, > -KenD > > PS: Note SRFI 97: "SRFI Libraries" > http://srfi.schemers.org/srfi-97/srfi-97.html > From spdegabrielle at gmail.com Fri Aug 29 06:01:26 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:57 2009 Subject: [plt-scheme] scribblings error In-Reply-To: <932b2f1f0808282056meceeb24o27f44f1b70739129@mail.gmail.com> References: <595b9ab20808281626u4096cea0q6f42f068e8d4a8e5@mail.gmail.com> <932b2f1f0808282056meceeb24o27f44f1b70739129@mail.gmail.com> Message-ID: <595b9ab20808290301q785c6f4etecce422e8b559867@mail.gmail.com> Thanks again guys for your help in this I *really* appreciate it. Let me know if you are coming to London so I can make it up to you. Back to the problem; I'm confused that it is working for Grant, because while I have made considerable changes, I didn't think anything in the code would affect the documentation. (I even renamed the scribble file to avoid what I thought was a possible name collision problem) I've zipped the source at http://projects-project.googlecode.com/files/projectmgr.zip On Fri, Aug 29, 2008 at 4:56 AM, Robby Findler wrote: > I've improved planet's error handling in SVN and here is the current > error message, now with stack trace information (this error message is > different, I guess because I'm running a newer version of PLT Scheme > than you are Stephen?). I've downloaded the latest overnight plt-full, reset all my config files back to the default and renamed the .scrbl file - the old error has been replaced your one; uclic36:~/Documents/Development/scheme/subversion/projects-project stephen$ planet create projectmgr Building: notes.scrbl PLaneT packager: Error generating scribble documentation: main-doc-relative->path: expected argument of type ; given (#) Refusing to continue packaging. uclic36:~/Documents/Development/scheme/subversion/projects-project stephen$ (I've switched machines to a 10.4 intel mac too) > I don't know what this error message, but the stack trace indicates to > me that it is at least a missing check earlier? Does that seem right? Sorry, I don't get your stake trace - I may be doing something wrong. Thanks again, Stephen > [alishan] ~/Desktop% planet create projectmgr/ > Building: project.scrbl > PLaneT packager: Error generating scribble documentation: > main-doc-relative->path: expected argument of type bytes, or a list beginning with doc>; given (#) > > === context === > /Users/robby/svn/plt/collects/scribble/html-render.ss:263:4: relative->path > /Users/robby/svn/plt/collects/scribble/html-render.ss:371:6: toc-item->title+num > /Users/robby/svn/plt/collects/scribble/html-render.ss:387:6: toc-item->block > /Users/robby/svn/plt/collects/scribble/html-render.ss:434:6: toc-content > /Users/robby/svn/plt/collects/scribble/html-render.ss:357:4: > render-toc-view method in ...ibble/html-render.ss:226:2 > /Users/robby/svn/plt/collects/scribble/html-render.ss:554:4: > render-one-part method in ...ibble/html-render.ss:226:2 > /Users/robby/svn/plt/collects/planet/util.ss:269:0: render > /Users/robby/svn/plt/collects/planet/util.ss:308:2: make-planet-archive > > > Refusing to continue packaging. > > > Robby > > On Thu, Aug 28, 2008 at 6:26 PM, Stephen De Gabrielle > wrote: >> Hi, >> >> I'm trying to use a simple scribble file, but planet is not letting me >> >> sp:PLT Scheme Full v4.0.2.6 spdegabrielle$ bin/planet create >> /Users/spdegabrielle/Documents/Development/scheme/subversion/projects-project/projectmgr/ >> Building: project.scrbl >> PLaneT packager: Error generating scribble documentation: procedure >> application: expected procedure, given: #f; arguments were: >> scribblings >> Refusing to continue packaging. >> sp:PLT Scheme Full v4.0.2.6 spdegabrielle$ >> >> The worst thing is it used to work, before I changed my code. >> >> Cheers, >> >> Stephen >> >> PS ProjectMgr updated 1.6 >> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> > -- Cheers, Stephen -- Stephen De Gabrielle s.degabrielle@cs.ucl.ac.uk Telephone +44 (0)20 7679 0693 (x30693) Mobile 079 851 890 45 Project: Making Sense of Information (MaSI) Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html Home:http://www.degabrielle.name/stephen UCL Interaction Centre MPEB 8th floor University College London Gower Street London WC1E 6BT From grettke at acm.org Fri Aug 29 08:44:49 2008 From: grettke at acm.org (Grant Rettke) Date: Thu Mar 26 02:26:57 2009 Subject: [plt-scheme] scribblings error In-Reply-To: <595b9ab20808290301q785c6f4etecce422e8b559867@mail.gmail.com> References: <595b9ab20808281626u4096cea0q6f42f068e8d4a8e5@mail.gmail.com> <932b2f1f0808282056meceeb24o27f44f1b70739129@mail.gmail.com> <595b9ab20808290301q785c6f4etecce422e8b559867@mail.gmail.com> Message-ID: <756daca50808290544w6f027edgf17b6604b512a844@mail.gmail.com> On Fri, Aug 29, 2008 at 5:01 AM, Stephen De Gabrielle wrote: > Back to the problem; > I'm confused that it is working for Grant, because while I have made > considerable changes, I didn't think anything in the code would affect > the documentation. (I even renamed the scribble file to avoid what I > thought was a possible name collision problem) > I've zipped the source at > http://projects-project.googlecode.com/files/projectmgr.zip To be totally sure about the code I was using, I just checked out the SVN trunk and did the following: 0. svn checkout http://projects-project.googlecode.com/svn/trunk/ projects-project-read-only 1. Uncommented the scribblings line in info.ss 2. Move notes.scrbl into the projectmgr directory 3. Ran planet create ./projectmgr 4. It created the PLT file and the documentation Here is the version of PLT I'm using: C:\projects-project-read-only>mzscheme --version Welcome to MzScheme v4.1 [3m], Copyright (c) 2004-2008 PLT Scheme Inc. From mflatt at cs.utah.edu Fri Aug 29 09:17:18 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:58 2009 Subject: [plt-scheme] scribblings error In-Reply-To: <595b9ab20808290301q785c6f4etecce422e8b559867@mail.gmail.com> References: <595b9ab20808281626u4096cea0q6f42f068e8d4a8e5@mail.gmail.com> <932b2f1f0808282056meceeb24o27f44f1b70739129@mail.gmail.com> <595b9ab20808290301q785c6f4etecce422e8b559867@mail.gmail.com> Message-ID: <20080829131720.23A276500B9@mail-svr1.cs.utah.edu> At Fri, 29 Aug 2008 11:01:26 +0100, "Stephen De Gabrielle" wrote: > stephen$ planet create projectmgr > Building: notes.scrbl > PLaneT packager: Error generating scribble documentation: > main-doc-relative->path: expected argument of type bytes, or a list beginning with doc>; given (#) > Refusing to continue packaging. This was a bug in the way that Scribble builds docs for a Planet package. It's now fixed in SVN. Matthew From Ken.Dickey at whidbey.com Fri Aug 29 11:35:38 2008 From: Ken.Dickey at whidbey.com (Ken Dickey) Date: Thu Mar 26 02:26:58 2009 Subject: [plt-scheme] r6rs timer In-Reply-To: <001701c909a5$f9c1c7d0$2101a8c0@uw2b2dff239c4d> References: <001201c90925$7a072ba0$2101a8c0@uw2b2dff239c4d> <200808281118.28083.Ken.Dickey@whidbey.com> <001701c909a5$f9c1c7d0$2101a8c0@uw2b2dff239c4d> Message-ID: <200808290835.38848.Ken.Dickey@whidbey.com> On Friday 29 August 2008 00:08:01 Jos Koot wrote: > When I said R6RS conformant, I ment source code that runs on all R6RS > implementations, not restricted to PLT only. > The two R6RS documents do mention "time" in their indices, nor anything > alike. > Hence when using "time" in a performance test suit, I must include a dummy > time macro, which I replace by an import from scheme/base when running with > PLT. Right. A time-compat..sls file supplies a time macro which may be a "dummy", depending on . The R6RS test suite code which runs on all implementations includes "the" time-compat.sls library, uses the time macro, and its code does not change. I think we are "agreeing loudly" here using different words. Right? -KenD From dougorleans at gmail.com Fri Aug 29 12:56:31 2008 From: dougorleans at gmail.com (Doug Orleans) Date: Thu Mar 26 02:26:58 2009 Subject: [plt-scheme] configure error: C compiler cannot create executables Message-ID: <2c17707e0808290956g4586ed9xc24c9f94e504306e@mail.gmail.com> Hi, I recently reinstalled Ubuntu 8.04 from DVD. I checked out the PLT trunk from Subversion, but when I run configure I get this error: dougo@quiet:/usr/local/plt/src$ ./configure checking for gcc... gcc checking for C compiler default output file name... configure: error: C compiler cannot create executables See `config.log' for more details. Here's the relevant section of config.log: gcc version 4.2.3 (Ubuntu 4.2.3-2ubuntu7) configure:2673: $? = 0 configure:2680: gcc -V >&5 gcc: '-V' option must have argument --dougorleans@gmail.com From jos.koot at telefonica.net Fri Aug 29 16:29:43 2008 From: jos.koot at telefonica.net (Jos Koot) Date: Thu Mar 26 02:26:58 2009 Subject: [plt-scheme] r6rs timer References: <001201c90925$7a072ba0$2101a8c0@uw2b2dff239c4d> <200808281118.28083.Ken.Dickey@whidbey.com> <001701c909a5$f9c1c7d0$2101a8c0@uw2b2dff239c4d> <200808290835.38848.Ken.Dickey@whidbey.com> Message-ID: <000e01c90a15$f8d920a0$2101a8c0@uw2b2dff239c4d> Absolutely Jos ----- Original Message ----- From: "Ken Dickey" To: "Jos Koot" Cc: Sent: Friday, August 29, 2008 5:35 PM Subject: Re: [plt-scheme] r6rs timer > On Friday 29 August 2008 00:08:01 Jos Koot wrote: >> When I said R6RS conformant, I ment source code that runs on all R6RS >> implementations, not restricted to PLT only. > >> The two R6RS documents do mention "time" in their indices, nor anything >> alike. > >> Hence when using "time" in a performance test suit, I must include a >> dummy >> time macro, which I replace by an import from scheme/base when running >> with >> PLT. > > Right. A time-compat..sls file supplies a time macro > which > may be a "dummy", depending on . The R6RS test suite code > which runs on all implementations includes "the" time-compat.sls library, > uses the time macro, and its code does not change. > > I think we are "agreeing loudly" here using different words. Right? > > -KenD From noelwelsh at gmail.com Fri Aug 29 16:37:11 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:26:58 2009 Subject: [plt-scheme] Specifying directory sandbox evalutes file requires relative to Message-ID: Hello, I have a problem creating an interaction-environment with a require statement that uses a file require. This is used for Scribble documentation, which lives in a sub-directory called scribblings. The require statement requires a file in the same directory using a line like: (file "db.ss") It works fine in testing, but when I come to build the package using "planet create" it seems that the require statement is resolved relative to the top level directory, so it breaks. I can fix it: (file "scribblings/db.ss") but now I get this really weird error message: WARNING: collected information for key multiple times: (exporting-libraries #f) "modcollapse.ss" broke the contract (-> (or/c symbol? module-path-index?) (or/c ...etc... path?)) on collapse-module-path-index; expected <(or/c (and/c module-path? (or/c symbol? (cons/c (symbols (quote lib)) any/c) (cons/c (symbols (quote file)) any/c) (cons/c (symbols (quote planet)) any/c) (cons/c (symbols (quote quote)) any/c))) path?)>, given: (planet "../generic/connection.ss" ("untyped" "snooze.plt" 2)) This require statement points outside the package! It does not appear anywhere in my code, so I assume it is created in generating the Scribble docs. Any ideas? Thanks, Noel From noelwelsh at gmail.com Fri Aug 29 16:38:22 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:26:58 2009 Subject: [plt-scheme] Persistence solutions for v4.1 In-Reply-To: References: Message-ID: Just FYI, release is delayed by planet weirdness... see my recent email to plt-scheme. N. On Tue, Aug 26, 2008 at 7:54 PM, Noel Welsh wrote: > I plan to update Snooze on Thursday. > > HTH, > N. From robby at cs.uchicago.edu Fri Aug 29 17:04:26 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:59 2009 Subject: [plt-scheme] Specifying directory sandbox evalutes file requires relative to In-Reply-To: References: Message-ID: <932b2f1f0808291404h72c3e489y61da3e7d2766795b@mail.gmail.com> It does seem like something fishy is going on there, but why aren't you writing: (require "db.ss") ? Robby On Fri, Aug 29, 2008 at 3:37 PM, Noel Welsh wrote: > Hello, > > I have a problem creating an interaction-environment with a require > statement that uses a file require. This is used for Scribble > documentation, which lives in a sub-directory called scribblings. The > require statement requires a file in the same directory using a line > like: > > (file "db.ss") > > It works fine in testing, but when I come to build the package using > "planet create" it seems that the require statement is resolved > relative to the top level directory, so it breaks. I can fix it: > > (file "scribblings/db.ss") > > but now I get this really weird error message: > > WARNING: collected information for key multiple times: (exporting-libraries #f) > "modcollapse.ss" broke the contract > (-> > (or/c symbol? module-path-index?) > (or/c > ...etc... > path?)) > on collapse-module-path-index; expected <(or/c (and/c module-path? > (or/c symbol? (cons/c (symbols (quote lib)) any/c) (cons/c (symbols > (quote file)) any/c) (cons/c (symbols (quote planet)) any/c) (cons/c > (symbols (quote quote)) any/c))) path?)>, given: (planet > "../generic/connection.ss" ("untyped" "snooze.plt" 2)) > > This require statement points outside the package! It does not appear > anywhere in my code, so I assume it is created in generating the > Scribble docs. > > Any ideas? > > Thanks, > Noel > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From mflatt at cs.utah.edu Fri Aug 29 17:13:12 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:59 2009 Subject: [plt-scheme] Specifying directory sandbox evalutes file requires relative to In-Reply-To: References: Message-ID: <20080829211313.9EE406500A9@mail-svr1.cs.utah.edu> At Fri, 29 Aug 2008 21:37:11 +0100, "Noel Welsh" wrote: > I have a problem creating an interaction-environment with a require > statement that uses a file require. This is used for Scribble > documentation, which lives in a sub-directory called scribblings. The > require statement requires a file in the same directory using a line > like: > > (file "db.ss") Don't use `file' for relative references like this. The `file' form is intended as a way to reach files that you can't access in the restricted, portable way that is supported by a plain string. In this case, you just want a string... > It works fine in testing, but when I come to build the package using > "planet create" it seems that the require statement is resolved > relative to the top level directory, so it breaks. I can fix it: > > (file "scribblings/db.ss") ... specifically, just "scribblings/db.ss". Setup PLT and Planet packaging set the current directory to the one containing the "info.ss" file when building docs, and I think Planet probably requires that "info.ss" file to be in the package's root. Since `interaction-eval' is dynamic, it depends on the current directory instead of the enclosing file. > but now I get this really weird error message: > > WARNING: collected information for key multiple times: (exporting-libraries #f) > "modcollapse.ss" broke the contract > (-> > (or/c symbol? module-path-index?) > (or/c > ...etc... > path?)) > on collapse-module-path-index; expected <(or/c (and/c module-path? > (or/c symbol? (cons/c (symbols (quote lib)) any/c) (cons/c (symbols > (quote file)) any/c) (cons/c (symbols (quote planet)) any/c) (cons/c > (symbols (quote quote)) any/c))) path?)>, given: (planet > "../generic/connection.ss" ("untyped" "snooze.plt" 2)) > > This require statement points outside the package! It does not appear > anywhere in my code, so I assume it is created in generating the > Scribble docs. This must be a bug in `setup/modcollapse'. Does your code have a "../generic/connection.ss" relative path somewhere? Or some other form of reference to "connection.ss"? Matthew From mflatt at cs.utah.edu Fri Aug 29 17:19:59 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:59 2009 Subject: [plt-scheme] Specifying directory sandbox evalutes file requires relative to In-Reply-To: <20080829211313.9EE406500A9@mail-svr1.cs.utah.edu> References: <20080829211313.9EE406500A9@mail-svr1.cs.utah.edu> Message-ID: <20080829212001.62D4B6500AE@mail-svr1.cs.utah.edu> At Fri, 29 Aug 2008 15:13:12 -0600, Matthew Flatt wrote: > > WARNING: collected information for key multiple times: (exporting-libraries > #f) > > "modcollapse.ss" broke the contract > > (-> > > (or/c symbol? module-path-index?) > > (or/c > > ...etc... > > path?)) > > on collapse-module-path-index; expected <(or/c (and/c module-path? > > (or/c symbol? (cons/c (symbols (quote lib)) any/c) (cons/c (symbols > > (quote file)) any/c) (cons/c (symbols (quote planet)) any/c) (cons/c > > (symbols (quote quote)) any/c))) path?)>, given: (planet > > "../generic/connection.ss" ("untyped" "snooze.plt" 2)) > > > > This require statement points outside the package! It does not appear > > anywhere in my code, so I assume it is created in generating the > > Scribble docs. > > This must be a bug in `setup/modcollapse'. Does your code have a > "../generic/connection.ss" relative path somewhere? Or some other form > of reference to "connection.ss"? Nevermind. I managed to find a combination of references that triggers this bug. Matthew From mflatt at cs.utah.edu Fri Aug 29 17:36:41 2008 From: mflatt at cs.utah.edu (Matthew Flatt) Date: Thu Mar 26 02:26:59 2009 Subject: [plt-scheme] Specifying directory sandbox evalutes file requires relative to In-Reply-To: References: Message-ID: <20080829213642.BBB186500AF@mail-svr1.cs.utah.edu> At Fri, 29 Aug 2008 21:37:11 +0100, "Noel Welsh" wrote: > WARNING: collected information for key multiple times: (exporting-libraries #f) > "modcollapse.ss" broke the contract > (-> > (or/c symbol? module-path-index?) > (or/c > ...etc... > path?)) > on collapse-module-path-index; expected <(or/c (and/c module-path? > (or/c symbol? (cons/c (symbols (quote lib)) any/c) (cons/c (symbols > (quote file)) any/c) (cons/c (symbols (quote planet)) any/c) (cons/c > (symbols (quote quote)) any/c))) path?)>, given: (planet > "../generic/connection.ss" ("untyped" "snooze.plt" 2)) A bug in `syntax/modcollapse' --- probably the one that you're running into --- is now fixed in SVN. Matthew From spdegabrielle at gmail.com Fri Aug 29 17:42:18 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:26:59 2009 Subject: [plt-scheme] big text in program contour view Message-ID: <595b9ab20808291442g4bc483bco131f0b252db50854@mail.gmail.com> Hi, Is there a utility to create the big text that is readable in the program contour pane of DrScheme? Cheers, Stephen From robby at cs.uchicago.edu Fri Aug 29 17:44:19 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:26:59 2009 Subject: [plt-scheme] big text in program contour view In-Reply-To: <595b9ab20808291442g4bc483bco131f0b252db50854@mail.gmail.com> References: <595b9ab20808291442g4bc483bco131f0b252db50854@mail.gmail.com> Message-ID: <932b2f1f0808291444r5760b330ldf9d596e0e44ed87@mail.gmail.com> In DrScheme's "Insert" menu, the "Insert Large Letters..." menu item. Robby On Fri, Aug 29, 2008 at 4:42 PM, Stephen De Gabrielle wrote: > Hi, > Is there a utility to create the big text that is readable in the > program contour pane of DrScheme? > > Cheers, > > Stephen > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From matthias at ccs.neu.edu Fri Aug 29 17:47:27 2008 From: matthias at ccs.neu.edu (Matthias Felleisen) Date: Thu Mar 26 02:27:00 2009 Subject: [plt-scheme] big text in program contour view In-Reply-To: <595b9ab20808291442g4bc483bco131f0b252db50854@mail.gmail.com> References: <595b9ab20808291442g4bc483bco131f0b252db50854@mail.gmail.com> Message-ID: <41AADB72-A9EE-4D03-9679-3E3577BD8D6B@ccs.neu.edu> It has just been converted to Typed Scheme. Look in the svn distribution -- Matthias On Aug 29, 2008, at 5:42 PM, Stephen De Gabrielle wrote: > Hi, > Is there a utility to create the big text that is readable in the > program contour pane of DrScheme? > > Cheers, > > Stephen > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme From robby at cs.uchicago.edu Fri Aug 29 17:50:25 2008 From: robby at cs.uchicago.edu (Robby Findler) Date: Thu Mar 26 02:27:00 2009 Subject: [plt-scheme] big text in program contour view In-Reply-To: <41AADB72-A9EE-4D03-9679-3E3577BD8D6B@ccs.neu.edu> References: <595b9ab20808291442g4bc483bco131f0b252db50854@mail.gmail.com> <41AADB72-A9EE-4D03-9679-3E3577BD8D6B@ccs.neu.edu> Message-ID: <932b2f1f0808291450q1531ed22k3bb0a8afbea319c2@mail.gmail.com> Both the typed and untyped copies are actually checked in at the moment: http://svn.plt-scheme.org/plt/trunk/collects/drscheme/private/insert-large-letters-typed.ss http://svn.plt-scheme.org/plt/trunk/collects/drscheme/private/insert-large-letters.ss (I've asked Sam why keep the untyped one, but he hasn't gotten back to me yet.) Robby On Fri, Aug 29, 2008 at 4:47 PM, Matthias Felleisen wrote: > > It has just been converted to Typed Scheme. Look in the svn distribution -- > Matthias > > > > > > > On Aug 29, 2008, at 5:42 PM, Stephen De Gabrielle wrote: > >> Hi, >> Is there a utility to create the big text that is readable in the >> program contour pane of DrScheme? >> >> Cheers, >> >> Stephen >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > From dvanhorn at ccs.neu.edu Fri Aug 29 18:06:14 2008 From: dvanhorn at ccs.neu.edu (David Van Horn) Date: Thu Mar 26 02:27:00 2009 Subject: [plt-scheme] testing and the Module language Message-ID: <48B872D6.3020005@ccs.neu.edu> How do I generate test case reports for programs that use htdp/testing in the Module language? #lang scheme (require htdp/testing) (check-expect true false) Welcome to DrScheme, version 4.1.0.2-svn19aug2008 [3m]. Language: Module; memory limit: 128 megabytes. > (generate-report) This program should be tested. > David From spdegabrielle at gmail.com Fri Aug 29 19:00:54 2008 From: spdegabrielle at gmail.com (Stephen De Gabrielle) Date: Thu Mar 26 02:27:00 2009 Subject: [plt-scheme] big text in program contour view In-Reply-To: <932b2f1f0808291450q1531ed22k3bb0a8afbea319c2@mail.gmail.com> References: <595b9ab20808291442g4bc483bco131f0b252db50854@mail.gmail.com> <41AADB72-A9EE-4D03-9679-3E3577BD8D6B@ccs.neu.edu> <932b2f1f0808291450q1531ed22k3bb0a8afbea319c2@mail.gmail.com> Message-ID: <595b9ab20808291600p2c40b827v6e09d50c29411f46@mail.gmail.com> Thanks to all of you Cheers, s. On Fri, Aug 29, 2008 at 10:50 PM, Robby Findler wrote: > Both the typed and untyped copies are actually checked in at the moment: > > http://svn.plt-scheme.org/plt/trunk/collects/drscheme/private/insert-large-letters-typed.ss > http://svn.plt-scheme.org/plt/trunk/collects/drscheme/private/insert-large-letters.ss > > (I've asked Sam why keep the untyped one, but he hasn't gotten back to me yet.) > > Robby > > On Fri, Aug 29, 2008 at 4:47 PM, Matthias Felleisen > wrote: >> >> It has just been converted to Typed Scheme. Look in the svn distribution -- >> Matthias >> >> >> >> >> >> >> On Aug 29, 2008, at 5:42 PM, Stephen De Gabrielle wrote: >> >>> Hi, >>> Is there a utility to create the big text that is readable in the >>> program contour pane of DrScheme? >>> >>> Cheers, >>> >>> Stephen >>> _________________________________________________ >>> For list-related administrative tasks: >>> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> _________________________________________________ >> For list-related administrative tasks: >> http://list.cs.brown.edu/mailman/listinfo/plt-scheme >> >> > -- Cheers, Stephen -- Stephen De Gabrielle s.degabrielle@cs.ucl.ac.uk Telephone +44 (0)20 7679 0693 (x30693) Mobile 079 851 890 45 Project: Making Sense of Information (MaSI) Work:http://www.uclic.ucl.ac.uk/annb/MaSI.html Home:http://www.degabrielle.name/stephen UCL Interaction Centre MPEB 8th floor University College London Gower Street London WC1E 6BT From workmin at ccs.neu.edu Fri Aug 29 23:23:07 2008 From: workmin at ccs.neu.edu (Jon Rafkind) Date: Thu Mar 26 02:27:00 2009 Subject: [plt-scheme] configure error: C compiler cannot create executables In-Reply-To: <2c17707e0808290956g4586ed9xc24c9f94e504306e@mail.gmail.com> References: <2c17707e0808290956g4586ed9xc24c9f94e504306e@mail.gmail.com> Message-ID: <48B8BD1B.306@ccs.neu.edu> Doug Orleans wrote: > Hi, I recently reinstalled Ubuntu 8.04 from DVD. I checked out the > PLT trunk from Subversion, but when I run configure I get this error: > > dougo@quiet:/usr/local/plt/src$ ./configure > checking for gcc... gcc > checking for C compiler default output file name... > configure: error: C compiler cannot create executables > See `config.log' for more details. > > Here's the relevant section of config.log: > > gcc version 4.2.3 (Ubuntu 4.2.3-2ubuntu7) > configure:2673: $? = 0 > configure:2680: gcc -V >&5 > gcc: '-V' option must have argument > > --dougorleans@gmail.com > _________________________________________________ > For list-related administrative tasks: > http://list.cs.brown.edu/mailman/listinfo/plt-scheme > > I have ubuntu 8.04 with the same exact version of gcc. In config.log I see the same messages about -V needing an option, but it continues on without complaining that gcc cannot create an executable. Is there more to config.log after that -V line? Also, fwiw, you should create a new subdirectory and do configure && make from there. src $ md b; cd b src/b $ ../configure && make From noelwelsh at gmail.com Sat Aug 30 02:25:09 2008 From: noelwelsh at gmail.com (Noel Welsh) Date: Thu Mar 26 02:27:00 2009 Subject: [plt-scheme] Specifying directory sandbox evalutes file requires relative to In-Reply-To: <20080829213642.BBB186500AF@mail-svr1.cs.utah.edu> References: <20080829213642.BBB