From bcc58cb3048faa146ed0f90b330ebbe791d53b5c Mon Sep 17 00:00:00 2001 From: anon5 Date: Sun, 19 Sep 2021 12:45:50 +0000 Subject: Switch to Minetest 5.4.1 protocol and other changes --- stack.go | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'stack.go') diff --git a/stack.go b/stack.go index d930604..8cf3aa8 100644 --- a/stack.go +++ b/stack.go @@ -1,6 +1,6 @@ // In this file, JSON refers to WTF-JSON. // -// BUG(mt): Itemstrings use variant of JSON called WTF-JSON +// BUG(mt): Stackstrings use variant of JSON called WTF-JSON // where \u00XX escapes in string literals act like Go's \xXX escapes. // This should not be fixed because it would break existing items. @@ -25,10 +25,7 @@ type Item struct { ItemMeta } -// String returns the Stack's itemstring. -// -// BUG(mt): The term itemstring is somewhat misleading, because -// an itemstring represents a stack of items, not a single item. +// String returns the Stack's stackstring. func (s Stack) String() string { if s.Count == 0 { return "" @@ -90,7 +87,7 @@ func jsonStr(s string) string { return b.String() } -// Scan scans an itemstring, implementing the fmt.Scanner interface. +// Scan scans a stackstring, implementing the fmt.Scanner interface. func (stk *Stack) Scan(state fmt.ScanState, verb rune) (err error) { *stk = Stack{} -- cgit v1.2.3