Skip to content

Commit 900a041

Browse files
authored
Generate language server enum settings as const string choices (#4517)
1 parent 1bec655 commit 900a041

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scripts/lsp-generate-settings.el

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@
3737
ENUM is the value of enum key in vscode manifest."
3838
(cond
3939
((and enum (not (or (equal "boolean" type)
40-
(equal '("boolean") type)))) `(choice (:tag ,@(append enum nil))))
40+
(equal '("boolean") type))))
41+
`(choice ,@(mapcar (lambda (e) `(const ,(format "\"%s\"" e))) enum)))
4142
(t (pcase type
4243
("boolean" 'boolean)
4344
('("boolean") 'boolean)

0 commit comments

Comments
 (0)