Skip to content
Snippets Groups Projects
Commit f3d1abca authored by ram's avatar ram
Browse files

Added %PUTF, currently defined to just call the PUTF miscop, pending

writing of a lisp version.
parent 913c72bd
No related branches found
No related tags found
No related merge requests found
...@@ -29,10 +29,7 @@ ...@@ -29,10 +29,7 @@
(defun makunbound (variable) (defun makunbound (variable)
"VARIABLE must evaluate to a symbol. This symbol is made unbound, "VARIABLE must evaluate to a symbol. This symbol is made unbound,
removing any value it may currently have." removing any value it may currently have."
(set variable (makunbound variable))
(%primitive make-other-immediate-type
0
vm:unbound-marker-type)))
(defun symbol-value (variable) (defun symbol-value (variable)
"VARIABLE must evaluate to a symbol. This symbol's current special "VARIABLE must evaluate to a symbol. This symbol's current special
...@@ -85,17 +82,19 @@ ...@@ -85,17 +82,19 @@
(defun %put (symbol indicator value) (defun %put (symbol indicator value)
"The VALUE is added as a property of SYMBOL under the specified INDICATOR. "The VALUE is added as a property of SYMBOL under the specified INDICATOR.
Returns VALUE." Returns VALUE."
(do ((pl (symbol-plist symbol) (cddr pl))) (%primitive put symbol indicator value)
((endp pl) #| (do ((pl (symbol-plist symbol) (cddr pl)))
((atom pl)
(setf (symbol-plist symbol) (setf (symbol-plist symbol)
(list* indicator value (symbol-plist symbol))) (list* indicator value (symbol-plist symbol)))
value) value)
(cond ((endp (cdr pl)) (cond ((atom (cdr pl))
(error "~S has an odd number of items in its property list." (error "~S has an odd number of items in its property list."
symbol)) symbol))
((eq (car pl) indicator) ((eq (car pl) indicator)
(rplaca (cdr pl) value) (rplaca (cdr pl) value)
(return value))))) (return value))))|#
)
(defun remprop (symbol indicator) (defun remprop (symbol indicator)
"Look on property list of SYMBOL for property with specified "Look on property list of SYMBOL for property with specified
...@@ -126,6 +125,9 @@ ...@@ -126,6 +125,9 @@
((eq (car plist) indicator) ((eq (car plist) indicator)
(return (cadr plist)))))) (return (cadr plist))))))
(defun %putf (x y z)
(%primitive putf x y z))
(defun get-properties (place indicator-list) (defun get-properties (place indicator-list)
"Like GETF, except that Indicator-List is a list of indicators which will "Like GETF, except that Indicator-List is a list of indicators which will
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment