wisp
 
(Arne Babenhauserheide)
2015-03-19: merge

merge

diff --git a/.bugs/bugs b/.bugs/bugs
--- a/.bugs/bugs
+++ b/.bugs/bugs
@@ -12,7 +12,7 @@ wisp: handle general paren prefixes like
 throw an exception when reducing indentation to an unknown indentation level. | owner:Arne Babenhauserheide <bab@draketo.de>, open:False, id:424186bd85f186b7279c5c59e2bd42f847284719, time:1376003568.91
 wisp-in-wisp: only parses the first 272 lines, for some reason. | owner:, open:False, id:4cb6c556d7136609e2da9ab3fc045a39847f1ef3, time:1377014682.98
 adjust runtests.sh to use testrunner.w                       | owner:, open:False, id:4d4e76343fe09f0ec72a3e5eb0077bd16e12f9d5, time:1415127234.43
-wisp-scheme: REPL: sometimes the output of a command is only shown after typing the next non-empty line. | owner:, open:True, id:56d2f81e9c89accb0b0bc668ddc8feed3b60e9b2, time:1416584789.23
+wisp-scheme: REPL: sometimes the output of a command is only shown after typing the next non-empty line. | owner:, open:False, id:56d2f81e9c89accb0b0bc668ddc8feed3b60e9b2, time:1416584789.23
 implement wisp in wisp                                       | owner:Arne Babenhauserheide <bab@draketo.de>, open:False, id:6299306916706410702029289bf32edab1e7f17c, time:1367113341.49
 support other types of brackets, like square brackets.       | owner:Arne Babenhauserheide <bab@draketo.de>, open:False, id:6749f3abcb9455eac9271efd8265797bce114239, time:1389134151.98
 linebreaks in parens still break                             | owner:, open:False, id:6797987c7834a53358fb4ebbd8b9b36c2c4a8f01, time:1379004764.14
diff --git a/.hgsigs b/.hgsigs
--- a/.hgsigs
+++ b/.hgsigs
@@ -17,3 +17,4 @@ 32659321b29470b5198827eda494d9824cc161ee
 eaf23f42b01382e4ab255abcd34e031b043e1f56 0 iQEcBAABAgAGBQJUP+zuAAoJEFyD82SnDaCeXRkH/iZOiyKj8VcuNJdpSZKqIvzNRMz5JhIiF3G04zzHs8jDxrJiGVVHWPYNXR0p7pChMsq5JanjrnQn2IGcGt7blB1fmjzhq6bwbru+sD2moisP/zFM1HOSKx0j7xsNwB8wd08l0GV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R0YRwdmiqOh1AoH8dVdkCsCfplBc3VGrdDN4caZP00=
diff --git a/.hgtags b/.hgtags
--- a/.hgtags
+++ b/.hgtags
@@ -25,3 +25,4 @@ 42ab97d010efa7883240f5e5254ea46fd9423239
 b7441736af4dc8f1a7df860d1b064e080a45e1a5 v0.6.6
 0e702c268e6fdc9c52f034b6553c940b09c16400 v0.8.0
 8eaf023f5d3bc20ad4b795cde3a92e3b5c242dba v0.8.1
+327acbae68ef4efbf77734f0ee20359ed559ce0d v0.8.2
diff --git a/NEWS b/NEWS
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,18 @@
+wisp 0.8.2 (2015-03-18):
+- resolve REPL delayed output bug.
+- forbid dot at the end of a line and as only symbol in a line to reserve them for future use.
+- generalized the shell-call to guile: It gets the parentdir from $0.
+- note curly braces, neoteric expressions and dual-wisp-sweet syntax.
+- added tests: sxml, self-referencial function, curly-infix.
+- new example: beautiful factorial.
+- new example: ensemble estimation with ensemble square root filter. Uses python driven by an output-pipe as a plotting tool.
+- SRFI 119 in draft.
+
+wisp 0.8.1 (2014-11-19):
+- srfi: polish implementation notes.
+- add the requirements to the syntax-examples.
+- wisp-scheme.w works completely again.
+
 wisp 0.8.0 (2014-11-03):
 - the testsuite is defined in terms of the code-tree, not in terms of
   the readable file. Implemented in testrunner.w
diff --git a/configure.ac b/configure.ac
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
 dnl run `autoreconf -i` to generate a configure script. 
 dnl Then run ./configure to generate a Makefile.
 dnl Finally run make to generate the project.
-AC_INIT([wisp], [0.8.1],
+AC_INIT([wisp], [0.8.2],
         [arne_bab@web.de])
 # Check for programs I need for my build
 AC_CANONICAL_TARGET
diff --git a/docs/srfi-from-template.html b/docs/srfi-from-template.html
--- a/docs/srfi-from-template.html
+++ b/docs/srfi-from-template.html
@@ -63,15 +63,15 @@ Wisp expressions can include any s-expre
 
 <table><tr><th>wisp</th><th>s-exp</th></tr><tr><td>
 <pre><b>define</b> : <i>hello</i> who   
-  <i>format</i> #t "~A ~A!\n"    
-          . "Hello" who   
-<i>hello</i>       "Wisp"        
+         <i>format</i> #t "Hello ~A!\n"  
+                        . who   
+<i>hello</i> "Wisp"        
 </pre>
 </td><td>
 <pre>(<b>define</b> (<i>hello</i> who)
-  (<i>format</i> #t "~A ~A!\n"
-             "Hello" who))
-(<i>hello</i>       "S-exp")
+        (<i>format</i> #t "Hello ~A!\n"
+                          who))
+(<i>hello</i> "S-exp")
 </pre>
 </td></tr></table>
 
@@ -503,8 +503,12 @@ Effectively code in parentheses and stri
 
 <li>The suggested suffix for files using wisp-syntax is <code>.w</code>.
 
-<li>To represent tail notation like <code>(define (foo . args))</code>, either avoid a linebreak before the dot as in <code>define : foo . args</code> or use a double dot to start the line: <code>. . args</code>. The first dot mark the line as continuation, the second is enters the code.</li>
-  
+<li>To represent tail notation like <code>(define (foo . args))</code>, either avoid a linebreak before the dot as in <code>define : foo . args</code> or use a double dot to start the line: <code>. . args</code>. The first dot mark the line as continuation, the second enters the scheme code.</li>
+
+<li>A dot as symbol at the end of a line is reserved for potential future use. It should be a syntax error if the next non-empty line starts with non-zero indentation. A lone dot at the end of a line calls for hard to catch errors.</li>
+
+<li>A dot as only symbol in a line has no useful meaning: the line is by definition empty. As such, a dot as only symbol on a line is also reserved for future use and should be treated as a syntax error to avoid locking out future possibilities.</li>
+
 </ul>
 
 
@@ -746,7 +750,7 @@ DEALINGS IN THE SOFTWARE.
     <address>Editor: <a href="mailto:srfi-editors at srfi dot schemers dot org">Michael Sperber</a></address>
 <!-- Created: Tue Sep 29 19:20:08 EDT 1998 -->
 <!-- hhmts start -->
-Last modified: Tue Feb  3 16:49:26 MET 2015
+Last modified: Tue Mar 11 21:25:26 MET 2015
 <!-- hhmts end -->
   </body>
 </html>
diff --git a/examples/factorial.w b/examples/factorial.w
new file mode 100755
--- /dev/null
+++ b/examples/factorial.w
@@ -0,0 +1,16 @@
+#!/usr/bin/env sh
+exec guile -L $(dirname $(dirname $(realpath "$0"))) --language=wisp -e '(@@ (examples factorial) main)' -s "$0" "$@"
+; !#
+
+define-module : examples factorial
+              . #:export : factorial
+
+define : factorial n            ;   (define (factorial n)
+    if : zero? n                ;       (if (zero? n)
+       . n                      ; =>        n
+       * n : factorial {n - 1}  ;           (* n (factorial {n - 1}))))
+
+define : main args
+         display : factorial 5
+         newline
+
diff --git a/wisp-reader.w b/wisp-reader.w
--- a/wisp-reader.w
+++ b/wisp-reader.w
@@ -65,9 +65,12 @@ define : read-one-wisp-sexp port env
   define : try-pending
     if : null? wisp-pending-sexps
          wisp-scheme-read-chunk-env
-         let : : sexp : car wisp-pending-sexps
-            set! wisp-pending-sexps : cdr wisp-pending-sexps
-            . sexp
+         let
+            : sexp : car wisp-pending-sexps
+              pending wisp-pending-sexps
+            set! wisp-pending-sexps : list ; : cdr wisp-pending-sexps
+            ; write : cons 'begin pending
+            cons 'begin pending
   try-pending
 
 define-language wisp