Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: "pointer to context object" vs "context object" #1475

Closed
real-or-random opened this issue Jan 4, 2024 · 0 comments · Fixed by #1476
Closed

docs: "pointer to context object" vs "context object" #1475

real-or-random opened this issue Jan 4, 2024 · 0 comments · Fixed by #1476
Labels
user-documentation user-facing documentation

Comments

@real-or-random
Copy link
Contributor

We should always say "pointer to a secp256k1 context object" in the API docs

From IRC discussion, see https://gnusha.org/secp256k1/2024-01-04.log :

08:37 < nickler> "ctx: pointer to a context object." or "ctx: a secp256k1 context object.". We currently use both arbitrarily afaics.
08:42 < real_or_random> nickler: I think this confusion stems from _context_create where the docs say "Returns: a newly created context object."
08:44 < real_or_random> I guess the initial idea was that the pointers of type secp256k1_context* ARE "context objects" (and don't POINT TO context object). perhaps this is also the reason for the different spacing around the asterisk for pointers 
08:44 < real_or_random> I mean for contexts 
08:46 < real_or_random> but I think that's too much abstraction. we should just always say "pointer to a context object" 
08:46 < sipa> I can't remember ever thinking that the pointer itself was to be treated as the context object.
08:47 < sipa> I think there are other places in the code where we confuse (for brevity) objects and pointers to them, though perhaps not in the public headers.
08:47 < real_or_random> ok, maybe this is just my wrong interpretation
@real-or-random real-or-random added the user-documentation user-facing documentation label Jan 4, 2024
@real-or-random real-or-random linked a pull request Jan 4, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
user-documentation user-facing documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant