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

add ices #1362

Merged
merged 1 commit into from
Jul 29, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions ices/99665-1.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
pub trait MyComponent {
type Properties;
}

impl<M> MyComponent for M
where
M: 'static,
{
type Properties = ();
}

fn main() {
|_: <&u8 as MyComponent>::Properties| {};
}
21 changes: 21 additions & 0 deletions ices/99665-2.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
pub trait MyComponent {
type Properties;
}

impl<M> MyComponent for M
where
M: 'static,
{
type Properties = TableProps<M>;
}

pub struct TableProps<M>
where
M: 'static,
{
pub entries: M,
}

fn main() {
|_: <&u32 as MyComponent>::Properties| {};
}
15 changes: 15 additions & 0 deletions ices/99734.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/bash

cat > out.rs <<'EOF'

pub use std::*;

pub mod task {}

pub fn main() {
println!("Hello, world!");
}

EOF

rustdoc out.rs
4 changes: 4 additions & 0 deletions ices/99777-1.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
pub fn test() {
#[doc(alias = "test")]
let num_flags = 0;
}
4 changes: 4 additions & 0 deletions ices/99777-2.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
pub fn test() {
#[doc(alias = "test")]
let num_flags = 0;
}
6 changes: 6 additions & 0 deletions ices/99777-3.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
fn main() {
match () {
#[doc(alias = "foo")]
_ => {}
}
}
19 changes: 19 additions & 0 deletions ices/99820.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#![feature(const_trait_impl)]
#![feature(fn_traits)]
#![feature(unboxed_closures)]

struct Closure;

impl const FnOnce<&usize> for Closure {
type Output = usize;

extern "rust-call" fn call_once(self, arg: &usize) -> Self::Output {
*arg
}
}

enum Bug<T = [(); Closure.call_once(&0) ]> {
V(T),
}

fn main() {}
9 changes: 9 additions & 0 deletions ices/99828.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
fn get_iter(vec: &[i32]) -> impl Iterator<Item = {}> + '_ {
vec.iter()
}

fn main() {
let vec = Vec::new();
let mut iter = get_iter(&vec);
iter.next();
}