Formatter option is now composed of two data: flags (lower 16 bits) and indentation size (higher 16 bits).

DictType and ListType formatter use both indent and flag options.
Simple-store now makes a DictType from its data and its ToString() function returns dict.ToString()
This commit is contained in:
2024-06-11 16:32:01 +02:00
parent 56d6d06d15
commit 9fb611aa20
8 changed files with 126 additions and 42 deletions
+1 -1
View File
@@ -44,7 +44,7 @@ func dummy(ctx ExprContext, name string, args []any) (result any, err error) {
func TestFunctionToStringSimple(t *testing.T) {
source := NewGolangFunctor(dummy)
want := "func() {<body>}"
want := "func() {}"
got := source.ToString(0)
if got != want {
t.Errorf(`(func() -> result = %v [%T], want = %v [%T]`, got, got, want, want)