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

Split up files with // ignore-tidy-filelength #75701

Closed

Conversation

alex-griffiths
Copy link

@alex-griffiths alex-griffiths commented Aug 19, 2020

Sorry it's taken me so long to get my act togethern on this, and that even with all the time, not much has been done. Hopefully what I've got here is at least acceptable.

One thing. When I'd build the compiler, I'd get some warnings about missing stability attributes. I wasn't sure the best way to fix this warning, so I've copied and pasted the stability attributes from the structs themselves. I hope this is okay. If not, I can try and fix it.

This is for #60302

@rust-highfive
Copy link
Collaborator

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @KodrAus (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see the contribution instructions for more information.

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 19, 2020
Copy link
Member

@JohnTitor JohnTitor left a comment

Choose a reason for hiding this comment

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

Please format the changes with ./x.py fmt, at least.

src/librustc_resolve/diagnostics.rs Outdated Show resolved Hide resolved
src/librustc_resolve/binding_error.rs Outdated Show resolved Hide resolved
library/core/src/str/utf8.rs Outdated Show resolved Hide resolved
library/alloc/src/vec/drain.rs Show resolved Hide resolved
library/alloc/src/vec/drain.rs Outdated Show resolved Hide resolved
library/core/src/str/indices.rs Outdated Show resolved Hide resolved
library/core/src/str/mod.rs Show resolved Hide resolved
library/core/src/str/mod.rs Outdated Show resolved Hide resolved
@JohnTitor JohnTitor changed the title Split up files with '// ignore-tidy-filelength Split up files with // ignore-tidy-filelength Aug 19, 2020
@petrochenkov
Copy link
Contributor

@alex-griffiths
Could you avoid the changes in librustc_resolve?

If you'd like to do something in this direction, I'd suggest to start with moving #[test] functions into separate files in library/std (rust-lang/compiler-team#344, see #63207 for an example).
That's the change that certainly won't break any internal structure of the affected crates.

@alex-griffiths
Copy link
Author

I'm so sorry. I didn't properly check that the changes I made at least built. I'll fix that now.

library/core/src/str/mod.rs Outdated Show resolved Hide resolved
@petrochenkov
Copy link
Contributor

@alex-griffiths
Could you squash commits as well, so that librustc_resolve changes are no longer in git history?
(This is not urgent, just something that needs to be done before the merge.)

@bors
Copy link
Contributor

bors commented Aug 24, 2020

☔ The latest upstream changes (presumably #75815) made this pull request unmergeable. Please resolve the merge conflicts.

@KodrAus
Copy link
Contributor

KodrAus commented Sep 4, 2020

Thanks for working on this @alex-griffiths!

It looks like we've got some merge conflicts and a few broken doc links after the move:

core/str/fn.from_utf8_mut.html:25: broken link - core/str/struct.Utf8Error.html
core/str/fn.from_utf8.html:43: broken link - core/str/struct.Utf8Error.html
core/str/utf8/struct.Utf8Error.html:4: broken link - core/std/string/struct.String.html
core/str/utf8/struct.Utf8Error.html:65: broken link - core/std/char/constant.REPLACEMENT_CHARACTER.html
thread 'main' panicked at 'found some broken links', src/tools/linkchecker/main.rs:67:9

Comment on lines +23 to +27
#[stable(feature = "rust1", since = "1.0.0")]
pub mod utf8;

#[stable(feature = "rust1", since = "1.0.0")]
pub mod indices;
Copy link
Contributor

Choose a reason for hiding this comment

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

You don't need to public these mods.

@KodrAus KodrAus removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Sep 11, 2020
@KodrAus KodrAus added the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Sep 11, 2020
@JohnCSimon
Copy link
Member

Ping from triage:
@alex-griffiths can you please address the comments, thank you.

@Dylan-DPC-zz
Copy link

hi @alex-griffiths thanks for taking the time to contribute. This has been inactive for a while, so I have to close it. If you wish and have the time in future you can open a new PR and we'll take it forward from there :) Thanks

@Dylan-DPC-zz Dylan-DPC-zz added S-inactive Status: Inactive and waiting on the author. This is often applied to closed PRs. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Sep 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-inactive Status: Inactive and waiting on the author. This is often applied to closed PRs.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants