• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

tecnickcom / gogen / 28802722110
100%

Build:
DEFAULT BRANCH: main
Ran 06 Jul 2026 03:28PM UTC
Jobs 1
Files 167
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

06 Jul 2026 03:19PM UTC coverage: 99.971% (+0.001%) from 99.97%
28802722110

push

github

nicolaasuni
feat(threadsafe)!: race-safe pointer-based tsslice helpers, Guarded slice/map wrappers, and bounds-checked/compound/snapshot additions

- tsslice.Set, Get, Len, Filter, Map and Reduce now take a *S (pointer to the slice) and dereference it only while holding the lock, so calls that share a slice variable while another goroutine grows it via Append no longer race on the slice header; previously the header (pointer/len/cap) was read at the call site before the lock was taken, which the race detector flagged, and the package is now correct by default instead of relying on a caller-side snapshot workaround.
- Add bounds-checked, non-panicking accessors to tsslice (GetOK, SetOK) and an order-preserving tsslice.Delete (via slices.Delete) that report an ok/removed flag instead of panicking on an out-of-range index; the indexed Get/Set keep their idiomatic panic, now documented, matching the maputil/sliceutil convention.
- Add atomic compound-operation combinators Do (write) and RDo (read) to both tsmap and tsslice for read-modify-write and multi-step sequences that a single helper cannot express, since each helper releases its lock on return and a separate GetOK-then-Set is a check-then-act race.
- Add Snapshot to both packages returning a consistent shallow copy under the read lock (slices.Clone/maps.Clone), giving free-function callers a first-class safe read-out instead of an always-true Filter.
- Add Guarded[E] and Guarded[K, V] struct types that own both the container and a sync.RWMutex so the lock can never be mismatched with the data or forgotten; the zero value is usable (tsmap.Guarded allocates its backing map lazily on first write), pointer receivers keep them copylocks-safe, and Map/Reduce/Invert to a different element type are expressed through RDo because Go methods cannot introduce their own type parameters.
- Harden the concurrency documentation: callbacks passed to Filter/Map/Reduce/Invert/Do/RDo run under the lock and must not call back into... (continued)

224 of 224 new or added lines in 4 files covered. (100.0%)

13636 of 13640 relevant lines covered (99.97%)

106548.81 hits per line

Jobs
ID Job ID Ran Files Coverage
1 28802722110.1 06 Jul 2026 03:28PM UTC 167
99.97
GitHub Action Run
Source Files on build 28802722110
  • Tree
  • List 167
  • Changed 20
  • Source Changed 20
  • Coverage Changed 18
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #28802722110
  • 8db5738c on github
  • Prev Build on main (#28759717689)
  • Next Build on main (#28806925612)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc