source: project/release/3/locale/trunk/locale-errors.scm @ 13860

Last change on this file since 13860 was 13860, checked in by Kon Lovett, 12 years ago

Save. Mvd params into locale.scm

File size: 756 bytes
Line 
1;;;; locale-errors.scm
2;;;; Kon Lovett, Mar '09
3
4(declare
5  (usual-integrations)
6  (fixnum)
7  (inline)
8  (no-procedure-checks)
9  (no-bound-checks)
10  (export
11    make-type-error-message
12    type-error) )
13
14;;;
15
16
17;;
18
19(define (make-exn-condition loc msg . args)
20  (make-property-condition 'exn 'message msg 'location loc 'arguments args) )
21
22(define (make-type-error-message typmsg)
23  (string-append "bad argument type - expected " typmsg) )
24
25(define (type-condition) (make-property-condition 'type))
26
27(define (make-type-error-condition loc typmsg bad)
28  (make-composite-condition
29   (make-exn-condition loc (make-type-error-message typmsg) bad)
30   (type-condition)) )
31
32(define (type-error loc typmsg bad)
33  (abort (make-type-error-condition loc typmsg bad)) )
Note: See TracBrowser for help on using the repository browser.