bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#24982: 24.5; way to let Elisp reader ignore unreadable #(...) constr


From: Juri Linkov
Subject: bug#24982: 24.5; way to let Elisp reader ignore unreadable #(...) constructs
Date: Mon, 02 Apr 2018 23:54:40 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu)

>> > Enhancement request:
>> >
>> > Provide a Boolean variable or a wrapper macro that has the effect of not
>> > raising an error but just skipping over any unreadable #(...) construct.
>> 
>> There is such macro called ‘ignore-errors’.
>
> No.  That ignores all errors.
>
> Is there an error handler that covers all and only #(...) read errors?

Then you can use something like

  (condition-case err
      (read (current-buffer))
    (invalid-read-syntax err))

that for example for unreadable #<marker ...> returns

  (invalid-read-syntax "#")





reply via email to

[Prev in Thread] Current Thread [Next in Thread]