forked from rust-lang/glacier
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b23dfaa
commit 2526894
Showing
3 changed files
with
38 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
pub fn ice( | ||
x: impl AsRef<str>, | ||
) -> impl IntoIterator<Item = ()> { | ||
vec![].append(&mut ice(x.as_ref())); | ||
|
||
Vec::new() | ||
} | ||
|
||
fn main() { | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
pub trait Trait { | ||
type Fut<'a> where Self: 'a; | ||
fn fun<'a, 'b>(&'a self, x: &'_ mut &'b ()) -> Self::Fut<'a> | ||
where | ||
'b: 'a; | ||
} | ||
impl Trait for () { | ||
type Fut<'a> = impl ::std::future::Future + 'a | ||
where | ||
Self: 'a; | ||
fn fun<'a, 'b>(&'a self, x: &'_ mut &'b ()) -> Self::Fut<'a> | ||
where | ||
'b: 'a, | ||
{ | ||
async { } | ||
} | ||
} | ||
|
||
pub fn main() {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#![feature(core_intrinsics)] | ||
|
||
pub fn wrapping<T: Copy>(a: T, b: T) { | ||
let _z = core::intrinsics::wrapping_mul(a, b); | ||
} | ||
|
||
pub fn main() { | ||
wrapping(1,2); | ||
} |