Lars Ingebrigtsen writes: > Philip Kaludercic writes: > >> Another idea could be to take inspiration from Guile's "Sandboxed >> Evaluation"[0] and provide a "safe subset" of Elisp that can be >> evaluated (with some additional checks). >> >> E.g. the following would allow evaluating `add-to-list' if the list if >> safe and the value is self-evaluating: > > Oh, that's a good idea. I wonder whether anybody's written an > interpreter for a "safe" version of Emacs Lisp -- then people could put > `if' statements etc also into these files. There is unsafep, but that is too strict for what we want. E.g. (unsafep '(setq tab-width 3)) ;; => (global-variable tab-width) even though we would want this to work. I've attached an incomplete sketch of how this could look like