Matthias Krüger e52fbff5e8
Rollup merge of #111525 - scottmcm:slice-position-tweak, r=Mark-Simulacrum
Stop checking for the absence of something that doesn't exist

A couple of codegen tests are doing
```
// CHECK-NOT: slice_index_len_fail
```

However, that function no longer exists: [the only places](https://github.com/search?q=repo%3Arust-lang%2Frust+slice_index_len_fail&type=code) it occurs in the repo are in those tests.

So this PR updates the tests to check for the absense of the functions that are actually used today to panic for out-of-bounds indexing.
2023-05-15 17:12:45 +02:00
..
2023-03-20 10:25:29 +00:00
2023-01-17 16:23:22 +01:00
2023-01-11 20:42:13 -05:00
2023-01-17 16:23:22 +01:00
2023-01-17 16:23:22 +01:00
2023-03-16 15:07:04 +01:00
2023-05-03 22:09:33 -07:00
2023-01-17 16:23:22 +01:00
2023-01-11 09:32:08 +00:00
2023-04-14 16:26:11 +00:00
2023-05-08 03:55:41 -07:00
2023-01-17 16:23:22 +01:00
2023-04-30 00:06:26 +08:00
2023-01-17 16:23:22 +01:00
2023-05-08 03:55:41 -07:00
2023-02-14 19:21:58 -05:00
2023-01-17 16:23:22 +01:00
2023-05-08 03:55:41 -07:00
2023-04-17 09:16:07 +02:00
2023-01-17 16:23:22 +01:00
2023-01-17 16:23:22 +01:00
2023-01-17 16:23:22 +01:00
2023-01-17 16:23:22 +01:00
2023-02-14 19:21:58 -05:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-17 16:23:22 +01:00
2023-05-08 03:55:41 -07:00
2023-01-17 16:23:22 +01:00

The files here use the LLVM FileCheck framework, documented at https://llvm.org/docs/CommandGuide/FileCheck.html.

One extension worth noting is the use of revisions as custom prefixes for FileCheck. If your codegen test has different behavior based on the chosen target or different compiler flags that you want to exercise, you can use a revisions annotation, like so:

// revisions: aaa bbb
// [bbb] compile-flags: --flags-for-bbb

After specifying those variations, you can write different expected, or explicitly unexpected output by using <prefix>-SAME: and <prefix>-NOT:, like so:

// CHECK: expected code
// aaa-SAME: emitted-only-for-aaa
// aaa-NOT:                        emitted-only-for-bbb
// bbb-NOT:  emitted-only-for-aaa
// bbb-SAME:                       emitted-only-for-bbb