(format:out-substr): Update the column counter correctly. This fixes
authorMarius Vollmer <mvo@zagadka.de>
Wed, 19 Mar 2003 18:29:04 +0000 (18:29 +0000)
committerMarius Vollmer <mvo@zagadka.de>
Wed, 19 Mar 2003 18:29:04 +0000 (18:29 +0000)
the behavior of ~T (tabbing) after ~F, for instance.  Thanks to
Matthias Koeppe!

ice-9/format.scm

index efb7c16..486dc72 100644 (file)
@@ -89,7 +89,7 @@
   (do ((k i (+ k 1)))
       ((= k n))
     (write-char (string-ref str k) format:port))
-  (set! format:output-col (+ format:output-col n)))
+  (set! format:output-col (+ format:output-col (- n i))))
 
 ;(define (format:out-fill n ch)       ; this allocates a new string
 ;  (format:out-str (make-string n ch)))