Skip to content

Add support for setopt #550

@shackra

Description

@shackra

hello

since or before Emacs 29.1, there is a function called setopt:

setopt is an autoloaded Lisp macro in cus-edit.el .

(setopt [VARIABLE VALUE]...)

Set VARIABLE/VALUE pairs, and return the final VALUE.
This is like setq , but is meant for user options instead of
plain variables. This means that setopt will execute any
custom-set form associated with VARIABLE.

Note that setopt will emit a warning if the type of a VALUE
does not match the type of the corresponding VARIABLE as
declared by defcustom . (VARIABLE will be assigned the value
even if it doesn t match the type.)

Since it is like setq, I thought that probably leaf.el should support it, and use setq for older versions of Emacs under the hood.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions