Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

regression: trait bound is not satisfied Cow/Borrow<str> #127339

Closed
Mark-Simulacrum opened this issue Jul 4, 2024 · 3 comments
Closed

regression: trait bound is not satisfied Cow/Borrow<str> #127339

Mark-Simulacrum opened this issue Jul 4, 2024 · 3 comments
Labels
E-needs-bisection Call for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustc P-high High priority regression-from-stable-to-beta Performance or correctness regression from stable to beta. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Milestone

Comments

@Mark-Simulacrum
Copy link
Member

Not clear what exactly has changed.

[INFO] [stdout] error[E0277]: the trait bound `for<'a> beef::generic::Cow<'a, str, beef::wide::internal::Wide>: Borrow<beef::generic::Cow<'_, str, lean::internal::Lean>>` is not satisfied
[INFO] [stdout]    --> src/page.rs:433:18
[INFO] [stdout]     |
[INFO] [stdout] 433 |             .get(template)
[INFO] [stdout]     |              --- ^^^^^^^^ the trait `for<'a> Borrow<beef::generic::Cow<'_, str, lean::internal::Lean>>` is not implemented for `beef::generic::Cow<'a, str, beef::wide::internal::Wide>`
[INFO] [stdout]     |              |
[INFO] [stdout]     |              required by a bound introduced by this call
[INFO] [stdout]     |
[INFO] [stdout]     = help: the trait `Borrow<str>` is implemented for `beef::generic::Cow<'_, str, beef::wide::internal::Wide>`
[INFO] [stdout]     = help: for that trait implementation, expected `str`, found `beef::generic::Cow<'_, str, lean::internal::Lean>`
[INFO] [stdout] note: required by a bound in `Ramhorns::<H>::get`
[INFO] [stdout]    --> /opt/rustwide/cargo-home/registry/src/index.crates.io-6f17d22bba15001f/ramhorns-0.14.0/src/lib.rs:206:31
[INFO] [stdout]     |
[INFO] [stdout] 204 |     pub fn get<S>(&self, name: &S) -> Option<&Template<'static>>
[INFO] [stdout]     |            --- required by a bound in this associated function
[INFO] [stdout] 205 |     where
[INFO] [stdout] 206 |         for<'a> Cow<'a, str>: std::borrow::Borrow<S>,
[INFO] [stdout]     |                               ^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `Ramhorns::<H>::get`
@Mark-Simulacrum Mark-Simulacrum added T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. regression-from-stable-to-beta Performance or correctness regression from stable to beta. E-needs-bisection Call for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustc labels Jul 4, 2024
@Mark-Simulacrum Mark-Simulacrum added this to the 1.80.0 milestone Jul 4, 2024
@rustbot rustbot added I-prioritize Issue: Indicates that prioritization has been requested for this issue. needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. labels Jul 4, 2024
@compiler-errors
Copy link
Member

This is #119820, cc @lcnr (though we probably already have this listed as a regression in that one)

@apiraino
Copy link
Contributor

apiraino commented Jul 5, 2024

From me, assigning priority with same reasoning as for #127342

WG-prioritization assigning priority (Zulip discussion).

@rustbot label -I-prioritize +P-high

@rustbot rustbot added P-high High priority and removed I-prioritize Issue: Indicates that prioritization has been requested for this issue. labels Jul 5, 2024
@apiraino
Copy link
Contributor

IIUC this is now fixed by #127568 (now beta-backported).

If yes, I think this issue can be closed

@lcnr lcnr closed this as completed Jul 18, 2024
@jieyouxu jieyouxu removed the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Jul 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
E-needs-bisection Call for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustc P-high High priority regression-from-stable-to-beta Performance or correctness regression from stable to beta. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

6 participants