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

Change DIBuilderCreateEnumerator signature to match LLVM 9 #69734

Merged
merged 3 commits into from Mar 9, 2020

Conversation

@tmiasko
Copy link

tmiasko commented Mar 5, 2020

  • Change DIBuilderCreateEnumerator signature to match LLVM 9 C API.
  • Use provided is unsigned flag when emitting enumerators.
@rust-highfive

This comment has been minimized.

Copy link
Collaborator

rust-highfive commented Mar 5, 2020

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @ecstatic-morse (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.

Copy link
Contributor

ecstatic-morse left a comment

Some questions about ownership need to be resolved before this is merged. Also left a nit about using as casts for discriminants.

@tmiasko tmiasko force-pushed the tmiasko:di-enumerator branch from 9a0c17b to 30650f8 Mar 5, 2020
@ecstatic-morse

This comment has been minimized.

Copy link
Contributor

ecstatic-morse commented Mar 5, 2020

Thanks @tmiasko! LGTM, although I'm gonna defer to someone who works on this code, since I don't quite understand why this worked before if we were using the wrong signature.

r? @nagisa

@tmiasko

This comment has been minimized.

Copy link
Author

tmiasko commented Mar 5, 2020

Oh sorry, I didn't made it clear in PR description. The PR prepares for migration
to the C API that is available since LLVM 9, without actually mgirating it yet, sice
we support older versions of LLVM.

Thus the code continues to use own wrapper LLVMRustDIBuilderCreateEnumerator rather than
official one LLVMDIBuilderCreateEnumerator, but now they have exactly the same type
signature and arguments.

@ecstatic-morse

This comment has been minimized.

Copy link
Contributor

ecstatic-morse commented Mar 5, 2020

Ah, I see now.

r? @ecstatic-morse
@bors r+ rollup

@bors

This comment has been minimized.

Copy link
Contributor

bors commented Mar 5, 2020

📌 Commit 30650f8 has been approved by ecstatic-morse

@ecstatic-morse

This comment has been minimized.

Copy link
Contributor

ecstatic-morse commented Mar 5, 2020

Note to self: llvm::StringRef explicitly does not require the string to be null-terminated. It does, however, have a const char* constructor for null-terminated strings, which is what we were using prior to this PR.

bors added a commit that referenced this pull request Mar 8, 2020
Rollup of 7 pull requests

Successful merges:

 - #69120 (Don't give invalid suggestion on desugared span.)
 - #69326 (mir-interpret: add method to read wide strings from Memory)
 - #69608 (Expose target libdir information via print command)
 - #69734 (Change DIBuilderCreateEnumerator signature to match LLVM 9)
 - #69800 (Compile address sanitizer test with debuginfo)
 - #69807 (Cleanup E0391 explanation)
 - #69820 (clean up E0392 explanation)

Failed merges:

r? @ghost
@bors bors merged commit e2617a9 into rust-lang:master Mar 9, 2020
4 checks passed
4 checks passed
pr Build #20200305.33 succeeded
Details
pr (Linux mingw-check) Linux mingw-check succeeded
Details
pr (Linux x86_64-gnu-llvm-7) Linux x86_64-gnu-llvm-7 succeeded
Details
pr (Linux x86_64-gnu-tools) Linux x86_64-gnu-tools succeeded
Details
@tmiasko tmiasko deleted the tmiasko:di-enumerator branch Mar 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants
You can’t perform that action at this time.