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

Conditions under which some slice methods return None seem undocumented #40435

Closed
8573 opened this issue Mar 11, 2017 · 0 comments
Closed

Conditions under which some slice methods return None seem undocumented #40435

8573 opened this issue Mar 11, 2017 · 0 comments
Labels
A-docs Area: Documentation for any part of the project, including the compiler, standard library, and tools

Comments

@8573
Copy link

8573 commented Mar 11, 2017

Some methods of slices, including split_first, split_first_mut,
split_last, and split_last_mut return Option types without
documenting the conditions under which they return Some vs None; I
would like to suggest that these conditions be documented.

@steveklabnik steveklabnik added the A-docs Area: Documentation for any part of the project, including the compiler, standard library, and tools label Mar 11, 2017
frewsxcv added a commit to frewsxcv/rust that referenced this issue Mar 19, 2017
…r=frewsxcv

Add mention of None as possible return. Closes rust-lang#40435.

This commit adds a small mention to some methods that None is returned when the slice is empty.
@bors bors closed this as completed in b77d31a Mar 19, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-docs Area: Documentation for any part of the project, including the compiler, standard library, and tools
Projects
None yet
Development

No branches or pull requests

3 participants