Method Languages.PLIS.default_environment()


Method default_environment

Environment default_environment()

Description

Creates a new environment on which it runs init_functions, init_specials and the following boot code.

(begin
  (defmacro (cddr x)
    (list (quote cdr) (list (quote cdr) x)))
  (defmacro (cadr x)
    (list (quote car) (list (quote cdr) x)))
  (defmacro (cdar x)
    (list (quote cdr) (list (quote car) x)))
  (defmacro (caar x)
    (list (quote car) (list (quote car) x)))

  (defmacro (when cond . body)
    (list (quote if) cond
	  (cons (quote begin) body)))

  (define (map fun list)
    (if (null? list) (quote ())
      (cons (fun (car list))
	         (map fun (cdr list)))))

  (defmacro (let decl . body)
    (cons (cons (quote lambda)
		(cons (map car decl) body))
	  (map cadr decl))))