(herald (home "Tinit")) ; -*- T -*- ;;;;;; T initialization file ;;; This file is loaded into USER-ENV. ;;; Setting this to QUERY should allow querying for _three_ choices: ;;; recompiling, loading the older binary, or loading the newer source. ;;; As it is, though, it just asks whether to recompile. ;;; ;;; Actually, it would be best to allow it to be a procedure that maps ;;; a source filename & a binary filename to the filename to load. (set (load-out-of-date-action) 'newer) ;;; Miscellaneous utilities (define tsys-env t-implementation-env) (import tsys-env *bound?) (define (*copy-syntax from from-id to . to-id) (*define-syntax to (if (null? to-id) from-id (car to-id)) (syntax-table-entry (env-syntax-table from) from-id))) ;;; S-expression comments (orbit '(set-dispatch-syntax read-dispatch #\; (lambda (port char number readtable) (ignore char number readtable) (read port) nothing-read)) tsys-env) ;;; Two convenient macros: a better structure type definition macro ;;; and a convenient mechanism for assmebling bit strings. (load '(home scheme/t/t4/defstruct) standard-env) (load '(home scheme/t/library/bit-field) standard-env) ;;; Orbit evaluator and noise utilities (load '(home scheme/t/library/orbit-util) orbit-env) ;; Don't PP-CPS the simplified tree of every input evaluated. (set (*value orbit-env '*noise-flag*) '#f) (set (*value orbit-env '*debug-flag*) '#f) (set (repl-eval) orbit-eval) ;;; More useful breakpointing utility (with silly name). ;;; Works only in interpreted code. (*define-syntax standard-env 'bkpt (macro-expander (bkpt fmt . args) `(BREAKPOINT (FORMAT '#F ,fmt ,@args) (THE-ENVIRONMENT))))