2023-09-29 14:52:30 -05:00
|
|
|
pub struct P;
|
|
|
|
pub struct Q;
|
|
|
|
pub struct R<T>(T);
|
|
|
|
|
|
|
|
// Checks that tuple and unit both work
|
2024-06-03 02:35:56 -05:00
|
|
|
pub fn side_effect() {}
|
2023-09-29 14:52:30 -05:00
|
|
|
|
|
|
|
// Check a non-tuple
|
2024-06-03 02:35:56 -05:00
|
|
|
pub fn not_tuple() -> P {
|
|
|
|
loop {}
|
|
|
|
}
|
2023-09-29 14:52:30 -05:00
|
|
|
|
|
|
|
// Check a 1-tuple
|
2024-06-03 02:35:56 -05:00
|
|
|
pub fn one() -> (P,) {
|
|
|
|
loop {}
|
|
|
|
}
|
2023-09-29 14:52:30 -05:00
|
|
|
|
|
|
|
// Check a 2-tuple
|
2024-06-03 02:35:56 -05:00
|
|
|
pub fn two() -> (P, P) {
|
|
|
|
loop {}
|
|
|
|
}
|
2023-09-29 14:52:30 -05:00
|
|
|
|
|
|
|
// Check a nested tuple
|
2024-06-03 02:35:56 -05:00
|
|
|
pub fn nest() -> (Q, R<(u32,)>) {
|
|
|
|
loop {}
|
|
|
|
}
|