Skip to content

Conversation

csmoe
Copy link
Contributor

@csmoe csmoe commented Oct 24, 2018

Closes #211
r? @mark-i-m

Copy link
Contributor

@mark-i-m mark-i-m left a comment

Choose a reason for hiding this comment

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

Thanks! Overall, looks good :)

One thing is that "placeholder" seems a bit weird when used as a verb. I would propose "placeholder-ify", "placeholdered", and "placeholdering". I left comments where I think we might want to change.

Also, I left a couple of nits/typos/minor comments.

subtyping, we recommend you read the paper). There are a few parts:

**TODO**: We should define _skolemize_.
**TODO**: We should define _placeholder_.
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we can remove this TODO and just link to the glossary?

We want the obligation `StaticInt : for<'a> Foo<&'a isize>` to be
considered unsatisfied. The check begins just as before. `'a` is
skolemized to `'0` and the impl trait reference is instantiated to
placeholder to `'0` and the impl trait reference is instantiated to
Copy link
Contributor

Choose a reason for hiding this comment

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

verb?

corresponds (intuitively) to some unknown set of other elements –
for details on skolemization, see the section
[skolemization and universes](#skol).
for details on placeholder, see the section
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
for details on placeholder, see the section
for details on placeholders, see the section

for details on skolemization, see the section
[skolemization and universes](#skol).
for details on placeholder, see the section
[placeholder and universes](#placeholder).
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
[placeholder and universes](#placeholder).
[placeholders and universes](#placeholder).


Here, the name `'b` is not part of the root universe. Instead, when we
"enter" into this `for<'b>` (e.g., by skolemizing it), we will create
"enter" into this `for<'b>` (e.g., by placeholder it), we will create
Copy link
Contributor

Choose a reason for hiding this comment

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

verb?

```

Here we would skolemize the supertype, as before, yielding:
Here we would placeholer the supertype, as before, yielding:
Copy link
Contributor

Choose a reason for hiding this comment

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

Typo:

Suggested change
Here we would placeholer the supertype, as before, yielding:
Here we would placeholder the supertype, as before, yielding:

Copy link
Contributor

Choose a reason for hiding this comment

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

verb?

first one. That is unsound. Let's see how it plays out.

First, we skolemize the supertype:
First, we placeholder the supertype:
Copy link
Contributor

Choose a reason for hiding this comment

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

verb?

1. The first thing we would do is to
skolemize the obligation, yielding `AnyInt : Foo<&'0 isize>` (here `'0`
represents skolemized region #0). Note that we now have no quantifiers;
placeholder the obligation, yielding `AnyInt : Foo<&'0 isize>` (here `'0`
Copy link
Contributor

Choose a reason for hiding this comment

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

verb?

@csmoe
Copy link
Contributor Author

csmoe commented Oct 25, 2018

@mark-i-m while re-review niko's PR, when talking about "placeholder-ify", the diff wrote "replace .. with placeholder" or "create/add placeholder". so I decide to follow his words, is this ok?
image

@csmoe csmoe force-pushed the placeholder branch 4 times, most recently from 2e1b236 to 659386f Compare October 25, 2018 03:15
Copy link
Contributor

@mark-i-m mark-i-m left a comment

Choose a reason for hiding this comment

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

Excellent! Thanks @csmoe.

LGTM. I left a few nits/minor changes. I tried to use Github's new suggestions feature. Let me know how it works. After that, r=me 😄

@mark-i-m mark-i-m mentioned this pull request Oct 25, 2018
mark-i-m and others added 4 commits October 25, 2018 11:33
Co-Authored-By: csmoe <csmoe@msn.com>
Co-Authored-By: csmoe <csmoe@msn.com>
Co-Authored-By: csmoe <csmoe@msn.com>
Co-Authored-By: csmoe <csmoe@msn.com>
@csmoe
Copy link
Contributor Author

csmoe commented Oct 25, 2018

r? @mark-i-m it works 😄

@mark-i-m mark-i-m merged commit 4196710 into rust-lang:master Oct 25, 2018
@mark-i-m
Copy link
Contributor

Thanks @csmoe 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants