diff options
| author | Oli Scherer <github333195615777966@oli-obk.de> | 2025-03-11 12:08:45 +0000 |
|---|---|---|
| committer | Oli Scherer <github333195615777966@oli-obk.de> | 2025-06-26 13:46:45 +0000 |
| commit | eb7245a864613f290c5668f4f4e8376edd065dc6 (patch) | |
| tree | c31fc679f821ab1d469de7324a71d91f72787cbb /src/tools/rustfmt/tests/source | |
| parent | 18f4cb11108bbb3119d4ba2a7eb06c80adf6a438 (diff) | |
| download | rust-eb7245a864613f290c5668f4f4e8376edd065dc6.tar.gz rust-eb7245a864613f290c5668f4f4e8376edd065dc6.zip | |
Change const trait bound syntax from ~const to [const]
Diffstat (limited to 'src/tools/rustfmt/tests/source')
| -rw-r--r-- | src/tools/rustfmt/tests/source/type.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/tools/rustfmt/tests/source/type.rs b/src/tools/rustfmt/tests/source/type.rs index 7a232f85198..213fad7cb16 100644 --- a/src/tools/rustfmt/tests/source/type.rs +++ b/src/tools/rustfmt/tests/source/type.rs @@ -142,18 +142,18 @@ type MyFn = fn(a: SomeLongComplexType, b: SomeOtherLongComplexType,) -> Box<Futu // Const bound -trait T: ~ const Super {} +trait T: [ const ] Super {} -const fn not_quite_const<S: ~ const T>() -> i32 { <S as T>::CONST } +const fn not_quite_const<S: [ const ] T>() -> i32 { <S as T>::CONST } -impl ~ const T {} +impl const T for U {} -fn apit(_: impl ~ const T) {} +fn apit(_: impl [ const ] T) {} -fn rpit() -> impl ~ const T { S } +fn rpit() -> impl [ const] T { S } pub struct Foo<T: Trait>(T); -impl<T: ~ const Trait> Foo<T> { +impl<T: [ const] Trait> Foo<T> { fn new(t: T) -> Self { Self(t) } |
