Skip to content

proposal: compiler warnings for deprecated / soon to be shutdown features and GOEXPERIMENTS #80975

Description

@nikolaydubina

Proposal Details

I know go maintainers do not care and will dismiss this proposal, as they usaully do. but adding this for collective history. (unless they will start removing discussions they do not like entirely).

go 1.27 fiasco with GOEXPERIMENTS=jsonv2 that dropped format tag is not good.

major reason why it makes especially bad is that people who opted-in DID NOT KNOW that the flag will be shut down in 4 months. unless you follow go threads or some personal blogs or all of the github issues, people do not even know that experiment is shut down.

other languages have compiler warning mechanism:

  • Kotlin has compiler deprecation warnings
  • Swift has compiler deprecation warnings
  • Rust has compiler deprecation warnings
  • Typescript has compiler deprecation warnings

Go does not.

if you have some expected change in behavior (particualrly important for GOEXPERIMENTS), there is no way for people who opted-in to be notified what is going on.

then suddenly, out of blue, you get your code crash. and maintainers just shrug "there is no compatibility promise. it is experiment."

right, but how people know what is going on with these experiments? not everybody is reading all threads / emails / zoom calls in what go core team is doing.

the fact that there is no notification / warnings static analysis mechanism is bonkers.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions