From 9d0c73cef2e51da0565e09cce2b25b187cad0029 Mon Sep 17 00:00:00 2001 From: Anmol Sethi Date: Wed, 18 Jan 2023 07:39:09 -0800 Subject: [PATCH] d2ast: Make null ScalarString empty string So people know it's special at least until I fix d2compiler. --- d2ast/d2ast.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/d2ast/d2ast.go b/d2ast/d2ast.go index 09a00e63e..bd4373f76 100644 --- a/d2ast/d2ast.go +++ b/d2ast/d2ast.go @@ -404,7 +404,7 @@ func (s *SingleQuotedString) scalar() {} func (s *BlockString) scalar() {} // TODO: mistake, move into parse.go -func (n *Null) ScalarString() string { return n.Type() } +func (n *Null) ScalarString() string { return "" } func (b *Boolean) ScalarString() string { return strconv.FormatBool(b.Value) } func (n *Number) ScalarString() string { return n.Raw } func (s *UnquotedString) ScalarString() string {