Skip to content

Commit 7a7a28d

Browse files
committed
Fixed file formatting and made tidy happy
1 parent d89d2a9 commit 7a7a28d

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

src/test/ui/const-generics/issues/issue-63322-forbid-dyn.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ impl A for B {}
99

1010
fn test<const T: &'static dyn A>() {
1111
//[full]~^ ERROR must be annotated with `#[derive(PartialEq, Eq)]` to be used
12-
//[min]~^^ ERROR `&'static (dyn A + 'static)` is forbidden as the type of a const generic parameter
12+
//[min]~^^ ERROR `&'static (dyn A + 'static)` is forbidden as the type of
13+
// a const generic parameter
1314
//[min]~| ERROR must be annotated with `#[derive(PartialEq, Eq)]` to be used
1415
unimplemented!()
1516
}

src/test/ui/const-generics/std/const-generics-range.min.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ LL | struct _RangeInclusive<const R: std::ops::RangeInclusive<usize>>;
3535
= note: more complex types are supported with `#[feature(const_generics)]`
3636

3737
error: `std::ops::RangeTo<usize>` is forbidden as the type of a const generic parameter
38-
--> $DIR/const-generics-range.rs:29:26
38+
--> $DIR/const-generics-range.rs:30:26
3939
|
4040
LL | struct _RangeTo<const R: std::ops::RangeTo<usize>>;
4141
| ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -44,7 +44,7 @@ LL | struct _RangeTo<const R: std::ops::RangeTo<usize>>;
4444
= note: more complex types are supported with `#[feature(const_generics)]`
4545

4646
error: `std::ops::RangeToInclusive<usize>` is forbidden as the type of a const generic parameter
47-
--> $DIR/const-generics-range.rs:34:35
47+
--> $DIR/const-generics-range.rs:35:35
4848
|
4949
LL | struct _RangeToInclusive<const R: std::ops::RangeToInclusive<usize>>;
5050
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

src/test/ui/const-generics/std/const-generics-range.rs

+4-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ const RANGE_FULL : _RangeFull<{ .. }> = _RangeFull;
2222
// Regression test for #70155
2323
// `RangeInclusive` should be usable within const generics:
2424
struct _RangeInclusive<const R: std::ops::RangeInclusive<usize>>;
25-
//[min]~^ ERROR `std::ops::RangeInclusive<usize>` is forbidden as the type of a const generic parameter
25+
//[min]~^ ERROR `std::ops::RangeInclusive<usize>` is forbidden as the type of a const generic
26+
// parameter
2627
const RANGE_INCLUSIVE : _RangeInclusive<{ 0 ..= 999 }> = _RangeInclusive;
2728

2829
// `RangeTo` should be usable within const generics:
@@ -32,7 +33,8 @@ const RANGE_TO : _RangeTo<{ .. 1000 }> = _RangeTo;
3233

3334
// `RangeToInclusive` should be usable within const generics:
3435
struct _RangeToInclusive<const R: std::ops::RangeToInclusive<usize>>;
35-
//[min]~^ ERROR `std::ops::RangeToInclusive<usize>` is forbidden as the type of a const generic parameter
36+
//[min]~^ ERROR `std::ops::RangeToInclusive<usize>` is forbidden as the type of a const generic
37+
// parameter
3638
const RANGE_TO_INCLUSIVE : _RangeToInclusive<{ ..= 999 }> = _RangeToInclusive;
3739

3840
pub fn main() {}

0 commit comments

Comments
 (0)