diff options
| author | Rémy Rakic <remy.rakic+github@gmail.com> | 2025-01-30 17:10:19 +0000 |
|---|---|---|
| committer | Rémy Rakic <remy.rakic+github@gmail.com> | 2025-01-30 17:10:19 +0000 |
| commit | 4fcae667d6ff477a274eaecc6437d8dc828b9265 (patch) | |
| tree | b9e4d71cf7b0a336508cca780ff7591ac1928f79 /tests/ui/recursion | |
| parent | 5a45ab9738330fb317d49e3594c2db5248b1e971 (diff) | |
| download | rust-4fcae667d6ff477a274eaecc6437d8dc828b9265.tar.gz rust-4fcae667d6ff477a274eaecc6437d8dc828b9265.zip | |
normalize long-type.txt in tests
this allows compare-mode to share the same subdirectory and removes differences due to that
Diffstat (limited to 'tests/ui/recursion')
| -rw-r--r-- | tests/ui/recursion/recursion.rs | 3 | ||||
| -rw-r--r-- | tests/ui/recursion/recursion.stderr | 6 |
2 files changed, 5 insertions, 4 deletions
diff --git a/tests/ui/recursion/recursion.rs b/tests/ui/recursion/recursion.rs index f3c633983b1..ce56fe974b7 100644 --- a/tests/ui/recursion/recursion.rs +++ b/tests/ui/recursion/recursion.rs @@ -1,6 +1,7 @@ //@ build-fail //@ compile-flags:-C overflow-checks=off -//@ normalize-stderr: ".nll/" -> "/" +// The regex below normalizes the long type file name to make it suitable for compare-modes. +//@ normalize-stderr: "'\$TEST_BUILD_DIR/.*\.long-type.txt'" -> "'$$TEST_BUILD_DIR/$$FILE.long-type.txt'" enum Nil {NilValue} struct Cons<T> {head:isize, tail:T} diff --git a/tests/ui/recursion/recursion.stderr b/tests/ui/recursion/recursion.stderr index 7a9f04d4bd6..cb9f67ba741 100644 --- a/tests/ui/recursion/recursion.stderr +++ b/tests/ui/recursion/recursion.stderr @@ -1,15 +1,15 @@ error: reached the recursion limit while instantiating `test::<Cons<Cons<Cons<Cons<Cons<...>>>>>>` - --> $DIR/recursion.rs:18:11 + --> $DIR/recursion.rs:19:11 | LL | _ => {test (n-1, i+1, Cons {head:2*i+1, tail:first}, Cons{head:i*i, tail:second})} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | note: `test` defined here - --> $DIR/recursion.rs:16:1 + --> $DIR/recursion.rs:17:1 | LL | fn test<T:Dot> (n:isize, i:isize, first:T, second:T) ->isize { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - = note: the full type name has been written to '$TEST_BUILD_DIR/recursion/recursion/recursion.long-type.txt' + = note: the full type name has been written to '$TEST_BUILD_DIR/$FILE.long-type.txt' error: aborting due to 1 previous error |
