From d4d9aab5d4067e65239d2a67abd22039e9f42ffc Mon Sep 17 00:00:00 2001 From: Alejandro Mery Date: Fri, 1 Sep 2023 14:26:52 +0000 Subject: [PATCH] basic: GoString [WIP] Signed-off-by: Alejandro Mery --- basic/write.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/basic/write.go b/basic/write.go index d4a74e9..57ee28b 100644 --- a/basic/write.go +++ b/basic/write.go @@ -86,3 +86,9 @@ func (doc *Document) String() string { buf := doc.AsBuffer(WriteNewLine) return buf.String() } + +// GoString generates a string output for "%#v" +func (Document) GoString() string { + var buf bytes.Buffer + return buf.String() +}