diff options
| author | Oli Scherer <git-spam-no-reply9815368754983@oli-obk.de> | 2022-02-17 13:28:06 +0000 |
|---|---|---|
| committer | Oli Scherer <git-spam-no-reply9815368754983@oli-obk.de> | 2022-03-28 16:57:45 +0000 |
| commit | 1163aa7e72bc69b76cb68177fa4f83a66a6034cc (patch) | |
| tree | c3ffe7ad686652f0fb9643350bd3c2d1fc1d803e /src/test/ui/parser/fn-header-semantic-fail.rs | |
| parent | 86e1860495403ee0154608e51fe4b4d81203e15f (diff) | |
| download | rust-1163aa7e72bc69b76cb68177fa4f83a66a6034cc.tar.gz rust-1163aa7e72bc69b76cb68177fa4f83a66a6034cc.zip | |
Remove opaque type obligation and just register opaque types as they are encountered.
This also registers obligations for the hidden type immediately.
Diffstat (limited to 'src/test/ui/parser/fn-header-semantic-fail.rs')
| -rw-r--r-- | src/test/ui/parser/fn-header-semantic-fail.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/test/ui/parser/fn-header-semantic-fail.rs b/src/test/ui/parser/fn-header-semantic-fail.rs index cf5d3dab4aa..c2954868f78 100644 --- a/src/test/ui/parser/fn-header-semantic-fail.rs +++ b/src/test/ui/parser/fn-header-semantic-fail.rs @@ -27,6 +27,7 @@ fn main() { struct Y; impl X for Y { async fn ft1() {} //~ ERROR functions in traits cannot be declared `async` + //~^ ERROR impl has stricter requirements than trait unsafe fn ft2() {} // OK. const fn ft3() {} //~ ERROR functions in traits cannot be declared const extern "C" fn ft4() {} @@ -35,6 +36,7 @@ fn main() { //~| ERROR functions in traits cannot be declared const //~| ERROR functions cannot be both `const` and `async` //~| ERROR cycle detected + //~| ERROR impl has stricter requirements than trait } impl Y { |
