File: low-exception.scm

package info (click to toggle)
scheme48 1.9.2-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 18,232 kB
  • sloc: lisp: 88,907; ansic: 87,519; sh: 3,224; makefile: 771
file content (49 lines) | stat: -rw-r--r-- 1,856 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
; Part of Scheme 48 1.9.  See file COPYING for notices and license.

; Authors: Mike Sperber

; This is to avoid a circular dependency: Doing this right requires
; the EXCEPTION structure, which comes (much) later.

(define (error-proc . args)
  (debug-message "error called before it's ready"))
(define (assertion-violation-proc . args)
  (debug-message "assertion-violation called before it's ready"))
(define (implementation-restriction-violation-proc . args)
  (debug-message "implementation-restriction-violation called before it's ready"))
(define (warning-proc . args)
  (debug-message "warning called before it's ready"))
(define (syntax-violation-proc . args)
  (debug-message "syntax-violation called before it's ready"))
(define (note-proc . args)
  (debug-message "note called before it's ready"))

(define (error who message . irritants)
  (apply error-proc who message irritants))

(define (assertion-violation who message . irritants)
  (apply assertion-violation-proc who message irritants))

(define (implementation-restriction-violation who message . irritants)
  (apply implementation-restriction-violation who message irritants))

(define (warning who message . irritants)
  (apply warning-proc who message irritants))

(define (note who message . irritants)
  (apply note-proc who message irritants))

(define (syntax-violation who message form . subforms)
  (apply syntax-violation-proc who message form subforms))

(define (initialize-low-exception-procedures!
	 error assertion-violation implementation-restriction-violation
	 warning note
	 syntax-violation)
  (set! error-proc error)
  (set! assertion-violation-proc assertion-violation)
  (set! implementation-restriction-violation-proc implementation-restriction-violation)
  (set! warning-proc warning)
  (set! note-proc note)
  (set! syntax-violation-proc syntax-violation))