Skip to content
This repository has been archived by the owner on May 23, 2024. It is now read-only.

Commit

Permalink
Merge pull request #1321 from matthiaskrgr/28
Browse files Browse the repository at this point in the history
add 3 ices
  • Loading branch information
Alexendoo committed Jun 28, 2022
2 parents 3ba4c2b + 0210854 commit 29a2588
Show file tree
Hide file tree
Showing 3 changed files with 62 additions and 0 deletions.
26 changes: 26 additions & 0 deletions ices/98594.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#!/bin/bash

rustc -Zverbose - <<'EOF'
#![allow(unused_parens)]
trait Foo {
type Assoc;
}
fn called()
where
for<'b> fn(&'b ()): Foo,
{
}
fn caller()
where
(for<'a> fn(&'a ())): Foo,
{
called()
}
fn main() {}
EOF

19 changes: 19 additions & 0 deletions ices/98598.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
pub trait Foo {
type Output: Foo;

fn baz() -> Self::Output;
}

pub struct Bar;

impl Foo for &Bar {
type Output = Bar;

fn baz() -> Self::Output {
Foo::baz();

Self::Output {}
}
}

pub fn main() {}
17 changes: 17 additions & 0 deletions ices/98604.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/bash

rustc --edition=2021 - <<'EOF'
type AsyncFnPtr = Box<
dyn Fn() -> std::pin::Pin<Box<dyn std::future::Future<Output = ()>>>,
>;
async fn test() {}
#[allow(unused_must_use)]
fn main() {
Box::new(test) as AsyncFnPtr;
}
EOF

0 comments on commit 29a2588

Please sign in to comment.