Tags: mitranim/gg
Tags
more slice functions, set methods, fixes * Add `gg.Set.IsEmpty`. * Add `gg.Set.IsNotEmpty`. * Add `gg.TakeLastWhile`. * Add `gg.Slice.TakeLastWhile`. * Add `gg.DropLastWhile`. * Add `gg.Slice.DropLastWhile`. * Add `gg.FindLastIndex`. * Add `gg.Slice.FindLastIndex`. * Add `gg.FindLast`. * Add `gg.Slice.FindLast`. * Add `gg.FoundLast`. * Add `gg.Slice.FoundLast`. * Bugfix `gg.TakeWhile`. * Bugfix `gg.DropWhile`.
better error tracing; breaking renaming; misc tweaks Breaking: * Rename `gg.JsonParse` → `gg.JsonDecode`. * Rename `gg.JsonParseTo` → `gg.JsonDecodeTo`. * Rename `gg.JsonParseCatch` → `gg.JsonDecodeCatch`. * Rename `gg.Err.AppendStack` → `gg.Err.AppendStackTo`. * Rename `gg.Trace.AppendIndent` → `gg.Trace.AppendIndentTo`. * Rename `gg.Trace.AppendIndentTable` → `gg.Trace.AppendIndentTableTo`. * Rename `gg.Trace.AppendIndentMulti` → `gg.Trace.AppendIndentMultiTo`. * Rename `gg.Caller.AppendIndent` → `gg.Caller.AppendIndentTo`. * Rename `gg.Caller.AppendNewlineIndent` → `gg.Caller.AppendNewlineIndentTo`. * Rename `gg.Frames.AppendIndentTable` → `gg.Frames.AppendIndentTableTo`. * Rename `gg.Frame.AppendIndent` → `gg.Frame.AppendIndentTo`. * Rename `gg.Frame.AppendNewlineIndent` → `gg.Frame.AppendNewlineIndentTo`. * Rename `gg.Frame.AppendRowIndent` → `gg.Frame.AppendRowIndentTo`. * Rename `gtest.NoError` → `gtest.NoErr`. * Rename `gtest.ErrorStr` → `gtest.ErrStr`. * Rename `gtest.Err` → `gtest.VerbErr`. * Rename `gtest.Error` → `gtest.Err`. Other: * Add `gg.JsonEncodeIndent`. * Add `gg.JsonEncodeCatch`. * Add `gg.JsonEncodeIndentCatch`. * Add `gg.JsonDecodeOpt`. * Add `gg.JsonDecodeOptTo`. * Add `gg.StackAppenderTo`. * Add `gg.WrapTracedAt`. * Add `gg.TryTrans`. * Add `gg.Compacted`. * Add `gg.Split`. * Add `gg.ReadDirFileNames`. * Add `gg.Buf.AppendErrorStack`. * Add `gg.Err.OwnTrace`. * Add `gg.Errs.WrapTracedAt`. * Add `gg.Trace.IsEmpty`. * Add `gg.OrdSet.Reset`. * Export more "msg X" functions in `gtest`.
more comparison functions * Add `gg.IsSorted`. * Add `gg.Less2`. * Add `gg.Less`. * Add `gg.LessPrim2`. * Add `gg.LessPrim`. * Add `gg.LessEq2`. * Add `gg.LessEq`. * Add `gg.LessEqPrim2`. * Add `gg.LessEqPrim`. * Add `gg.AddUncheck`. * Add `gg.SubUncheck`. * Add `gg.Words.Piped`. * Rename `gg.PtrSwap` → `gg.SnapSwap`. Misc: move comparison and ptr funs to their own files.
`gsql`: avoid zeroing scan target Previously, various scanning functions in `gsql`, specifically those that take an addressable target, would always scan into a zero value, then overwrite the target with the resulting value. This could cause problems when the target contained non-DB fields not intended to be zeroed, even when those fields were private. The new behavior is to avoid allocating new values, unless appending elements to slices, and prefer to scan into the provided addressable target, avoiding the issue.
PreviousNext