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

Balance the debug output of Lvalue Subslice #37692

Merged
merged 1 commit into from
Nov 12, 2016

Conversation

nbp
Copy link
Contributor

@nbp nbp commented Nov 10, 2016

The current debug output for Lvalue Subslice is not balanced and does not respect the comment[1], which indicates that we use slice[from:-to] in Python terms.. In python terms slices which have a start but no end are written as a[start:], so following the comment, I fixed the output accordingly.

Grep-ing over the sources, I did not found any test cases checking this subslice debug output.
Note, I have not yet tested this change yet, as I am still waiting for the end of LLVM compilation.

[1] https://manishearth.github.io/rust-internals-docs/rustc/mir/enum.ProjectionElem.html

@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 @eddyb (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.

@eddyb
Copy link
Member

eddyb commented Nov 10, 2016

@bors r+ rollup Thanks!

@bors
Copy link
Contributor

bors commented Nov 10, 2016

📌 Commit 4ce4900 has been approved by eddyb

@alexcrichton alexcrichton added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Nov 10, 2016
eddyb added a commit to eddyb/rust that referenced this pull request Nov 11, 2016
Balance the debug output of Lvalue Subslice

The current debug output for Lvalue Subslice is not balanced and does not respect the comment[1], which indicates that we use `slice[from:-to] in Python terms.`.  In python terms slices which have a start but no end are written as `a[start:]`, so following the comment, I fixed the output accordingly.

Grep-ing over the sources, I did not found any test cases checking this subslice debug output.
Note, I have not yet tested this change yet, as I am still waiting for the end of LLVM compilation.

[1] https://manishearth.github.io/rust-internals-docs/rustc/mir/enum.ProjectionElem.html
eddyb added a commit to eddyb/rust that referenced this pull request Nov 12, 2016
Balance the debug output of Lvalue Subslice

The current debug output for Lvalue Subslice is not balanced and does not respect the comment[1], which indicates that we use `slice[from:-to] in Python terms.`.  In python terms slices which have a start but no end are written as `a[start:]`, so following the comment, I fixed the output accordingly.

Grep-ing over the sources, I did not found any test cases checking this subslice debug output.
Note, I have not yet tested this change yet, as I am still waiting for the end of LLVM compilation.

[1] https://manishearth.github.io/rust-internals-docs/rustc/mir/enum.ProjectionElem.html
bors added a commit that referenced this pull request Nov 12, 2016
@bors bors merged commit 4ce4900 into rust-lang:master Nov 12, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants