Skip to content

allow incomplete_features in UI tests #974

@cyrgani

Description

@cyrgani

Proposal

The UI test suite already allows several lints by default, such as unused lints or internal_features, because a lot of tests would trigger them and distract from the actual purpose of the test. However, the incomplete_features lint is not yet allowed. This has two drawbacks:

  1. PRs that mark a feature as "no longer incomplete" need to update a lot of test files to no longer contain #![expect(incomplete_features)] or //~ WARN the feature ... is incomplete, which is annoying (example: stop marking deref_patterns as an incomplete feature rust#153053)
  2. There are quite a few tests that are marked as check/build/run-pass that still have a .stderr file that contains nothing more than the warning: the feature ... is incomplete and may not be safe to use and/or cause compiler crashes warning.

Therefore, I propose to also allow incomplete_features for all UI tests by default and only add #![warn(incomplete_features)] to tests that are specifically about emitting the warning for a feature.

Mentors or Reviewers

I am willing to make a PR that allows the lint for tests/ui and updates the affected test files.

Process

The main points of the Major Change Process are as follows:

  • File an issue describing the proposal.
  • A compiler team member who is knowledgeable in the area can second by writing @rustbot second or kickoff a team FCP with @rfcbot fcp $RESOLUTION.
  • Once an MCP is seconded, the Final Comment Period begins.
    • Final Comment Period lasts for 10 days after all outstanding concerns are solved.
    • Outstanding concerns will block the Final Comment Period from finishing. Once all concerns are resolved, the 10 day countdown is restarted.
    • If no concerns are raised after 10 days since the resolution of the last outstanding concern, the MCP is considered approved.

You can read more about Major Change Proposals on forge.

Note

Concerns (0 active)

Managed by @rustbot—see help for details.

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-compilerAdd this label so rfcbot knows to poll the compiler teammajor-changeA proposal to make a major change to rustcmajor-change-acceptedA major change proposal that was accepted

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions