Subject: bug#41741: [PATCH] Save project list as lisp data

From: Dmitry Gutov <[email-masked]>
Date: Sun, 7 Jun 2020 23:18:26 +0300

On 07.06.2020 22:55, Simen Heggestøyl wrote:

 > It is transient now, yes.

And later, it won't be?

> Just as an example I can imagine an optional feature in the future where
> you could name a project interactively the first time it's seen
> (i.e. when it's added to the project list for the first time).

And then lose all these annotations when a project root directory is 
moved/renamed/etc?

But OK, maybe it won't happen too often to really worry about.

>>> -          (when (file-exists-p filename)
>>> +          (when (file-readable-p filename)
>>
>> What's the difference? File exists, but belongs to another account?
>> I'm not sure we'd want to silently fail in that case (kinda puzzling
>> behavior), and writing to the file is likely to fail later too.
> 
> Hm, yes. I snatched that part from saveplace.el, but after you pointed
> it out I now also think it's better to get an error in that
> case. Reverted.

Perhaps we should change saveplace as well. :-)

>>> +              (car (read-from-string (buffer-string))))))))
>>
>> AKA:
>>
>>       (goto-char (point-min))
>>       (read (current-buffer))
>>
>> Though the practical difference will be tiny.
> 
> I don't mind changing it, but could you explain the difference to me? My
> understanding isn't deep enough to see anything but one line versus
> two. :)

Just an extra string allocation, I guess.