aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLudovic Courtès2010-07-16 16:10:45 +0200
committerLudovic Courtès2010-07-16 16:10:45 +0200
commit255c13f78a11c79b860ca6681e187879ac5583bf (patch)
tree3427dfadf4da161fe27615652d8f82cffee57978
parente01d73bba2d5816475d716094f9c03d2767f2c62 (diff)
downloadskribilo-255c13f78a11c79b860ca6681e187879ac5583bf.tar.gz
skribilo-255c13f78a11c79b860ca6681e187879ac5583bf.tar.lz
skribilo-255c13f78a11c79b860ca6681e187879ac5583bf.zip
Pretty-print engines.
* src/guile/skribilo/engine.scm (write): New method.
-rw-r--r--src/guile/skribilo/engine.scm9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/guile/skribilo/engine.scm b/src/guile/skribilo/engine.scm
index 89fb728..691b801 100644
--- a/src/guile/skribilo/engine.scm
+++ b/src/guile/skribilo/engine.scm
@@ -1,7 +1,7 @@
;;; engine.scm -- Skribilo engines.
;;; -*- coding: iso-8859-1 -*-
;;;
-;;; Copyright 2005, 2007, 2008, 2009 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright 2005, 2007, 2008, 2009, 2010 Ludovic Courtès <ludo@gnu.org>
;;; Copyright 2003, 2004 Erick Gallesio - I3S-CNRS/ESSI <eg@essi.fr>
;;;
;;;
@@ -27,6 +27,7 @@
:use-module (oop goops)
:use-module (ice-9 optargs)
+ :use-module (ice-9 format)
:autoload (srfi srfi-34) (raise guard)
:use-module (srfi srfi-35)
@@ -145,6 +146,12 @@
(define (engine-symbol-table obj)
(slot-ref obj 'symbol-table))
+(define-method (write (e <engine>) (p <port>))
+ (format p "#<~a ~a ~x>"
+ (class-name (class-of e))
+ (engine-ident e)
+ (object-address e)))
+
;;;