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

[move docs] Add enums to Move reference book #17755

Closed
wants to merge 2 commits into from

Conversation

tzakian
Copy link
Contributor

@tzakian tzakian commented May 15, 2024

Description

Adds documentation for enums to the Move reference book, and also updates the abilities section for them.

Test plan

👀

Copy link

vercel bot commented May 15, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
sui-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 17, 2024 11:18pm
3 Ignored Deployments
Name Status Preview Comments Updated (UTC)
multisig-toolkit ⬜️ Ignored (Inspect) Visit Preview May 17, 2024 11:18pm
sui-kiosk ⬜️ Ignored (Inspect) Visit Preview May 17, 2024 11:18pm
sui-typescript-docs ⬜️ Ignored (Inspect) Visit Preview May 17, 2024 11:18pm

Copy link
Contributor

@ronny-mysten ronny-mysten left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Tim!

external-crates/move/documentation/book/src/abilities.md Outdated Show resolved Hide resolved
external-crates/move/documentation/book/src/abilities.md Outdated Show resolved Hide resolved
external-crates/move/documentation/book/src/enums.md Outdated Show resolved Hide resolved
external-crates/move/documentation/book/src/enums.md Outdated Show resolved Hide resolved
external-crates/move/documentation/book/src/enums.md Outdated Show resolved Hide resolved
external-crates/move/documentation/book/src/enums.md Outdated Show resolved Hide resolved
external-crates/move/documentation/book/src/enums.md Outdated Show resolved Hide resolved
external-crates/move/documentation/book/src/enums.md Outdated Show resolved Hide resolved
external-crates/move/documentation/book/src/enums.md Outdated Show resolved Hide resolved
external-crates/move/documentation/book/src/enums.md Outdated Show resolved Hide resolved
@tzakian
Copy link
Contributor Author

tzakian commented May 16, 2024

Thank you for the review and suggestions @ronny-mysten!

Copy link
Contributor

@amnn amnn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

external-crates/move/documentation/book/src/enums.md Outdated Show resolved Hide resolved
external-crates/move/documentation/book/src/enums.md Outdated Show resolved Hide resolved

You can pattern match on Move values by value, immutable reference, and mutable reference. When
pattern matching by value, the value is moved into the match arm. When pattern matching by
reference, the value is borrowed into the match arm (either immutably or mutably). We'll go through
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought we tended not to use "We" in docs. cc @ronny-mysten, did I remember that correctly, and if so, what's the alternative in cases like this?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's true for Sui docs. These don't have a style guide and was asked not to provide that level of feedback originally. It's better to just mention that "the instructions...", "the document...", "the following examples..." go through... But because "we" was used throughout, probably best to keep it consistent.

tzakian and others added 2 commits May 17, 2024 16:12
Co-authored-by: ronny-mysten <118224482+ronny-mysten@users.noreply.github.com>
@tzakian
Copy link
Contributor Author

tzakian commented May 31, 2024

Closing for this PR for the Move book repo instead: MystenLabs/move-book#68

@tzakian tzakian closed this May 31, 2024
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.

None yet

3 participants