diff options
author | Jakob Unterwurzacher | 2024-01-23 21:36:24 +0100 |
---|---|---|
committer | Jakob Unterwurzacher | 2024-01-23 21:36:24 +0100 |
commit | 9958b63931aee613d5f97a8e7137efa3fb118343 (patch) | |
tree | 1a6985c23a4f58d76fc1e60ffde2b2e494b73269 /internal | |
parent | 6fbe61d11017051b035cebe00b66481203a2a036 (diff) |
go.mod: update all deps
Diffstat (limited to 'internal')
-rw-r--r-- | internal/generation_num/generation_num.go | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/internal/generation_num/generation_num.go b/internal/generation_num/generation_num.go new file mode 100644 index 0000000..298db14 --- /dev/null +++ b/internal/generation_num/generation_num.go @@ -0,0 +1,11 @@ +package generation_num + +import ( + "sync/atomic" +) + +var gen uint64 + +func Next() uint64 { + return atomic.AddUint64(&gen, 1) +} |