Stream: wg-async-foundations

Topic: weekly meeting 2019.05.07


Taylor Cramer (May 07 2019 at 17:01, on Zulip):

o/ @WG-async-await

centril (May 07 2019 at 17:01, on Zulip):

o/

Taylor Cramer (May 07 2019 at 17:02, on Zulip):

This last week we had a few issues due to the argument desugaring change to fix drop order. I think the last of those are covered by https://github.com/rust-lang/rust/pull/60535

Taylor Cramer (May 07 2019 at 17:03, on Zulip):

@davidtwco have you had a chance to finish reviewing it? I saw you and @eddyb discussing some additional changes you wanted to make

davidtwco (May 07 2019 at 17:03, on Zulip):

Here's a quick update on my #t-compiler/wg-async-await things from the last week:

Taylor Cramer (May 07 2019 at 17:03, on Zulip):

(moving construct_async_arguments to lowering rather than parsing)

davidtwco (May 07 2019 at 17:03, on Zulip):

davidtwco have you had a chance to finish reviewing it? I saw you and eddyb discussing some additional changes you wanted to make

I think that was a longer-term idea. We should land it w/out that. It looks good to me.

centril (May 07 2019 at 17:03, on Zulip):

@Taylor Cramer @nikomatsakis One thing that was done with the const-generics effort was to make a public call for tests; I think it would be good to do that here also particularly as I feel they are lacking and because it is more time sensitive

Taylor Cramer (May 07 2019 at 17:04, on Zulip):

@davidtwco Okay, thanks for the update-- I'll r+ then

Taylor Cramer (May 07 2019 at 17:05, on Zulip):

@centril What is the process you were imagining around that (esp. around getting diverse tests, rather than a lot of code that tests the same interaction of a few features)

Taylor Cramer (May 07 2019 at 17:05, on Zulip):

e.g. having argument-position impl trait tests, things returning trait objects, etc. would've been helpful

centril (May 07 2019 at 17:06, on Zulip):

@Taylor Cramer The WG would filter out duplicates; but variations of the same is a good thing

Taylor Cramer (May 07 2019 at 17:06, on Zulip):

but those are less likely to appear in a random test suite unless it occurs to someone to check that

centril (May 07 2019 at 17:06, on Zulip):

redundancy in testing is essential

centril (May 07 2019 at 17:06, on Zulip):

maybe ask folks to think of exotic things

Taylor Cramer (May 07 2019 at 17:06, on Zulip):

hm, I'm not sure I agree that more tests is necessarily better, but I think it isn't harmful in this case since we're drawing close to release time

centril (May 07 2019 at 17:06, on Zulip):

and write tests for combinatorial interactions

Taylor Cramer (May 07 2019 at 17:06, on Zulip):

(like, I would've pushed back against it while we were still on the old syntax e.g.)

centril (May 07 2019 at 17:07, on Zulip):

@Taylor Cramer it's all about covering much of the search space and doing good input space partitioning

Taylor Cramer (May 07 2019 at 17:07, on Zulip):

But okay, that sounds like a good idea-- did you want to try and solicit internals + reddit?

centril (May 07 2019 at 17:08, on Zulip):

I was thinking that if Niko did it on e.g. their blog post it would be most effective that way

nikomatsakis (May 07 2019 at 17:08, on Zulip):

I think it's a great idea, but I think there is some amount of "legwork"

nikomatsakis (May 07 2019 at 17:08, on Zulip):

i.e., putting out the call for tests

davidtwco (May 07 2019 at 17:08, on Zulip):

I forget whether we did something similar with NLL.

nikomatsakis (May 07 2019 at 17:08, on Zulip):

and trying to "structure" it

centril (May 07 2019 at 17:09, on Zulip):

oh sure; ultimately we need the tests tho :slight_smile:

nikomatsakis (May 07 2019 at 17:09, on Zulip):

well, what I mean is, don't you want to do that as part of the call? Or are you just imaging people saying "send me all your tests and centril will sort them"

nikomatsakis (May 07 2019 at 17:09, on Zulip):

I was sort of imagining making a list of features and people could sign themselves up

centril (May 07 2019 at 17:09, on Zulip):

@nikomatsakis ah I see what you mean

Taylor Cramer (May 07 2019 at 17:09, on Zulip):

I think @centril is making the good point that we wouldn't necessarily know all hte features to ask for people to test

nikomatsakis (May 07 2019 at 17:09, on Zulip):

"quest issue" style

centril (May 07 2019 at 17:10, on Zulip):

@nikomatsakis so I think both are valuable

nikomatsakis (May 07 2019 at 17:10, on Zulip):

indeed, and I agree with @centril's point that sometimes it's "random variations" that find the most bugs

centril (May 07 2019 at 17:10, on Zulip):

i.e. make a list but also ask for creative tests for unexpected things

nikomatsakis (May 07 2019 at 17:10, on Zulip):

I guess I'm mostly saying "I'm feeling pressed for time as is and hadn't necessarily planned on more blog posts" :) but if you want me to write something brief, perhaps linking over to an internals thread or something, I'd be happy to do so

centril (May 07 2019 at 17:11, on Zulip):

@nikomatsakis that would be great

centril (May 07 2019 at 17:11, on Zulip):

I also think this deserves prioritization so if other things (e.g. chalk) need to be deprioritized then so be it :slight_smile:

nikomatsakis (May 07 2019 at 17:12, on Zulip):

Probably so

Taylor Cramer (May 07 2019 at 17:12, on Zulip):

Okay, sounds like we have a plan there, then?

nikomatsakis (May 07 2019 at 17:12, on Zulip):

One question is: @centril will you (or someone) create an internals thread first that I can link to?

Taylor Cramer (May 07 2019 at 17:12, on Zulip):

(although perhaps it should wait until the new syntax PR lands so folks can provide tests that match the behavior there?)

nikomatsakis (May 07 2019 at 17:13, on Zulip):

ah, probably

centril (May 07 2019 at 17:13, on Zulip):

@Taylor Cramer sure; how much time do you expect that will take?

nikomatsakis (May 07 2019 at 17:13, on Zulip):

I suppose this also couples as a way to "try out" the new syntax

centril (May 07 2019 at 17:13, on Zulip):

the PR seems pretty solid aside from some minor things

davidtwco (May 07 2019 at 17:13, on Zulip):

Is there a PR up for the new syntax?

centril (May 07 2019 at 17:14, on Zulip):

@davidtwco https://github.com/rust-lang/rust/pull/60586

davidtwco (May 07 2019 at 17:14, on Zulip):

Thanks, must have missed that.

Taylor Cramer (May 07 2019 at 17:14, on Zulip):

@centril An hour today for me to fix up the issues and run tests locally then however long additionally it takes to get through the queue

Taylor Cramer (May 07 2019 at 17:14, on Zulip):

plus whatever delay until the next nightly

centril (May 07 2019 at 17:14, on Zulip):

@Taylor Cramer how about @bors p=50 ;)

Taylor Cramer (May 07 2019 at 17:15, on Zulip):

lol

nikomatsakis (May 07 2019 at 17:15, on Zulip):

I'd be ok w/ p=1

nikomatsakis (May 07 2019 at 17:16, on Zulip):

on the premise of "trying to hit release targets, wanting as much time as possible for things to shake out"

Taylor Cramer (May 07 2019 at 17:16, on Zulip):

@davidtwco I forgot to ask-- would the expected return type issues you were discussing w/ @eddyb also fix the issue where returning a trait object doesn't coerce properly?

centril (May 07 2019 at 17:16, on Zulip):

@nikomatsakis It's practically the same; if we have something super urgent we will just p=1000 that thing or something ^^

Taylor Cramer (May 07 2019 at 17:16, on Zulip):

I would've guessed it would, but perhaps I should open an issue to ensure there's a test if there isn't already an existing issue

davidtwco (May 07 2019 at 17:16, on Zulip):

davidtwco I forgot to ask-- would the expected return type issues you were discussing w/ eddyb also fix the issue where returning a trait object doesn't coerce properly?

I'm not sure, I don't have a good understanding of what's going on there yet, just that it's terrifying.

eddyb (May 07 2019 at 17:16, on Zulip):

I have no idea what the trait object thing is

eddyb (May 07 2019 at 17:17, on Zulip):

but since coercion is involved, I would expect not

nikomatsakis (May 07 2019 at 17:17, on Zulip):

Oh, was this the #54326 questions?

nikomatsakis (May 07 2019 at 17:17, on Zulip):

I saw that ping but didn't understand it yet

eddyb (May 07 2019 at 17:17, on Zulip):

like, we can only improve the situation in cases where we can be sure coercions can't happen :P

centril (May 07 2019 at 17:17, on Zulip):

@nikomatsakis ah; so your thinking was that I'd write up some list of features on internals or will you do that?

Taylor Cramer (May 07 2019 at 17:17, on Zulip):

@eddyb this thing: async fn foo() -> Box<dyn Foo> { Box::new(SomeFoo) } doesn't coerce

davidtwco (May 07 2019 at 17:17, on Zulip):

trait object thing being #60424?

eddyb (May 07 2019 at 17:17, on Zulip):

oh actually, nevermind, we would fix that

nikomatsakis (May 07 2019 at 17:18, on Zulip):

ah; so your thinking was that I'd write up some list of features on internals or will you do that?

I'd like to clarify who will do it, I suppose :)

Taylor Cramer (May 07 2019 at 17:18, on Zulip):

@davidtwco yup, thanks for the issue pointer, I couldn't remember where it was

