wisp
 
(Arne Babenhauserheide)
2013-09-12: can survive one linebreak inside parens, but not a second in a new

can survive one linebreak inside parens, but not a second in a new set of parens. I do not know why.

diff --git a/wisp-guile.w b/wisp-guile.w
--- a/wisp-guile.w
+++ b/wisp-guile.w
@@ -72,7 +72,8 @@ Ends with three consecutive linebreaks o
                     set! incharform 0
                     
             when : >= incharform 2
-                if : or (char=? nextchar #\space) (char=? nextchar #\linefeed ) (char=? nextchar #\newline ) 
+                if : or (char=? nextchar #\space) (char=? 
+                                nextchar #\linefeed ) (char=? nextchar #\newline ) 
                    begin
                        ; format #t "2: set incharform 0: lastchar ~a nextchar ~a instring ~a incomment ~a incharform ~a" lastchar nextchar instring incomment incharform
                        ; newline
@@ -139,12 +140,11 @@ Ends with three consecutive linebreaks o
                 set! incharform 2
             
             ; check for brackets 
-            ; format #t "~a~a: ~a\n" instring inbrackets nextchar
-            ; this breaks on this: (char=? lastchar #\# )
+            ; FIXME: This only fixes a single linebreak inside parens, but if a second occurs on the same line it breaks. I do not know why.
             when : not : or instring incomment
                 when
                     and 
-                        not : string-suffix? text : string-append "#"
+                        not : string-suffix? text "#"
                         not : char=? #\\ lastchar
                         not : endsinunevenbackslashes : string-drop-right text : min 1 : string-length text
                     when : equal? "(" : string nextchar