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

Hide all generated items except for projected types from calling code #192

Merged
merged 1 commit into from
Apr 19, 2020

Conversation

taiki-e
Copy link
Owner

@taiki-e taiki-e commented Apr 18, 2020

Generate all items except for projected types inside a const scope. This makes it impossible for user code to refer to these types. This removes redundant prefix/postfix based on the original type from many generate types. This also remove the pin_project_show_unpin_struct flag.

@taiki-e taiki-e force-pushed the underscore-const-names branch from 21b6b10 to add5ca5 Compare April 18, 2020 21:37
@taiki-e taiki-e added S-blocked Status: Blocked on something else C-enhancement Category: A new feature or an improvement for an existing one labels Apr 18, 2020
@taiki-e taiki-e self-assigned this Apr 18, 2020
@taiki-e taiki-e force-pushed the underscore-const-names branch 2 times, most recently from 9bf87d1 to c6cd9a2 Compare April 19, 2020 13:29
@taiki-e taiki-e changed the title [WIP] Use underscore_const_names Hide all items except for projected types from calling code Apr 19, 2020
@taiki-e taiki-e removed the S-blocked Status: Blocked on something else label Apr 19, 2020
@taiki-e taiki-e marked this pull request as ready for review April 19, 2020 13:33
@taiki-e
Copy link
Owner Author

taiki-e commented Apr 19, 2020

It needs to decide which remove support of rust older than 1.37 and whether to remove the pin_project_show_unpin_struct flag.

Keep support for 1.33, remove pin_project_show_unpin_struct flag. If someone needed that flag, we can probably restore it later.

@taiki-e

This comment has been minimized.

bors bot added a commit that referenced this pull request Apr 19, 2020
192: Hide all items except for projected types from calling code r=taiki-e a=taiki-e

Generate all items except for projected types inside a `const` scope. This makes it impossible for user code to refer to these types. This removes redundant prefix/postfix based on the original type from many generate types. This also remove the `pin_project_show_unpin_struct` flag.

Co-authored-by: Taiki Endo <te316e89@gmail.com>
@taiki-e

This comment has been minimized.

@bors

This comment has been minimized.

@taiki-e taiki-e force-pushed the underscore-const-names branch from c6cd9a2 to 9eba3fe Compare April 19, 2020 14:11
@taiki-e taiki-e changed the title Hide all items except for projected types from calling code Hide all generated items except for projected types from calling code Apr 19, 2020
@taiki-e taiki-e force-pushed the underscore-const-names branch from 9eba3fe to 2577f02 Compare April 19, 2020 14:14
@taiki-e taiki-e force-pushed the underscore-const-names branch from 2577f02 to fd1924d Compare April 19, 2020 14:17
@taiki-e
Copy link
Owner Author

taiki-e commented Apr 19, 2020

bors r+

@bors
Copy link
Contributor

bors bot commented Apr 19, 2020

@bors bors bot merged commit f21de9f into master Apr 19, 2020
@bors bors bot deleted the underscore-const-names branch April 19, 2020 14:22
@taiki-e taiki-e removed their assignment May 4, 2020
@taiki-e taiki-e added the A-pin-projection Area: #[pin_project] label May 7, 2020
bors bot added a commit that referenced this pull request May 7, 2020
211: Hide generated items from --document-private-items r=taiki-e a=taiki-e

All of the generated items are private items, but it can be displayed in the document by using the `--document-private-items` flag.

Naming will be allowed by #202, so it would probably be preferable to only display it in the document if the user did a naming.

cc #124 #202
Related: #192

Co-authored-by: Taiki Endo <te316e89@gmail.com>
@taiki-e taiki-e removed the C-enhancement Category: A new feature or an improvement for an existing one label Jan 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-pin-projection Area: #[pin_project]
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant