Stream: t-compiler/major changes

Topic: Add future-incompat entries to json diagno compiler-team#315


triagebot (Jun 19 2020 at 15:53, on Zulip):

A new proposal has been announced #315. It will be brought up at the next meeting.

pnkfelix (Jun 19 2020 at 15:56, on Zulip):

This is arguably a public facing feature, so it may require full FCP checkoff

nikomatsakis (Jun 19 2020 at 15:56, on Zulip):

Well, true, but we did affect approve the RFC

pnkfelix (Jun 19 2020 at 15:56, on Zulip):

approve it, you mean I assume

pnkfelix (Jun 19 2020 at 15:56, on Zulip):

there are some implementation details that are part of the public API

pnkfelix (Jun 19 2020 at 15:56, on Zulip):

speciifcally, the artifact work added a new flag

pnkfelix (Jun 19 2020 at 15:57, on Zulip):

--json, I think

pnkfelix (Jun 19 2020 at 15:57, on Zulip):

and that might be a good thing to use here to opt-into receiving this output

pnkfelix (Jun 19 2020 at 15:57, on Zulip):

rather than blindly piggy-backing it on every use of --error-format json

pnkfelix (Jun 19 2020 at 15:58, on Zulip):

but yeah, maybe full team checkoff is not necessary for that level of detail

nikomatsakis (Jun 19 2020 at 15:58, on Zulip):

I'm trying to think which people "own" the JSON output the most. I think @Esteban Küber perhaps, and I could imagine maybe @Vadim Petrochenkov

pnkfelix (Jun 19 2020 at 15:58, on Zulip):

anyway I was mostly eager to get this MCP posted, and the Zulip thread created, so that I could properly respond to @Aaron Hill 's volunteering to work on this on the tracking issue

pnkfelix (Jun 19 2020 at 15:59, on Zulip):

(that's an example of where we might want dedicated zulip threads for each tracking issue)

nikomatsakis (Jun 19 2020 at 15:59, on Zulip):

I think it would be reasonable to make a project group around this

pnkfelix (Jun 19 2020 at 15:59, on Zulip):

I definitely want to ask @Vadim Petrochenkov some questions

nikomatsakis (Jun 19 2020 at 15:59, on Zulip):

in fact I think it's a good idea

Esteban Küber (Jun 19 2020 at 15:59, on Zulip):

There's an overdue rework of the schema for json output

pnkfelix (Jun 19 2020 at 15:59, on Zulip):

specifically, I tried to use LintId as a way to build the entries of the allow-list

nikomatsakis (Jun 19 2020 at 15:59, on Zulip):

especially as a complete change involved cargo as well

Esteban Küber (Jun 19 2020 at 15:59, on Zulip):

We currently can't encode some things correctly

pnkfelix (Jun 19 2020 at 16:00, on Zulip):

but it didn't work at all, the equivalence check didn't work, and I don't know why it failed

pnkfelix (Jun 19 2020 at 16:00, on Zulip):

Esteban Küber said:

We currently can't encode some things correctly

can you speak more on this?

pnkfelix (Jun 19 2020 at 16:00, on Zulip):

nikomatsakis said:

I think it would be reasonable to make a project group around this

a project group for the json output in general? Or for report-future-incompat support?

pnkfelix (Jun 19 2020 at 16:01, on Zulip):

pnkfelix said:

but it didn't work at all, the equivalence check didn't work, and I don't know why it failed

(so I hacked it up using the lint names as the keys instead of LintIds. It was a total hack, though maybe an acceptable one...)

Esteban Küber (Jun 19 2020 at 16:01, on Zulip):

Multiple multi span suggestions are not representable and a single multipart suggestion is not distinguishable from multiple suggestions

nikomatsakis (Jun 19 2020 at 16:01, on Zulip):

pnkfelix said:

a project group for the json output in general? Or for report-future-incompat support?

the latter

Esteban Küber (Jun 19 2020 at 16:02, on Zulip):

This has been a blocker for rustfix for a year and a half

Esteban Küber (Jun 19 2020 at 16:02, on Zulip):

But I haven't focused on it

Vadim Petrochenkov (Jun 19 2020 at 16:17, on Zulip):

I don't know anything about this.

Vadim Petrochenkov (Jun 19 2020 at 16:18, on Zulip):

I'd ask cargo or rls people because they work with this json more than anyone else.

pnkfelix (Jun 19 2020 at 16:40, on Zulip):

@Vadim Petrochenkov do yo know anything about why I might have had problems with LintId? I believe you were the one who added that datatype, but maybe I misremember

pnkfelix (Jun 19 2020 at 16:41, on Zulip):

(if you need to see a concrete example of what was going wrong, I can post a diff against my prototype branch.)

pnkfelix (Jun 19 2020 at 16:42, on Zulip):

(it was in this bit of the code, though for now you'll have to just imagine the construction a LintId wrapping SAFE_PACKED_BORROWS rather than what its currently doing there, and then a corresponding edit two lines down to the .contains call)

pnkfelix (Jun 19 2020 at 16:44, on Zulip):

While I'm already making notes about this code, I also noted this semi-odd future-incompat lint, UNSTABLE_NAME_COLLISIONS, that has been marked that it should never be removed nor changed to an error.

pnkfelix (Jun 19 2020 at 16:44, on Zulip):

I was sort of wondering whether the future-incompat structure is the wrong tool for that job then

Vadim Petrochenkov (Jun 19 2020 at 16:51, on Zulip):

Here's the PR that added LintIds - https://github.com/rust-lang/rust/pull/15024

pnkfelix (Jun 19 2020 at 16:52, on Zulip):

whoops not you then, sorry!

Vadim Petrochenkov (Jun 19 2020 at 16:52, on Zulip):

I didn't work much with the lint infra in general.

pnkfelix (Jun 19 2020 at 16:53, on Zulip):

I must have had a serious M-x vc-annotate fail

triagebot (Jul 16 2020 at 14:06, on Zulip):

@T-compiler: Proposal #315 has been seconded, and will be approved in 10 days if no objections are raised.

Aaron Hill (Aug 13 2020 at 15:29, on Zulip):

@pnkfelix Now that the MCP has been accepted, what's the next step for this feature?

Last update: May 07 2021 at 07:00UTC