diff options
| author | Nicholas Nethercote <n.nethercote@gmail.com> | 2024-06-03 17:35:56 +1000 |
|---|---|---|
| committer | Nicholas Nethercote <n.nethercote@gmail.com> | 2024-06-04 14:15:06 +1000 |
| commit | c6fb703c05a47a7f20c59c5315fe704c536084d0 (patch) | |
| tree | 08d610a0b2d7fb99c745ae61f36d3cb685b62094 /tests/rustdoc-js/tuple-unit.rs | |
| parent | 98d65d62c511777d6372ae0115d40f82d0a42857 (diff) | |
| download | rust-c6fb703c05a47a7f20c59c5315fe704c536084d0.tar.gz rust-c6fb703c05a47a7f20c59c5315fe704c536084d0.zip | |
rustfmt `tests/rustdoc-js/`.
Diffstat (limited to 'tests/rustdoc-js/tuple-unit.rs')
| -rw-r--r-- | tests/rustdoc-js/tuple-unit.rs | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/tests/rustdoc-js/tuple-unit.rs b/tests/rustdoc-js/tuple-unit.rs index 93f9a671cbc..4531545cf6c 100644 --- a/tests/rustdoc-js/tuple-unit.rs +++ b/tests/rustdoc-js/tuple-unit.rs @@ -3,16 +3,24 @@ pub struct Q; pub struct R<T>(T); // Checks that tuple and unit both work -pub fn side_effect() { } +pub fn side_effect() {} // Check a non-tuple -pub fn not_tuple() -> P { loop {} } +pub fn not_tuple() -> P { + loop {} +} // Check a 1-tuple -pub fn one() -> (P,) { loop {} } +pub fn one() -> (P,) { + loop {} +} // Check a 2-tuple -pub fn two() -> (P,P) { loop {} } +pub fn two() -> (P, P) { + loop {} +} // Check a nested tuple -pub fn nest() -> (Q, R<(u32,)>) { loop {} } +pub fn nest() -> (Q, R<(u32,)>) { + loop {} +} |
