mirror of
https://github.com/PDP-10/its.git
synced 2026-01-30 21:41:56 +00:00
Added files to support building and running Macsyma.
Resolves #284. Commented out uses of time-origin in maxtul; mcldmp (init) until we can figure out why it gives arithmetic overflows under the emulators. Updated the expect script statements in build_macsyma_portion to not attempt to match expected strings, but simply sleep for some time since in some cases the matching appears not to work.
This commit is contained in:
33
src/maxsrc/char.2
Normal file
33
src/maxsrc/char.2
Normal file
@@ -0,0 +1,33 @@
|
||||
;;;;;;;;;;;;;;;;;;; -*- Mode: Lisp; Package: Macsyma -*- ;;;;;;;;;;;;;;;;;;;
|
||||
;;; (c) Copyright 1980 Massachusetts Institute of Technology ;;;
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
(macsyma-module char)
|
||||
|
||||
|
||||
;;; hacks for character manipulation.
|
||||
|
||||
|
||||
(DEFMFUN $GETCHARN (SYMBOL INDEX)
|
||||
(OR (SYMBOLP SYMBOL)
|
||||
(MERROR "First arg to GETCHARN: ~A, was not a symbol."
|
||||
(implode (mstring symbol))))
|
||||
(OR (AND (FIXP INDEX)
|
||||
(> INDEX 0))
|
||||
(MERROR "Second arg to GETCHARN: ~A, was not a positive fixnum."
|
||||
(implode (mstring index))))
|
||||
; what happens next is debateable.
|
||||
; one thing I don't want to do call mstring and take nthcdr.
|
||||
; what to returns depends on what you would see printed.
|
||||
; well, or read in.
|
||||
; the main use for this is to check symbol name conventions,
|
||||
; so $FOO and &FOO might be the same, same with %FOO I guess,
|
||||
; but FOO (i.e. ?FOO is different.) poo, all these things
|
||||
; depend on the setting of global switches. screw it.
|
||||
(LET ((C1 (GETCHARN SYMBOL 1)))
|
||||
(COND ((OR (= C1 #/$) (= C1 #/%) (= C1 #/&))
|
||||
(GETCHARN SYMBOL (1+ INDEX)))
|
||||
((= INDEX 1) #/?)
|
||||
(T (GETCHARN SYMBOL (1- INDEX))))))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user