eddyb (May 07 2019 at 17:18, on Zulip):

right, because the non-coercion return is that of the "future from generator" wrapper expression

centril (May 07 2019 at 17:18, on Zulip):

@nikomatsakis How about we iterate on it together?

eddyb (May 07 2019 at 17:19, on Zulip):

the drop order stuff came up before, sorry I didn't reply in time, didn't realize this was a meeting

the gist of it is that I'm working on killing Res::Upvar so that the logic can be cleaned up a bit and not require the entire frontend to know about the transformation

eddyb (May 07 2019 at 17:19, on Zulip):

but that cleanup doesn't need to block anything

Taylor Cramer (May 07 2019 at 17:20, on Zulip):

Okay- aside from the syntax PR, I think the only remaining issue is the multiple lifetimes one and @tmandry's stuff

Taylor Cramer (May 07 2019 at 17:20, on Zulip):

I've been looking at the resolve code to try and figure out how to insert the in constraints @nikomatsakis described

centril (May 07 2019 at 17:20, on Zulip):

@Taylor Cramer I'm pretty excited about your syntax PR for a different reason: it simplifies the work to preallocate lang_items in lowering so we don't refer to things by path.

Taylor Cramer (May 07 2019 at 17:21, on Zulip):

I'll admit I'm finding that codebase a bit daunting

Taylor Cramer (May 07 2019 at 17:21, on Zulip):

@centril yeah I saw that-- I'm interested to see how that goes

centril (May 07 2019 at 17:21, on Zulip):

@Taylor Cramer I'm gonna do some exploration :slight_smile:

Taylor Cramer (May 07 2019 at 17:21, on Zulip):

In particular, curious about the no-std vs. with-std handling

Taylor Cramer (May 07 2019 at 17:22, on Zulip):

@tmandry do you have any updates? it seems like you and @Zoxc have been having quite a bit of back-and-forth

centril (May 07 2019 at 17:23, on Zulip):

@Taylor Cramer also, before we do any requests for tests, it would be good if we move the tests to their own folder

centril (May 07 2019 at 17:23, on Zulip):

so we get all new test PRs to there

tmandry (May 07 2019 at 17:23, on Zulip):

@Taylor Cramer Yeah I need to do some revisions on the PR

tmandry (May 07 2019 at 17:24, on Zulip):

I think @Zoxc and I mostly agree actually

centril (May 07 2019 at 17:24, on Zulip):

well do you guys agree with @eddyb yet? :P

tmandry (May 07 2019 at 17:25, on Zulip):

most of my collaboration in working on the PR was with @eddyb

tmandry (May 07 2019 at 17:25, on Zulip):

a lot of the back-and-forth is because I didn't communicate any of that when I posted the PR

tmandry (May 07 2019 at 17:25, on Zulip):

so, I'm taking care of that now :)

tmandry (May 07 2019 at 17:26, on Zulip):

plus some changes that need to be made

nikomatsakis (May 07 2019 at 17:27, on Zulip):

I've been looking at the resolve code to try and figure out how to insert the in constraints nikomatsakis described

@Taylor Cramer I might be able to carve out time to try and do that, if needed.

centril (May 07 2019 at 17:27, on Zulip):

PSA: If anyone wants to r+ a PR in the next few minutes I'm making a rollup atm rollup was made.

Taylor Cramer (May 07 2019 at 17:29, on Zulip):

@nikomatsakis okay-- I'll keep trying, but so far I've gotten as far as "add a field with a mapping from regions to region sets that they must be in" and then trying to figure out how to actually do anything with those has been beyond me. Probably I just need to gain familiarity with the rest of the lifetime inference code, but it's a bit hard to get started

Taylor Cramer (May 07 2019 at 17:29, on Zulip):

there's just a lot of stuff going on :)

nikomatsakis (May 07 2019 at 17:30, on Zulip):

There...is

centril (May 07 2019 at 17:32, on Zulip):

Have to run; :wave:

repjarms (May 07 2019 at 17:33, on Zulip):

Hey guys, I wanted to post on the back end of the meeting here and just say that I am interested in helping out however I can. With the caveat that I'm a new contributor and so there's a start up penalty to my effectiveness currently :)

tmandry (May 07 2019 at 17:37, on Zulip):

plus some changes that need to be made

actually @Zoxc had a better intuition for how to structure this than I did, I'm going to go with their approach and move some logic into the layout computation

repjarms (May 07 2019 at 18:22, on Zulip):

@centril Id be interested in helping out with test coverage in the ensuing call for tests. That should help me get up to speed on the logic with the feature too

centril (May 07 2019 at 18:23, on Zulip):

@repjarms that would be sweet :slight_smile:

nikomatsakis (May 07 2019 at 18:26, on Zulip):

Ah, great

Last update: Nov 18 2019 at 00:50UTC