[plt-scheme] evaluating buffer w/o re-initializing environment?

From: Geoffrey S. Knauth (geoff at knauth.org)
Date: Sun Mar 29 14:09:44 EDT 2009

On Mar 29, 2009, at 12:50, Grant Rettke quoted Matthias from June 2007:
> http://list.cs.brown.edu/pipermail/plt-scheme/2007-June/018806.html

and in there I saw:

"Escape-control-x is for very small programs and macho, heroic young  
programmers who have time to waste (including on IRC channels). Real  
programmers use transparent REPLs."

I'm fine with Matthias's explanation above and at [1].  Sometimes  
though, I wish I could hold on to, say, a database connection.

Regarding the above quotation, I've used Emacs for 25 years, but I'm  
unsure what ESC C-x means.  My current Emacs (v22/v23) doesn't  
understand it.  Matthias, I'm guessing you meant C-x C-e, eval-last- 
sexp.

To Fred:  In Emacs scheme-mode with mzscheme underneath, I use the  
behavior you asked about most unheroically, e.g.,

; hypothetical checking account
(- 1000.00 ; bank balance at Sun Mar 29 13:25:48 EDT 2009
     400.00 ; oil company #101
     100.00 ; phone company #102
     100.00 ; electric company #103
     125.00 ; cable company #104
     150.00 ; kids' school lunches #105
      50.00 ; charity contribution #106
      74.70 ; little/seasoned/reasoned schemers (amazon) #107
     )
;=> 0.30 ; I'm happy! [2]
; ok, truth be told FPU said it was 0.29999999999999716

Geoff

[1] http://blog.plt-scheme.org/2009/03/drscheme-repl-isnt-lisp.html

[2] "Annual income twenty pounds, annual expenditure nineteen six,  
result happiness. Annual income twenty pounds, annual expenditure  
twenty pound ought and six, result misery." (Charles Dickens, David  
Copperfield)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20090329/35d8382a/attachment.html>

Posted on the users mailing list.