Sign in
chromium
/
external
/
github.com
/
rust-lang
/
rust
/
ab1f382ca8fa4a4c0dde58679207f9bec394fa0e
/
.
/
tests
/
ui
/
traits
/
const-traits
/
call-generic-method-fail.rs
blob: 66881334a2985e08416407fbf4177fd2c2dca975 [
file
] [
log
] [
blame
]
//@ compile-flags: -Znext-solver
#![
feature
(
const_trait_impl
)]
pub
const
fn
equals_self
<
T
:
PartialEq
>(
t
:
&
T
)
->
bool
{
*
t
==
*
t
//~^ ERROR cannot call non-const operator in constant functions
}
fn
main
()
{}