From: Eric Abrahamsen <eric@ericabrahamsen.net>
To: 28489@debbugs.gnu.org
Subject: bug#28489: Acknowledgement (27.0.50; eieio-persistent slot type validation should be a bit smarter)
Date: Sat, 30 Sep 2017 16:30:10 -0700 [thread overview]
Message-ID: <878tgvdat9.fsf@ericabrahamsen.net> (raw)
In-Reply-To: <87lglcn8dt.fsf@ericabrahamsen.net>
Noam Postavsky <npostavs@users.sourceforge.net> writes:
> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
>
>> Here's the commit as it stands, seems to work fine. I'll let it mellow
>> for a while, and then commit to... emacs-26? Since it's technically a
>> bug fix?
>
> Yes. You are missing a (require 'seq) in eieo-base.el though (without
> that, I get an error when running 'make -C test eieio-test-persist').
Thanks, done.
>> * lisp/emacs-lisp/eieio-base.el (eieio-persistent-slot-type-is-class-p):
>> An `or' form can specify multiple potential classes (or null) as
>> valid types for a slot, but previously only the final element of the
>> `or' was actually checked. Now returns all valid classes in the `or'
>> form.
>> * lisp/emacs-lisp/eieio-base.el (eieio-persistent-validate/fix-slot-value):
>> Check if proposed value matches any of the valid classes.
>
> These 2 entries should be combined like:
>
> * lisp/emacs-lisp/eieio-base.el (eieio-persistent-slot-type-is-class-p):
> An `or' form can specify multiple potential classes (or null) as [...]
> (eieio-persistent-validate/fix-slot-value): Check if proposed value
> matches any of the valid classes.
Dunno how that happened...
>> +(ert-deftest eieio-test-multiple-class-slot ()
>> + (let ((persist
>> + (persistent-multiclass-slot "random string"
>> + :slot1 (persistent-random-class)
>> + :slot2 (persist-not-persistent)
>> + :file (concat default-directory "test-ps5.pt"))))
>> + (persist-test-save-and-compare persist)
>> + (delete-file (oref persist file))))
>
> I think this test should a bit more thorough about deleting the file,
> even if the test fails for some reason:
>
> (unwind-protect
> (persist-test-save-and-compare persist)
> (ignore-errors (delete-file (oref persist file))))
Done -- at some point, the same should be done for the other tests.
Thanks,
Eric
next prev parent reply other threads:[~2017-09-30 23:30 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-18 0:43 bug#28489: 27.0.50; eieio-persistent slot type validation should be a bit smarter Eric Abrahamsen
[not found] ` <handler.28489.B.150569546424990.ack@debbugs.gnu.org>
2017-09-26 20:22 ` bug#28489: Acknowledgement (27.0.50; eieio-persistent slot type validation should be a bit smarter) Eric Abrahamsen
2017-09-27 0:05 ` Noam Postavsky
2017-09-27 16:39 ` Eric Abrahamsen
2017-09-28 2:23 ` Noam Postavsky
2017-09-28 5:02 ` Eric Abrahamsen
2017-09-29 0:35 ` Noam Postavsky
2017-09-29 20:31 ` Eric Abrahamsen
2017-09-30 0:57 ` Noam Postavsky
2017-09-30 18:05 ` Eric Abrahamsen
2017-09-30 21:58 ` Noam Postavsky
2017-09-30 23:30 ` Eric Abrahamsen [this message]
2017-10-14 12:13 ` Eric Abrahamsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=878tgvdat9.fsf@ericabrahamsen.net \
--to=eric@ericabrahamsen.net \
--cc=28489@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.