write-snapshot doesn't work
Created by: reiniervandijk
(define-object write-snapshot-test (base-object)
:input-slots
((a 2 :settable))
)
Then try:
gdl-user> (make-self 'write-snapshot-test :a 5)
#<write-snapshot-test @ #x23b5f4aa>
gdl-user> (the (write-snapshot :filename "D:/test.gdl"))
; No value
And the output is according to:
(in-package :gdl-user)
(write-snapshot-test)
Imported comments:
By genworks on 2013-03-06 17:47:32 UTC
This is fixed in github. Use the following to preview the fix:
(in-package :gdl)
(excl:without-package-locks
(define-object-amendment vanilla-mixin* ()
:functions
((active-inputs
()
(let ((inputs (append (the (message-list :category :optional-input-slots))
(the (message-list :category :settable-optional-input-slots))
(the (message-list :category :settable-defaulted-input-slots))
(the (message-list :category :required-input-slots))
(the (message-list :category :defaulted-input-slots)))) result)
(mapc #'(lambda (slot)
(let ((contents (funcall (read-from-string (format nil "gdl-acc::~a" slot)) self)))
(when (and (not (member slot '(:%name% :%parent% :%aggregate% :%index% :$$tatu-object)))
(consp contents) (third contents))
(push slot result) (push (readable-expression (first contents) self) result)))) inputs)
(nreverse result))))))