Skip to content

docs(example): clarify SetTotal usage in dynTotal example - #164

Merged
vbauerster merged 1 commit into
vbauerster:masterfrom
Solaris-star:docs/144-clarify-dyntotal-example
Aug 3, 2026
Merged

docs(example): clarify SetTotal usage in dynTotal example#164
vbauerster merged 1 commit into
vbauerster:masterfrom
Solaris-star:docs/144-clarify-dyntotal-example

Conversation

@Solaris-star

Copy link
Copy Markdown
Contributor

The dynTotal example's comments were too sparse — users were confused about what SetTotal(n, false) vs SetTotal(n, true) does and why total starts at 0.

Expanded the comments to explain:

  • Why total starts at 0 (unknown final size, no auto-complete)
  • What SetTotal(n, false) does mid-stream (running estimate, no completion trigger)
  • What SetTotal(n, true) does at the end (trigger completion, let p.Wait() return)

Closes #144

Expand the comments to explain:
- why total starts at 0 (unknown final size)
- what SetTotal(n, false) does mid-stream (running estimate, no completion)
- what SetTotal(n, true) does at the end (trigger completion)

Closes vbauerster#144
@vbauerster
vbauerster merged commit 4c24b6e into vbauerster:master Aug 3, 2026
8 checks passed
@vbauerster

Copy link
Copy Markdown
Owner

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

confusing dyn total example

2 participants