aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLudovic Courtès2015-03-11 14:39:09 +0100
committerLudovic Courtès2015-03-11 17:08:05 +0100
commit96c2d6467dec0ad3280f367de234e2bce03b981f (patch)
tree19a7d851445e0b5ab20a081d1a80e599edf9c99a /src
parentad680abb966ddd40ebeda5e066bd5eb23946d369 (diff)
downloadskribilo-96c2d6467dec0ad3280f367de234e2bce03b981f.tar.gz
skribilo-96c2d6467dec0ad3280f367de234e2bce03b981f.tar.lz
skribilo-96c2d6467dec0ad3280f367de234e2bce03b981f.zip
condition: Always use a literal format string.
* src/guile/skribilo/condition.scm (%call-with-skribilo-error-catch) [message-condition? c]: Pass a format string to 'format'.
Diffstat (limited to 'src')
-rw-r--r--src/guile/skribilo/condition.scm2
-rw-r--r--src/guile/skribilo/package/base.scm12
2 files changed, 4 insertions, 10 deletions
diff --git a/src/guile/skribilo/condition.scm b/src/guile/skribilo/condition.scm
index 97c97b1..5c3f684 100644
--- a/src/guile/skribilo/condition.scm
+++ b/src/guile/skribilo/condition.scm
@@ -212,7 +212,7 @@
(abort exit-val))
((message-condition? c)
- (format (current-error-port) (condition-message c))
+ (format (current-error-port) "~a~%" (condition-message c))
(abort exit-val))
(else
diff --git a/src/guile/skribilo/package/base.scm b/src/guile/skribilo/package/base.scm
index 082f33a..4cc5f93 100644
--- a/src/guile/skribilo/package/base.scm
+++ b/src/guile/skribilo/package/base.scm
@@ -743,19 +743,13 @@
(cells-vals '(collapse separate)))
(cond
((and frame (not (memq frame frame-vals)))
- (skribe-error 'table
- (format #f "frame should be one of \"~a\"" frame-vals)
- frame))
+ (invalid-argument-error 'table frame 'frame))
((and rules (not (memq rules rules-vals)))
- (skribe-error 'table
- (format #f "rules should be one of \"~a\"" rules-vals)
- rules))
+ (invalid-argument-error 'table rules 'rules))
((not (or (memq cellstyle cells-vals)
(string? cellstyle)
(number? cellstyle)))
- (skribe-error 'table
- (format #f "cellstyle should be one of \"~a\", or a number, or a string" cells-vals)
- cellstyle))
+ (invalid-argument-error 'table cellstyle 'cellstyle))
(else
(new container
(markup 'table)