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

refactor documentation of operators, document + for strings and paths #7498

Merged
merged 7 commits into from
Jan 6, 2023

Conversation

fricklerhandwerk
Copy link
Contributor

@fricklerhandwerk fricklerhandwerk commented Dec 23, 2022

  • move annotations out of the column

    this form is easier to maintain, displays better because it needs less space, and allows
    for more details on each operator that requires explanations.

  • document semantics of overloaded + operator

Related: #7338 (comment)

This work is sponsored by Antithesis

@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/tweag-nix-dev-update-42/24204/1

@edolstra
Copy link
Member

I'm not convinced that this format is better for readers than a table. Whether the table is less maintainable is not super important given that we rarely ever add operators.

For comparison, the Rust language reference also uses a table: https://doc.rust-lang.org/book/appendix-02-operators.html

this is for a simpler transformation into a series of subsections
this form is much easier to maintain (also with minimal diffs), and
allows for more details on each operator.

this change a purely mechanical transformation, without changing any contents.
add notes on semantics where appropriate
this makes the table less unwieldy, and leaves enough space for
extensive explanations.
@fricklerhandwerk
Copy link
Contributor Author

@edolstra now this is closer to how it's done in the Rust docs. I added explanations in external notes, such that the table is narrower and we still have enough space to add explanations where needed.

@edolstra edolstra merged commit 3172c51 into NixOS:master Jan 6, 2023
@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/nix-team-report-2022-10-2023-03/27486/1

@fricklerhandwerk fricklerhandwerk deleted the path+string branch July 13, 2023 20:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants