facebook / sapling

A Scalable, User-Friendly Source Control System.
https://sapling-scm.com
GNU General Public License v2.0
6.07k stars 275 forks source link

Add missing `Eq`. #883

Closed zadlg closed 5 months ago

zadlg commented 5 months ago

Add missing Eq.

Running rustc == 1.76.0.

The following error was occurring:

error: to use a constant of type `FetchMode` in a pattern, `FetchMode` must be annotated with `#[derive(PartialEq, Eq)]`
   --> lib/revisionstore/src/scmstore/tree.rs:261:20
    |
261 |             if let FetchMode::AllowRemote = fetch_mode {
    |                    ^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: the traits must be derived, manual `impl`s are not sufficient
    = note: see https://doc.rust-lang.org/stable/std/marker/trait.StructuralEq.html for details
error: could not compile `revisionstore` (lib) due to 1 previous error; 1 warning emitted
facebook-github-bot commented 5 months ago

@facebook-github-bot has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 5 months ago

@zadlg has updated the pull request. You must reimport the pull request before landing.

facebook-github-bot commented 5 months ago

@facebook-github-bot has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 5 months ago

@zadlg has updated the pull request. You must reimport the pull request before landing.

facebook-github-bot commented 5 months ago

@facebook-github-bot has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 5 months ago

This pull request has been merged in facebook/sapling@607fb678cec9870a8a077e2c88500bec0e5fd443.

zzl0 commented 5 months ago

@zadlg thanks for fixing it