From cf94bdc0742c13e2a0cac864c478b8626b266e1b Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:11:38 +0200 Subject: Merging upstream version 1.66.0+dfsg1. Signed-off-by: Daniel Baumann --- .../ui/rfc-2632-const-trait-impl/call-generic-method-nonconst.rs | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src/test/ui/rfc-2632-const-trait-impl/call-generic-method-nonconst.rs') diff --git a/src/test/ui/rfc-2632-const-trait-impl/call-generic-method-nonconst.rs b/src/test/ui/rfc-2632-const-trait-impl/call-generic-method-nonconst.rs index d3e14a53a..414a8c87d 100644 --- a/src/test/ui/rfc-2632-const-trait-impl/call-generic-method-nonconst.rs +++ b/src/test/ui/rfc-2632-const-trait-impl/call-generic-method-nonconst.rs @@ -2,13 +2,18 @@ struct S; -impl PartialEq for S { +#[const_trait] +trait Foo { + fn eq(&self, _: &Self) -> bool; +} + +impl Foo for S { fn eq(&self, _: &S) -> bool { true } } -const fn equals_self(t: &T) -> bool { +const fn equals_self(t: &T) -> bool { true } -- cgit v1.2.3