1
0
forked from aniani/vim

patch 9.1.0233: Vim9: string() output of enum is problematic

Problem:  Vim9: string() output of enum is problematic
Solution: Make string() output for an enum consistent with that of a
          regular object (Yegappan Lakshmanan).

closes: #14343

Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
Yegappan Lakshmanan
2024-03-31 18:45:35 +02:00
committed by Christian Brabandt
parent 5df961a1bc
commit 3cf121ed31
4 changed files with 38 additions and 17 deletions

View File

@@ -9599,7 +9599,7 @@ string({expr}) Return {expr} converted to a String. If {expr} is a Number,
Class class SomeName
Object object of SomeName {lnum: 1, col: 3}
Enum enum EnumName
EnumValue enum.value
EnumValue enum name.value {name: str, ordinal: nr}
When a |List| or |Dictionary| has a recursive reference it is
replaced by "[...]" or "{...}". Using eval() on the result