Skip to content

Conversation

@Kowasaki
Copy link
Contributor

The test expectations shows all the generated ::std::marker::PhantomData<::std::cell::UnsafeCell> used type parameters.

@fitzgen
Copy link
Member

fitzgen commented Apr 17, 2017

@Kowasaki thanks! This looks great!

There are just two things needed before we can merge this:

  1. There are a couple test failures in CI where it seems not all the test expectations were updated: https://travis-ci.org/servo/rust-bindgen/jobs/222713799#L813 You can go ahead and look at the logged diffs to see which files and what test expectation changes are still needed.

  2. Once that is done, please rebase on top of master and sqaush your work down into one commit.

Thanks again! Looking forward to landing this :)

Unknown author and others added 15 commits April 17, 2017 16:29
…meters

This is a follow up to c8a206a, and the support for blacklisting in the named
template parameter usage analysis. This ensures that ever item we ever call
`constrain` on has an entry in `used` for the set of template parameters it
uses. Additionally, it adds extra assertions to enforce the invariant.

We cannot completely avoid analyzing blacklisted items because we want to
consider all of a blacklisted template's parameters as used. This is why we
ensure that blacklisted items have a used template parameter set rather than
ensuring that blacklisted items never end up in the worklist.
@bors-servo
Copy link

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

@fitzgen
Copy link
Member

fitzgen commented May 1, 2017

@Kowasaki hi! do you need some help rebasing + squashing and resolving conflicts?

http://blog.steveklabnik.com/posts/2012-11-08-how-to-squash-commits-in-a-github-pull-request is a good, quick read on how to rebase + squash a pull request.

@KiChjang
Copy link
Contributor

KiChjang commented May 1, 2017

A more lengthy guide is here in servo's repository's wiki.

Unknown author and others added 2 commits May 1, 2017 20:18
@Kowasaki
Copy link
Contributor Author

Kowasaki commented May 2, 2017

Hey all,

Thanks for the guides! I think I am still doing rebasing/squashing wrong though since I can still see all the commits here... it looks like I did squash the commits on my repo but I am not sure what is going on here

bors-servo pushed a commit that referenced this pull request May 5, 2017
Emit `PhantomData<UnsafeCell<T>>` members for all generic parameters

This makes generated generic structs lifetime invariant, since we cannot know
the C++ type's true variance.

Fixes #506

Rebased + squashed version of #635; cc @Kowasaki

To resolve the conflicts and rebase and squash, I did essentially these commands:

```
$ git fetch servo
$ git checkout -b Kowasaki-master servo/master
$ git merge --squash --edit Kowasaki/master
$ cargo test
$ cd tests/expectations
$ cargo test
$ cd -
$ git commit --author="Kowasaki"
$ git push fitzgen Kowasaki-master
```

Hopefully that is useful for you in the future :) Thanks for fixing this issue!
@fitzgen
Copy link
Member

fitzgen commented May 5, 2017

Rebased + squashed in #689

@fitzgen fitzgen closed this May 5, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants