rust-lang / lang-team

Home of the Rust lang team
http://lang-team.rust-lang.org/
Apache License 2.0
202 stars 48 forks source link

Meeting proposal: Rust Specification #179

Closed m-ou-se closed 1 year ago

m-ou-se commented 2 years ago

Summary

Let's talk about creating an official Rust specification.

Background reading

https://blog.m-ou.se/rust-standard/

Current situation

Languages like C and C++ are standardized. Rust is not. Standardization comes down to, basically:

  1. Having an accurate specification (a document)
  2. An (open?) process for evolution of the language
  3. Stability

Rust currently already has 2 and 3, but not 1.

For 1, we currently have:

These are currently all incomplete, and/or not a good source to rely on.

Things to discuss

It'd be wonderful if we had an official Rust specification, which is kept up to date and distributed together with each new release. (I suppose this would effectively mean completing/upgrading the Rust Reference.)

Questions to discuss:

About this issue

This issue corresponds to a lang-team design meeting proposal. It corresponds to a possible topic of discussion that may be scheduled for deeper discussion during one of our design meetings.

RalfJung commented 2 years ago

Another point to add to your list for (1): https://github.com/RalfJung/minirust.

RalfJung commented 2 years ago

Also FYI, some people are currently in the process of drafting an RFC for an "operational semantics team". It would probably make sense to have this meeting after that RFC was posted, since developing and maintaining a Rust specification will be the main goal of that team.

nikomatsakis commented 2 years ago

Also relevant: https://github.com/nikomatsakis/a-mir-formality

programmerjake commented 2 years ago

one thing i very much want Rust to avoid is ending up like ISO C++ where the standard's text is behind a paywall.

RalfJung commented 2 years ago

That will definitely not happen if I have any say in it.

nikomatsakis commented 2 years ago

Question I would want to start with:

What are the goals we aim to meet? (for which audience, and for which purpose)

nikomatsakis commented 2 years ago

Meeting scheduled for Jan Nov 16, pending confirmation of availability

EDIT: Typo.

chorman0773 commented 2 years ago

I'll be there. Rust implementors have a definate stake in it, so I also recommend that it be announced on (at the very least) the gcc-rust zulip. If that is fine, I'll notify them there.

Can you confirm Jan 16th, though? The hackmd for the planning meeting shows Nov 16th. January 16th also appears to be a monday.

RalfJung commented 2 years ago

Jan 16th won't work for me unfortunately.

gimbling-away commented 2 years ago

An interesting challenge for this specification would be type-inference. How would it be specified? Considering Rustc's type inference is always gradually improving and considering Rustc has some cases where it fails to infer types in cases where it should be able to.

rod-chapman commented 2 years ago

I assume you are all aware of the Ferrocene project and its effort to produce a reasonable language reference/specification? See https://github.com/ferrocene/specification

m-ou-se commented 2 years ago

Background reading

https://blog.m-ou.se/rust-standard/

Please make sure you all read this to make sure we all have the same context ^

m-ou-se commented 2 years ago

one thing i very much want Rust to avoid is ending up like ISO C++ where the standard's text is behind a paywall.

No worries, nobody wants that.

I assume you are all aware of the Ferrocene project and its effort to produce a reasonable language reference/specification?

Yes, it's already mentioned and linked in the meeting proposal above.

m-ou-se commented 2 years ago

Jan 16

That seems to be a typo. It's scheduled for november 16th.

RalfJung commented 2 years ago

Ah, that would work for me.

RalfJung commented 1 year ago

Also FYI, some people are currently in the process of drafting an RFC for an "operational semantics team". It would probably make sense to have this meeting after that RFC was posted, since developing and maintaining a Rust specification will be the main goal of that team.

FWIW the RFC has been posted recently: https://github.com/rust-lang/rfcs/pull/3346

scottmcm commented 1 year ago

Meeting happened 2022-11-16; there's likely going to be a post from @m-ou-se as follow-up.

m-ou-se commented 1 year ago

RFC: https://github.com/rust-lang/rfcs/pull/3355