rust/src/test/ui/stability-attribute
Matthias Krüger 68a44c8228
Rollup merge of #90856 - ken-matsui:suggestion-to-wrap-vec-allocator-api-in-tuple, r=davidtwco
Suggestion to wrap inner types using 'allocator_api' in tuple

This PR provides a suggestion to wrap the inner types in tuple when being along with 'allocator_api'.

Closes https://github.com/rust-lang/rust/issues/83250

```rust
fn main() {
    let _vec: Vec<u8, _> = vec![]; //~ ERROR use of unstable library feature 'allocator_api'
}
```

```diff
 error[E0658]: use of unstable library feature 'allocator_api'
   --> $DIR/suggest-vec-allocator-api.rs:2:23
    |
 LL |     let _vec: Vec<u8, _> = vec![];
-   |                       ^
+   |                   ----^
+   |                   |
+   |                   help: consider wrapping the inner types in tuple: `(u8, _)`
    |
    = note: see issue #32838 <https://github.com/rust-lang/rust/issues/32838> for more information
    = help: add `#![feature(allocator_api)]` to the crate attributes to enable
```
2021-11-23 19:28:06 +01:00
..
auxiliary Move some tests to subdirectories 2020-12-07 02:25:09 +03:00
generics-default-stability-where.rs Remove redundant ignore-tidy-linelength annotations 2021-04-03 22:30:20 +02:00
generics-default-stability-where.stderr Remove redundant ignore-tidy-linelength annotations 2021-04-03 22:30:20 +02:00
generics-default-stability.rs Remove redundant ignore-tidy-linelength annotations 2021-04-03 22:30:20 +02:00
generics-default-stability.stderr Use last segment 2021-06-15 19:35:03 +08:00
issue-28075.rs Move some tests to subdirectories 2020-12-07 02:25:09 +03:00
issue-28075.stderr Move some tests to subdirectories 2020-12-07 02:25:09 +03:00
issue-28388-3.rs Move some tests to subdirectories 2020-12-07 02:25:09 +03:00
issue-28388-3.stderr Move some tests to subdirectories 2020-12-07 02:25:09 +03:00
missing-const-stability.rs Test for missing const-stability attributes 2020-09-25 14:31:32 -07:00
missing-const-stability.stderr Test for missing const-stability attributes 2020-09-25 14:31:32 -07:00
missing-stability-attr-at-top-level.rs Remove redundant descr/descriptive_variant methods from HIR. 2020-04-24 13:44:08 -05:00
missing-stability-attr-at-top-level.stderr Remove redundant descr/descriptive_variant methods from HIR. 2020-04-24 13:44:08 -05:00
stability-attribute-issue-43027.rs Inherit #[stable(..)] annotations in enum variants and fields from its item 2021-02-10 19:10:14 -08:00
stability-attribute-issue.rs
stability-attribute-issue.stderr
stability-attribute-non-staged-force-unstable.rs
stability-attribute-non-staged-force-unstable.stderr
stability-attribute-non-staged.rs
stability-attribute-non-staged.stderr
stability-attribute-sanity-2.rs
stability-attribute-sanity-2.stderr Add long explanation for E0545 2021-02-15 19:16:39 +01:00
stability-attribute-sanity-3.rs
stability-attribute-sanity-3.stderr
stability-attribute-sanity-4.rs
stability-attribute-sanity-4.stderr
stability-attribute-sanity.rs remove const_fn feature gate 2021-05-09 14:29:31 +02:00
stability-attribute-sanity.stderr Add long explanation for E0544. 2021-07-26 22:59:16 +01:00
stability-attribute-trait-impl.rs Don't abort compilation after giving a lint error 2021-11-08 01:22:28 +00:00
stability-attribute-trait-impl.stderr Don't abort compilation after giving a lint error 2021-11-08 01:22:28 +00:00
stability-in-private-module.rs Move some tests to more reasonable directories 2021-11-18 12:09:34 -03:00
stability-in-private-module.stderr Move some tests to more reasonable directories 2021-11-18 12:09:34 -03:00
suggest-vec-allocator-api.rs Suggestion to wrap inner types using allocator_api in tuple 2021-11-24 00:24:13 +09:00
suggest-vec-allocator-api.stderr Suggestion to wrap inner types using allocator_api in tuple 2021-11-24 00:24:13 +09:00