aboutsummaryrefslogtreecommitdiff
path: root/src/guile/skribilo/prog.scm
diff options
context:
space:
mode:
authorLudovic Court`es2006-10-12 16:08:13 +0000
committerLudovic Court`es2006-10-12 16:08:13 +0000
commite70968b7c7c309ce262794880ddb3a74beb48c64 (patch)
tree0d167e21c625e043b4e0dc869728189451935b1a /src/guile/skribilo/prog.scm
parentbdfed985ba33fe739a058da5395f9519ccb364cf (diff)
downloadskribilo-e70968b7c7c309ce262794880ddb3a74beb48c64.tar.gz
skribilo-e70968b7c7c309ce262794880ddb3a74beb48c64.tar.lz
skribilo-e70968b7c7c309ce262794880ddb3a74beb48c64.zip
prog: Fixed line number output (`&prog-line').
* src/guile/skribilo/engine/base.scm: Use `srfi-13'. (&prog-line): Use the `:number' markup option rather than the ident as the line number. * src/guile/skribilo/prog.scm: Use `%skribilo-module-reader'. (make-prog-body): Pass the line number as a `:number' markup option in the `&prog-line' markup. git-archimport-id: skribilo@sv.gnu.org--2006/skribilo--devo--1.2--patch-3
Diffstat (limited to 'src/guile/skribilo/prog.scm')
-rw-r--r--src/guile/skribilo/prog.scm10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/guile/skribilo/prog.scm b/src/guile/skribilo/prog.scm
index 266d607..2f531cd 100644
--- a/src/guile/skribilo/prog.scm
+++ b/src/guile/skribilo/prog.scm
@@ -24,8 +24,13 @@
:autoload (ice-9 receive) (receive)
:use-module (skribilo lib) ;; `new'
:autoload (skribilo ast) (node? node-body)
+ :use-module (skribilo utils syntax)
+
:export (make-prog-body resolve-line))
+(fluid-set! current-reader %skribilo-module-reader)
+
+
;;; ======================================================================
;;;
;;; COMPATIBILITY
@@ -211,8 +216,9 @@
(extract-mark (car lines) mark regexp)
(let* ((line-ident (symbol->string (gensym "&prog-line")))
(n (new markup
- (markup '&prog-line)
- (ident line-ident)
+ (markup '&prog-line)
+ (ident line-ident)
+ (options `((:number ,lnum)))
(body (if m (make-line-mark m line-ident l) l)))))
(loop (cdr lines)
(+ lnum 1)