Update ui test files

This commit is contained in:
David Tolnay 2021-10-07 00:56:29 -04:00
parent 33b2677384
commit efbe574209
No known key found for this signature in database
GPG Key ID: F9BA143B95FF6D82
96 changed files with 103 additions and 103 deletions

View File

@ -1,5 +1,5 @@
error: failed to parse borrowed lifetimes: "zzz" error: failed to parse borrowed lifetimes: "zzz"
--> $DIR/bad_lifetimes.rs:5:22 --> $DIR/tests/ui/borrow/bad_lifetimes.rs:5:22
| |
5 | #[serde(borrow = "zzz")] 5 | #[serde(borrow = "zzz")]
| ^^^^^ | ^^^^^

View File

@ -1,5 +1,5 @@
error: duplicate borrowed lifetime `'a` error: duplicate borrowed lifetime `'a`
--> $DIR/duplicate_lifetime.rs:5:22 --> $DIR/tests/ui/borrow/duplicate_lifetime.rs:5:22
| |
5 | #[serde(borrow = "'a + 'a")] 5 | #[serde(borrow = "'a + 'a")]
| ^^^^^^^^^ | ^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: duplicate serde attribute `borrow` error: duplicate serde attribute `borrow`
--> $DIR/duplicate_variant.rs:8:13 --> $DIR/tests/ui/borrow/duplicate_variant.rs:8:13
| |
8 | #[serde(borrow)] 8 | #[serde(borrow)]
| ^^^^^^ | ^^^^^^

View File

@ -1,5 +1,5 @@
error: at least one lifetime must be borrowed error: at least one lifetime must be borrowed
--> $DIR/empty_lifetimes.rs:5:22 --> $DIR/tests/ui/borrow/empty_lifetimes.rs:5:22
| |
5 | #[serde(borrow = "")] 5 | #[serde(borrow = "")]
| ^^ | ^^

View File

@ -1,5 +1,5 @@
error: field `s` has no lifetimes to borrow error: field `s` has no lifetimes to borrow
--> $DIR/no_lifetimes.rs:5:5 --> $DIR/tests/ui/borrow/no_lifetimes.rs:5:5
| |
5 | / #[serde(borrow)] 5 | / #[serde(borrow)]
6 | | s: String, 6 | | s: String,

View File

@ -1,5 +1,5 @@
error: #[serde(borrow)] may only be used on newtype variants error: #[serde(borrow)] may only be used on newtype variants
--> $DIR/struct_variant.rs:8:5 --> $DIR/tests/ui/borrow/struct_variant.rs:8:5
| |
8 | / #[serde(borrow)] 8 | / #[serde(borrow)]
9 | | S { s: Str<'a> }, 9 | | S { s: Str<'a> },

View File

@ -1,5 +1,5 @@
error: field `s` does not have lifetime 'b error: field `s` does not have lifetime 'b
--> $DIR/wrong_lifetime.rs:5:5 --> $DIR/tests/ui/borrow/wrong_lifetime.rs:5:5
| |
5 | / #[serde(borrow = "'b")] 5 | / #[serde(borrow = "'b")]
6 | | s: &'a str, 6 | | s: &'a str,

View File

@ -1,5 +1,5 @@
error: enum tags `conflict` for type and content conflict with each other error: enum tags `conflict` for type and content conflict with each other
--> $DIR/adjacent-tag.rs:4:1 --> $DIR/tests/ui/conflict/adjacent-tag.rs:4:1
| |
4 | / #[serde(tag = "conflict", content = "conflict")] 4 | / #[serde(tag = "conflict", content = "conflict")]
5 | | enum E { 5 | | enum E {

View File

@ -1,5 +1,5 @@
error: #[serde(flatten)] cannot be used on newtype structs error: #[serde(flatten)] cannot be used on newtype structs
--> $DIR/flatten-newtype-struct.rs:6:12 --> $DIR/tests/ui/conflict/flatten-newtype-struct.rs:6:12
| |
6 | struct Foo(#[serde(flatten)] HashMap<String, String>); 6 | struct Foo(#[serde(flatten)] HashMap<String, String>);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(flatten)] cannot be used on tuple structs error: #[serde(flatten)] cannot be used on tuple structs
--> $DIR/flatten-tuple-struct.rs:6:17 --> $DIR/tests/ui/conflict/flatten-tuple-struct.rs:6:17
| |
6 | struct Foo(u32, #[serde(flatten)] HashMap<String, String>); 6 | struct Foo(u32, #[serde(flatten)] HashMap<String, String>);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(from = "...")] and #[serde(try_from = "...")] conflict with each other error: #[serde(from = "...")] and #[serde(try_from = "...")] conflict with each other
--> $DIR/from-try-from.rs:4:1 --> $DIR/tests/ui/conflict/from-try-from.rs:4:1
| |
4 | / #[serde(from = "u64", try_from = "u64")] 4 | / #[serde(from = "u64", try_from = "u64")]
5 | | struct S { 5 | | struct S {

View File

@ -1,5 +1,5 @@
error: variant field name `conflict` conflicts with internal tag error: variant field name `conflict` conflicts with internal tag
--> $DIR/internal-tag-alias.rs:4:1 --> $DIR/tests/ui/conflict/internal-tag-alias.rs:4:1
| |
4 | / #[serde(tag = "conflict")] 4 | / #[serde(tag = "conflict")]
5 | | enum E { 5 | | enum E {

View File

@ -1,5 +1,5 @@
error: variant field name `conflict` conflicts with internal tag error: variant field name `conflict` conflicts with internal tag
--> $DIR/internal-tag.rs:4:1 --> $DIR/tests/ui/conflict/internal-tag.rs:4:1
| |
4 | / #[serde(tag = "conflict")] 4 | / #[serde(tag = "conflict")]
5 | | enum E { 5 | | enum E {

View File

@ -1,5 +1,5 @@
error: #[serde(default)] can only be used on structs with named fields error: #[serde(default)] can only be used on structs with named fields
--> $DIR/enum.rs:5:1 --> $DIR/tests/ui/default-attribute/enum.rs:5:1
| |
5 | enum E { 5 | enum E {
| ^^^^ | ^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(default = "...")] can only be used on structs with named fields error: #[serde(default = "...")] can only be used on structs with named fields
--> $DIR/enum_path.rs:5:1 --> $DIR/tests/ui/default-attribute/enum_path.rs:5:1
| |
5 | enum E { 5 | enum E {
| ^^^^ | ^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(default)] can only be used on structs with named fields error: #[serde(default)] can only be used on structs with named fields
--> $DIR/nameless_struct_fields.rs:5:9 --> $DIR/tests/ui/default-attribute/nameless_struct_fields.rs:5:9
| |
5 | struct T(u8, u8); 5 | struct T(u8, u8);
| ^^^^^^^^ | ^^^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(default = "...")] can only be used on structs with named fields error: #[serde(default = "...")] can only be used on structs with named fields
--> $DIR/nameless_struct_fields_path.rs:5:9 --> $DIR/tests/ui/default-attribute/nameless_struct_fields_path.rs:5:9
| |
5 | struct T(u8, u8); 5 | struct T(u8, u8);
| ^^^^^^^^ | ^^^^^^^^

View File

@ -1,5 +1,5 @@
error: unknown serde field attribute `serialize` error: unknown serde field attribute `serialize`
--> $DIR/rename-and-ser.rs:5:27 --> $DIR/tests/ui/duplicate-attribute/rename-and-ser.rs:5:27
| |
5 | #[serde(rename = "x", serialize = "y")] 5 | #[serde(rename = "x", serialize = "y")]
| ^^^^^^^^^ | ^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: duplicate serde attribute `rename` error: duplicate serde attribute `rename`
--> $DIR/rename-ser-rename-ser.rs:5:38 --> $DIR/tests/ui/duplicate-attribute/rename-ser-rename-ser.rs:5:38
| |
5 | #[serde(rename(serialize = "x"), rename(serialize = "y"))] 5 | #[serde(rename(serialize = "x"), rename(serialize = "y"))]
| ^^^^^^ | ^^^^^^

View File

@ -1,5 +1,5 @@
error: duplicate serde attribute `rename` error: duplicate serde attribute `rename`
--> $DIR/rename-ser-rename.rs:6:13 --> $DIR/tests/ui/duplicate-attribute/rename-ser-rename.rs:6:13
| |
6 | #[serde(rename = "y")] 6 | #[serde(rename = "y")]
| ^^^^^^ | ^^^^^^

View File

@ -1,5 +1,5 @@
error: duplicate serde attribute `rename` error: duplicate serde attribute `rename`
--> $DIR/rename-ser-ser.rs:5:37 --> $DIR/tests/ui/duplicate-attribute/rename-ser-ser.rs:5:37
| |
5 | #[serde(rename(serialize = "x", serialize = "y"))] 5 | #[serde(rename(serialize = "x", serialize = "y"))]
| ^^^^^^^^^ | ^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: duplicate serde attribute `rename` error: duplicate serde attribute `rename`
--> $DIR/two-rename-ser.rs:6:13 --> $DIR/tests/ui/duplicate-attribute/two-rename-ser.rs:6:13
| |
6 | #[serde(rename(serialize = "y"))] 6 | #[serde(rename(serialize = "y"))]
| ^^^^^^ | ^^^^^^

View File

@ -1,5 +1,5 @@
error: duplicate serde attribute `serialize_with` error: duplicate serde attribute `serialize_with`
--> $DIR/with-and-serialize-with.rs:5:25 --> $DIR/tests/ui/duplicate-attribute/with-and-serialize-with.rs:5:25
| |
5 | #[serde(with = "w", serialize_with = "s")] 5 | #[serde(with = "w", serialize_with = "s")]
| ^^^^^^^^^^^^^^ | ^^^^^^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(tag = "...", content = "...")] must be used together error: #[serde(tag = "...", content = "...")] must be used together
--> $DIR/content-no-tag.rs:4:9 --> $DIR/tests/ui/enum-representation/content-no-tag.rs:4:9
| |
4 | #[serde(content = "c")] 4 | #[serde(content = "c")]
| ^^^^^^^ | ^^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(tag = "...")] cannot be used with tuple variants error: #[serde(tag = "...")] cannot be used with tuple variants
--> $DIR/internal-tuple-variant.rs:6:5 --> $DIR/tests/ui/enum-representation/internal-tuple-variant.rs:6:5
| |
6 | Tuple(u8, u8), 6 | Tuple(u8, u8),
| ^^^^^^^^^^^^^ | ^^^^^^^^^^^^^

View File

@ -1,17 +1,17 @@
error: untagged enum cannot have #[serde(tag = "...", content = "...")] error: untagged enum cannot have #[serde(tag = "...", content = "...")]
--> $DIR/untagged-and-adjacent.rs:4:9 --> $DIR/tests/ui/enum-representation/untagged-and-adjacent.rs:4:9
| |
4 | #[serde(untagged)] 4 | #[serde(untagged)]
| ^^^^^^^^ | ^^^^^^^^
error: untagged enum cannot have #[serde(tag = "...", content = "...")] error: untagged enum cannot have #[serde(tag = "...", content = "...")]
--> $DIR/untagged-and-adjacent.rs:5:9 --> $DIR/tests/ui/enum-representation/untagged-and-adjacent.rs:5:9
| |
5 | #[serde(tag = "t", content = "c")] 5 | #[serde(tag = "t", content = "c")]
| ^^^ | ^^^
error: untagged enum cannot have #[serde(tag = "...", content = "...")] error: untagged enum cannot have #[serde(tag = "...", content = "...")]
--> $DIR/untagged-and-adjacent.rs:5:20 --> $DIR/tests/ui/enum-representation/untagged-and-adjacent.rs:5:20
| |
5 | #[serde(tag = "t", content = "c")] 5 | #[serde(tag = "t", content = "c")]
| ^^^^^^^ | ^^^^^^^

View File

@ -1,11 +1,11 @@
error: untagged enum cannot have #[serde(content = "...")] error: untagged enum cannot have #[serde(content = "...")]
--> $DIR/untagged-and-content.rs:4:9 --> $DIR/tests/ui/enum-representation/untagged-and-content.rs:4:9
| |
4 | #[serde(untagged)] 4 | #[serde(untagged)]
| ^^^^^^^^ | ^^^^^^^^
error: untagged enum cannot have #[serde(content = "...")] error: untagged enum cannot have #[serde(content = "...")]
--> $DIR/untagged-and-content.rs:5:9 --> $DIR/tests/ui/enum-representation/untagged-and-content.rs:5:9
| |
5 | #[serde(content = "c")] 5 | #[serde(content = "c")]
| ^^^^^^^ | ^^^^^^^

View File

@ -1,11 +1,11 @@
error: enum cannot be both untagged and internally tagged error: enum cannot be both untagged and internally tagged
--> $DIR/untagged-and-internal.rs:4:9 --> $DIR/tests/ui/enum-representation/untagged-and-internal.rs:4:9
| |
4 | #[serde(untagged)] 4 | #[serde(untagged)]
| ^^^^^^^^ | ^^^^^^^^
error: enum cannot be both untagged and internally tagged error: enum cannot be both untagged and internally tagged
--> $DIR/untagged-and-internal.rs:5:9 --> $DIR/tests/ui/enum-representation/untagged-and-internal.rs:5:9
| |
5 | #[serde(tag = "type")] 5 | #[serde(tag = "type")]
| ^^^ | ^^^

View File

@ -1,5 +1,5 @@
error: #[serde(untagged)] can only be used on enums error: #[serde(untagged)] can only be used on enums
--> $DIR/untagged-struct.rs:5:1 --> $DIR/tests/ui/enum-representation/untagged-struct.rs:5:1
| |
5 | struct S; 5 | struct S;
| ^^^^^^ | ^^^^^^

View File

@ -1,5 +1,5 @@
error: expected serde rename attribute to be a string: `rename = "..."` error: expected serde rename attribute to be a string: `rename = "..."`
--> $DIR/boolean.rs:5:22 --> $DIR/tests/ui/expected-string/boolean.rs:5:22
| |
5 | #[serde(rename = true)] 5 | #[serde(rename = true)]
| ^^^^ | ^^^^

View File

@ -1,5 +1,5 @@
error: expected serde rename attribute to be a string: `rename = "..."` error: expected serde rename attribute to be a string: `rename = "..."`
--> $DIR/byte_character.rs:5:22 --> $DIR/tests/ui/expected-string/byte_character.rs:5:22
| |
5 | #[serde(rename = b'a')] 5 | #[serde(rename = b'a')]
| ^^^^ | ^^^^

View File

@ -1,5 +1,5 @@
error: expected serde rename attribute to be a string: `rename = "..."` error: expected serde rename attribute to be a string: `rename = "..."`
--> $DIR/byte_string.rs:5:22 --> $DIR/tests/ui/expected-string/byte_string.rs:5:22
| |
5 | #[serde(rename = b"byte string")] 5 | #[serde(rename = b"byte string")]
| ^^^^^^^^^^^^^^ | ^^^^^^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: expected serde rename attribute to be a string: `rename = "..."` error: expected serde rename attribute to be a string: `rename = "..."`
--> $DIR/character.rs:5:22 --> $DIR/tests/ui/expected-string/character.rs:5:22
| |
5 | #[serde(rename = 'a')] 5 | #[serde(rename = 'a')]
| ^^^ | ^^^

View File

@ -1,5 +1,5 @@
error: expected serde rename attribute to be a string: `rename = "..."` error: expected serde rename attribute to be a string: `rename = "..."`
--> $DIR/float.rs:5:22 --> $DIR/tests/ui/expected-string/float.rs:5:22
| |
5 | #[serde(rename = 3.14)] 5 | #[serde(rename = 3.14)]
| ^^^^ | ^^^^

View File

@ -1,5 +1,5 @@
error: expected serde rename attribute to be a string: `rename = "..."` error: expected serde rename attribute to be a string: `rename = "..."`
--> $DIR/integer.rs:5:22 --> $DIR/tests/ui/expected-string/integer.rs:5:22
| |
5 | #[serde(rename = 100)] 5 | #[serde(rename = 100)]
| ^^^ | ^^^

View File

@ -1,11 +1,11 @@
error: #[serde(field_identifier)] and #[serde(variant_identifier)] cannot both be set error: #[serde(field_identifier)] and #[serde(variant_identifier)] cannot both be set
--> $DIR/both.rs:4:9 --> $DIR/tests/ui/identifier/both.rs:4:9
| |
4 | #[serde(field_identifier, variant_identifier)] 4 | #[serde(field_identifier, variant_identifier)]
| ^^^^^^^^^^^^^^^^ | ^^^^^^^^^^^^^^^^
error: #[serde(field_identifier)] and #[serde(variant_identifier)] cannot both be set error: #[serde(field_identifier)] and #[serde(variant_identifier)] cannot both be set
--> $DIR/both.rs:4:27 --> $DIR/tests/ui/identifier/both.rs:4:27
| |
4 | #[serde(field_identifier, variant_identifier)] 4 | #[serde(field_identifier, variant_identifier)]
| ^^^^^^^^^^^^^^^^^^ | ^^^^^^^^^^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(field_identifier)] can only be used on an enum error: #[serde(field_identifier)] can only be used on an enum
--> $DIR/field_struct.rs:5:1 --> $DIR/tests/ui/identifier/field_struct.rs:5:1
| |
5 | struct S; 5 | struct S;
| ^^^^^^ | ^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(field_identifier)] may only contain unit variants error: #[serde(field_identifier)] may only contain unit variants
--> $DIR/field_tuple.rs:7:5 --> $DIR/tests/ui/identifier/field_tuple.rs:7:5
| |
7 | B(u8, u8), 7 | B(u8, u8),
| ^^^^^^^^^ | ^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: `Other` must be the last variant error: `Other` must be the last variant
--> $DIR/newtype_not_last.rs:7:5 --> $DIR/tests/ui/identifier/newtype_not_last.rs:7:5
| |
7 | Other(String), 7 | Other(String),
| ^^^^^^^^^^^^^ | ^^^^^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(other)] must be on a unit variant error: #[serde(other)] must be on a unit variant
--> $DIR/not_unit.rs:7:5 --> $DIR/tests/ui/identifier/not_unit.rs:7:5
| |
7 | / #[serde(other)] 7 | / #[serde(other)]
8 | | Other(u8, u8), 8 | | Other(u8, u8),

View File

@ -1,5 +1,5 @@
error: #[serde(other)] must be on the last variant error: #[serde(other)] must be on the last variant
--> $DIR/other_not_last.rs:7:5 --> $DIR/tests/ui/identifier/other_not_last.rs:7:5
| |
7 | / #[serde(other)] 7 | / #[serde(other)]
8 | | Other, 8 | | Other,

View File

@ -1,5 +1,5 @@
error: #[serde(other)] cannot appear on untagged enum error: #[serde(other)] cannot appear on untagged enum
--> $DIR/other_untagged.rs:6:5 --> $DIR/tests/ui/identifier/other_untagged.rs:6:5
| |
6 | / #[serde(other)] 6 | / #[serde(other)]
7 | | Other, 7 | | Other,

View File

@ -1,5 +1,5 @@
error: #[serde(other)] may not be used on a variant identifier error: #[serde(other)] may not be used on a variant identifier
--> $DIR/other_variant.rs:6:5 --> $DIR/tests/ui/identifier/other_variant.rs:6:5
| |
6 | / #[serde(other)] 6 | / #[serde(other)]
7 | | Other, 7 | | Other,

View File

@ -1,5 +1,5 @@
error: #[serde(variant_identifier)] can only be used on an enum error: #[serde(variant_identifier)] can only be used on an enum
--> $DIR/variant_struct.rs:5:1 --> $DIR/tests/ui/identifier/variant_struct.rs:5:1
| |
5 | struct S; 5 | struct S;
| ^^^^^^ | ^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(variant_identifier)] may only contain unit variants error: #[serde(variant_identifier)] may only contain unit variants
--> $DIR/variant_tuple.rs:7:5 --> $DIR/tests/ui/identifier/variant_tuple.rs:7:5
| |
7 | B(u8, u8), 7 | B(u8, u8),
| ^^^^^^^^^ | ^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: malformed bound attribute, expected `bound(serialize = ..., deserialize = ...)` error: malformed bound attribute, expected `bound(serialize = ..., deserialize = ...)`
--> $DIR/bound.rs:5:19 --> $DIR/tests/ui/malformed/bound.rs:5:19
| |
5 | #[serde(bound(unknown))] 5 | #[serde(bound(unknown))]
| ^^^^^^^ | ^^^^^^^

View File

@ -1,5 +1,5 @@
error: unexpected end of input, expected literal error: unexpected end of input, expected literal
--> $DIR/cut_off.rs:4:17 --> $DIR/tests/ui/malformed/cut_off.rs:4:17
| |
4 | #[serde(rename =)] 4 | #[serde(rename =)]
| ^ | ^

View File

@ -1,11 +1,11 @@
error: expected #[serde(...)] error: expected #[serde(...)]
--> $DIR/not_list.rs:4:3 --> $DIR/tests/ui/malformed/not_list.rs:4:3
| |
4 | #[serde] 4 | #[serde]
| ^^^^^ | ^^^^^
error: expected #[serde(...)] error: expected #[serde(...)]
--> $DIR/not_list.rs:5:3 --> $DIR/tests/ui/malformed/not_list.rs:5:3
| |
5 | #[serde = "?"] 5 | #[serde = "?"]
| ^^^^^^^^^^^ | ^^^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: malformed rename attribute, expected `rename(serialize = ..., deserialize = ...)` error: malformed rename attribute, expected `rename(serialize = ..., deserialize = ...)`
--> $DIR/rename.rs:5:20 --> $DIR/tests/ui/malformed/rename.rs:5:20
| |
5 | #[serde(rename(unknown))] 5 | #[serde(rename(unknown))]
| ^^^^^^^ | ^^^^^^^

View File

@ -1,5 +1,5 @@
error: cannot deserialize when there is a lifetime parameter called 'de error: cannot deserialize when there is a lifetime parameter called 'de
--> $DIR/deserialize_de_lifetime.rs:4:10 --> $DIR/tests/ui/precondition/deserialize_de_lifetime.rs:4:10
| |
4 | struct S<'de> { 4 | struct S<'de> {
| ^^^ | ^^^

View File

@ -1,5 +1,5 @@
error: cannot deserialize a dynamically sized struct error: cannot deserialize a dynamically sized struct
--> $DIR/deserialize_dst.rs:4:1 --> $DIR/tests/ui/precondition/deserialize_dst.rs:4:1
| |
4 | / struct S { 4 | / struct S {
5 | | string: String, 5 | | string: String,

View File

@ -1,5 +1,5 @@
error: field identifiers cannot be serialized error: field identifiers cannot be serialized
--> $DIR/serialize_field_identifier.rs:4:1 --> $DIR/tests/ui/precondition/serialize_field_identifier.rs:4:1
| |
4 | / #[serde(field_identifier)] 4 | / #[serde(field_identifier)]
5 | | enum F { 5 | | enum F {

View File

@ -1,5 +1,5 @@
error: variant identifiers cannot be serialized error: variant identifiers cannot be serialized
--> $DIR/serialize_variant_identifier.rs:4:1 --> $DIR/tests/ui/precondition/serialize_variant_identifier.rs:4:1
| |
4 | / #[serde(variant_identifier)] 4 | / #[serde(variant_identifier)]
5 | | enum F { 5 | | enum F {

View File

@ -1,5 +1,5 @@
error: failed to parse path: "~~~" error: failed to parse path: "~~~"
--> $DIR/bad_getter.rs:12:22 --> $DIR/tests/ui/remote/bad_getter.rs:12:22
| |
12 | #[serde(getter = "~~~")] 12 | #[serde(getter = "~~~")]
| ^^^^^ | ^^^^^

View File

@ -1,5 +1,5 @@
error: failed to parse path: "~~~" error: failed to parse path: "~~~"
--> $DIR/bad_remote.rs:10:18 --> $DIR/tests/ui/remote/bad_remote.rs:10:18
| |
10 | #[serde(remote = "~~~")] 10 | #[serde(remote = "~~~")]
| ^^^^^ | ^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(getter = "...")] is not allowed in an enum error: #[serde(getter = "...")] is not allowed in an enum
--> $DIR/enum_getter.rs:10:1 --> $DIR/tests/ui/remote/enum_getter.rs:10:1
| |
10 | / #[serde(remote = "remote::E")] 10 | / #[serde(remote = "remote::E")]
11 | | pub enum E { 11 | | pub enum E {

View File

@ -1,5 +1,5 @@
error[E0063]: missing field `b` in initializer of `remote::S` error[E0063]: missing field `b` in initializer of `remote::S`
--> $DIR/missing_field.rs:11:18 --> $DIR/tests/ui/remote/missing_field.rs:11:18
| |
11 | #[serde(remote = "remote::S")] 11 | #[serde(remote = "remote::S")]
| ^^^^^^^^^^^ missing `b` | ^^^^^^^^^^^ missing `b`

View File

@ -1,5 +1,5 @@
error: #[serde(getter = "...")] can only be used in structs that have #[serde(remote = "...")] error: #[serde(getter = "...")] can only be used in structs that have #[serde(remote = "...")]
--> $DIR/nonremote_getter.rs:4:1 --> $DIR/tests/ui/remote/nonremote_getter.rs:4:1
| |
4 | / struct S { 4 | / struct S {
5 | | #[serde(getter = "S::get")] 5 | | #[serde(getter = "S::get")]

View File

@ -1,11 +1,11 @@
error[E0609]: no field `b` on type `&remote::S` error[E0609]: no field `b` on type `&remote::S`
--> $DIR/unknown_field.rs:12:5 --> $DIR/tests/ui/remote/unknown_field.rs:12:5
| |
12 | b: u8, 12 | b: u8,
| ^ help: a field with a similar name exists: `a` | ^ help: a field with a similar name exists: `a`
error[E0560]: struct `remote::S` has no field named `b` error[E0560]: struct `remote::S` has no field named `b`
--> $DIR/unknown_field.rs:12:5 --> $DIR/tests/ui/remote/unknown_field.rs:12:5
| |
12 | b: u8, 12 | b: u8,
| ^ help: a field with a similar name exists: `a` | ^ help: a field with a similar name exists: `a`

View File

@ -1,5 +1,5 @@
error[E0308]: mismatched types error[E0308]: mismatched types
--> $DIR/wrong_de.rs:7:10 --> $DIR/tests/ui/remote/wrong_de.rs:7:10
| |
7 | #[derive(Deserialize)] 7 | #[derive(Deserialize)]
| ^^^^^^^^^^^ expected `u16`, found `u8` | ^^^^^^^^^^^ expected `u16`, found `u8`

View File

@ -1,5 +1,5 @@
error[E0308]: mismatched types error[E0308]: mismatched types
--> $DIR/wrong_getter.rs:15:10 --> $DIR/tests/ui/remote/wrong_getter.rs:15:10
| |
15 | #[derive(Serialize)] 15 | #[derive(Serialize)]
| ^^^^^^^^^ expected `u8`, found `u16` | ^^^^^^^^^ expected `u8`, found `u16`

View File

@ -1,5 +1,5 @@
error[E0308]: mismatched types error[E0308]: mismatched types
--> $DIR/wrong_ser.rs:9:10 --> $DIR/tests/ui/remote/wrong_ser.rs:9:10
| |
9 | #[derive(Serialize)] 9 | #[derive(Serialize)]
| ^^^^^^^^^ expected `u8`, found `u16` | ^^^^^^^^^ expected `u8`, found `u16`

View File

@ -1,5 +1,5 @@
error: unknown rename rule `rename_all = "abc"`, expected one of "lowercase", "UPPERCASE", "PascalCase", "camelCase", "snake_case", "SCREAMING_SNAKE_CASE", "kebab-case", "SCREAMING-KEBAB-CASE" error: unknown rename rule `rename_all = "abc"`, expected one of "lowercase", "UPPERCASE", "PascalCase", "camelCase", "snake_case", "SCREAMING_SNAKE_CASE", "kebab-case", "SCREAMING-KEBAB-CASE"
--> $DIR/container_unknown_rename_rule.rs:4:22 --> $DIR/tests/ui/rename/container_unknown_rename_rule.rs:4:22
| |
4 | #[serde(rename_all = "abc")] 4 | #[serde(rename_all = "abc")]
| ^^^^^ | ^^^^^

View File

@ -1,5 +1,5 @@
error: unknown rename rule `rename_all = "abc"`, expected one of "lowercase", "UPPERCASE", "PascalCase", "camelCase", "snake_case", "SCREAMING_SNAKE_CASE", "kebab-case", "SCREAMING-KEBAB-CASE" error: unknown rename rule `rename_all = "abc"`, expected one of "lowercase", "UPPERCASE", "PascalCase", "camelCase", "snake_case", "SCREAMING_SNAKE_CASE", "kebab-case", "SCREAMING-KEBAB-CASE"
--> $DIR/variant_unknown_rename_rule.rs:5:26 --> $DIR/tests/ui/rename/variant_unknown_rename_rule.rs:5:26
| |
5 | #[serde(rename_all = "abc")] 5 | #[serde(rename_all = "abc")]
| ^^^^^ | ^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(tag = "...")] can only be used on enums and structs with named fields error: #[serde(tag = "...")] can only be used on enums and structs with named fields
--> $DIR/internally-tagged-tuple.rs:5:9 --> $DIR/tests/ui/struct-representation/internally-tagged-tuple.rs:5:9
| |
5 | struct S(u8, u8); 5 | struct S(u8, u8);
| ^^^^^^^^ | ^^^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(tag = "...")] can only be used on enums and structs with named fields error: #[serde(tag = "...")] can only be used on enums and structs with named fields
--> $DIR/internally-tagged-unit.rs:3:10 --> $DIR/tests/ui/struct-representation/internally-tagged-unit.rs:3:10
| |
3 | #[derive(Serialize)] 3 | #[derive(Serialize)]
| ^^^^^^^^^ | ^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: #[serde(transparent)] requires struct to have at most one transparent field error: #[serde(transparent)] requires struct to have at most one transparent field
--> $DIR/at_most_one.rs:4:1 --> $DIR/tests/ui/transparent/at_most_one.rs:4:1
| |
4 | / #[serde(transparent)] 4 | / #[serde(transparent)]
5 | | struct S { 5 | | struct S {

View File

@ -1,5 +1,5 @@
error: #[serde(transparent)] requires at least one field that is neither skipped nor has a default error: #[serde(transparent)] requires at least one field that is neither skipped nor has a default
--> $DIR/de_at_least_one.rs:4:1 --> $DIR/tests/ui/transparent/de_at_least_one.rs:4:1
| |
4 | / #[serde(transparent)] 4 | / #[serde(transparent)]
5 | | struct S { 5 | | struct S {

View File

@ -1,5 +1,5 @@
error: #[serde(transparent)] is not allowed on an enum error: #[serde(transparent)] is not allowed on an enum
--> $DIR/enum.rs:4:1 --> $DIR/tests/ui/transparent/enum.rs:4:1
| |
4 | / #[serde(transparent)] 4 | / #[serde(transparent)]
5 | | enum E {} 5 | | enum E {}

View File

@ -1,5 +1,5 @@
error: #[serde(transparent)] requires at least one field that is not skipped error: #[serde(transparent)] requires at least one field that is not skipped
--> $DIR/ser_at_least_one.rs:4:1 --> $DIR/tests/ui/transparent/ser_at_least_one.rs:4:1
| |
4 | / #[serde(transparent)] 4 | / #[serde(transparent)]
5 | | struct S { 5 | | struct S {

View File

@ -1,5 +1,5 @@
error: #[serde(transparent)] is not allowed on a unit struct error: #[serde(transparent)] is not allowed on a unit struct
--> $DIR/unit_struct.rs:4:1 --> $DIR/tests/ui/transparent/unit_struct.rs:4:1
| |
4 | / #[serde(transparent)] 4 | / #[serde(transparent)]
5 | | struct S; 5 | | struct S;

View File

@ -1,5 +1,5 @@
error: #[serde(transparent)] is not allowed with #[serde(from = "...")] error: #[serde(transparent)] is not allowed with #[serde(from = "...")]
--> $DIR/with_from.rs:4:1 --> $DIR/tests/ui/transparent/with_from.rs:4:1
| |
4 | / #[serde(transparent, from = "u64")] 4 | / #[serde(transparent, from = "u64")]
5 | | struct S { 5 | | struct S {

View File

@ -1,5 +1,5 @@
error: #[serde(transparent)] is not allowed with #[serde(into = "...")] error: #[serde(transparent)] is not allowed with #[serde(into = "...")]
--> $DIR/with_into.rs:4:1 --> $DIR/tests/ui/transparent/with_into.rs:4:1
| |
4 | / #[serde(transparent, into = "u64")] 4 | / #[serde(transparent, into = "u64")]
5 | | struct S { 5 | | struct S {

View File

@ -1,5 +1,5 @@
error: #[serde(transparent)] is not allowed with #[serde(try_from = "...")] error: #[serde(transparent)] is not allowed with #[serde(try_from = "...")]
--> $DIR/with_try_from.rs:4:1 --> $DIR/tests/ui/transparent/with_try_from.rs:4:1
| |
4 | / #[serde(transparent, try_from = "u64")] 4 | / #[serde(transparent, try_from = "u64")]
5 | | struct S { 5 | | struct S {

View File

@ -1,5 +1,5 @@
error: failed to parse type: from = "Option<T" error: failed to parse type: from = "Option<T"
--> $DIR/from.rs:4:16 --> $DIR/tests/ui/type-attribute/from.rs:4:16
| |
4 | #[serde(from = "Option<T")] 4 | #[serde(from = "Option<T")]
| ^^^^^^^^^^ | ^^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: failed to parse type: into = "Option<T" error: failed to parse type: into = "Option<T"
--> $DIR/into.rs:4:16 --> $DIR/tests/ui/type-attribute/into.rs:4:16
| |
4 | #[serde(into = "Option<T")] 4 | #[serde(into = "Option<T")]
| ^^^^^^^^^^ | ^^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: failed to parse type: try_from = "Option<T" error: failed to parse type: try_from = "Option<T"
--> $DIR/try_from.rs:4:20 --> $DIR/tests/ui/type-attribute/try_from.rs:4:20
| |
4 | #[serde(try_from = "Option<T")] 4 | #[serde(try_from = "Option<T")]
| ^^^^^^^^^^ | ^^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: unexpected literal in serde container attribute error: unexpected literal in serde container attribute
--> $DIR/container.rs:4:9 --> $DIR/tests/ui/unexpected-literal/container.rs:4:9
| |
4 | #[serde("literal")] 4 | #[serde("literal")]
| ^^^^^^^^^ | ^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: unexpected literal in serde field attribute error: unexpected literal in serde field attribute
--> $DIR/field.rs:5:13 --> $DIR/tests/ui/unexpected-literal/field.rs:5:13
| |
5 | #[serde("literal")] 5 | #[serde("literal")]
| ^^^^^^^^^ | ^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: unexpected literal in serde variant attribute error: unexpected literal in serde variant attribute
--> $DIR/variant.rs:5:13 --> $DIR/tests/ui/unexpected-literal/variant.rs:5:13
| |
5 | #[serde("literal")] 5 | #[serde("literal")]
| ^^^^^^^^^ | ^^^^^^^^^

View File

@ -1,5 +1,5 @@
error: unknown serde container attribute `abc` error: unknown serde container attribute `abc`
--> $DIR/container.rs:4:9 --> $DIR/tests/ui/unknown-attribute/container.rs:4:9
| |
4 | #[serde(abc = "xyz")] 4 | #[serde(abc = "xyz")]
| ^^^ | ^^^

View File

@ -1,5 +1,5 @@
error: unknown serde field attribute `abc` error: unknown serde field attribute `abc`
--> $DIR/field.rs:5:13 --> $DIR/tests/ui/unknown-attribute/field.rs:5:13
| |
5 | #[serde(abc = "xyz")] 5 | #[serde(abc = "xyz")]
| ^^^ | ^^^

View File

@ -1,5 +1,5 @@
error: unknown serde variant attribute `abc` error: unknown serde variant attribute `abc`
--> $DIR/variant.rs:5:13 --> $DIR/tests/ui/unknown-attribute/variant.rs:5:13
| |
5 | #[serde(abc = "xyz")] 5 | #[serde(abc = "xyz")]
| ^^^ | ^^^

View File

@ -1,5 +1,5 @@
error: Serde does not support derive for unions error: Serde does not support derive for unions
--> $DIR/union_de.rs:4:1 --> $DIR/tests/ui/unsupported/union_de.rs:4:1
| |
4 | / union Union { 4 | / union Union {
5 | | x: u8, 5 | | x: u8,

View File

@ -1,5 +1,5 @@
error: Serde does not support derive for unions error: Serde does not support derive for unions
--> $DIR/union_ser.rs:4:1 --> $DIR/tests/ui/unsupported/union_ser.rs:4:1
| |
4 | / union Union { 4 | / union Union {
5 | | x: u8, 5 | | x: u8,

View File

@ -1,5 +1,5 @@
error: variant `Newtype` cannot have both #[serde(deserialize_with)] and a field #0 marked with #[serde(skip_deserializing)] error: variant `Newtype` cannot have both #[serde(deserialize_with)] and a field #0 marked with #[serde(skip_deserializing)]
--> $DIR/skip_de_newtype_field.rs:5:5 --> $DIR/tests/ui/with-variant/skip_de_newtype_field.rs:5:5
| |
5 | / #[serde(deserialize_with = "deserialize_some_newtype_variant")] 5 | / #[serde(deserialize_with = "deserialize_some_newtype_variant")]
6 | | Newtype(#[serde(skip_deserializing)] String), 6 | | Newtype(#[serde(skip_deserializing)] String),

View File

@ -1,5 +1,5 @@
error: variant `Struct` cannot have both #[serde(deserialize_with)] and a field `f1` marked with #[serde(skip_deserializing)] error: variant `Struct` cannot have both #[serde(deserialize_with)] and a field `f1` marked with #[serde(skip_deserializing)]
--> $DIR/skip_de_struct_field.rs:5:5 --> $DIR/tests/ui/with-variant/skip_de_struct_field.rs:5:5
| |
5 | / #[serde(deserialize_with = "deserialize_some_other_variant")] 5 | / #[serde(deserialize_with = "deserialize_some_other_variant")]
6 | | Struct { 6 | | Struct {

View File

@ -1,5 +1,5 @@
error: variant `Tuple` cannot have both #[serde(deserialize_with)] and a field #0 marked with #[serde(skip_deserializing)] error: variant `Tuple` cannot have both #[serde(deserialize_with)] and a field #0 marked with #[serde(skip_deserializing)]
--> $DIR/skip_de_tuple_field.rs:5:5 --> $DIR/tests/ui/with-variant/skip_de_tuple_field.rs:5:5
| |
5 | / #[serde(deserialize_with = "deserialize_some_other_variant")] 5 | / #[serde(deserialize_with = "deserialize_some_other_variant")]
6 | | Tuple(#[serde(skip_deserializing)] String, u8), 6 | | Tuple(#[serde(skip_deserializing)] String, u8),

View File

@ -1,5 +1,5 @@
error: variant `Unit` cannot have both #[serde(deserialize_with)] and #[serde(skip_deserializing)] error: variant `Unit` cannot have both #[serde(deserialize_with)] and #[serde(skip_deserializing)]
--> $DIR/skip_de_whole_variant.rs:5:5 --> $DIR/tests/ui/with-variant/skip_de_whole_variant.rs:5:5
| |
5 | / #[serde(deserialize_with = "deserialize_some_unit_variant")] 5 | / #[serde(deserialize_with = "deserialize_some_unit_variant")]
6 | | #[serde(skip_deserializing)] 6 | | #[serde(skip_deserializing)]

View File

@ -1,5 +1,5 @@
error: variant `Newtype` cannot have both #[serde(serialize_with)] and a field #0 marked with #[serde(skip_serializing)] error: variant `Newtype` cannot have both #[serde(serialize_with)] and a field #0 marked with #[serde(skip_serializing)]
--> $DIR/skip_ser_newtype_field.rs:5:5 --> $DIR/tests/ui/with-variant/skip_ser_newtype_field.rs:5:5
| |
5 | / #[serde(serialize_with = "serialize_some_newtype_variant")] 5 | / #[serde(serialize_with = "serialize_some_newtype_variant")]
6 | | Newtype(#[serde(skip_serializing)] String), 6 | | Newtype(#[serde(skip_serializing)] String),

View File

@ -1,5 +1,5 @@
error: variant `Newtype` cannot have both #[serde(serialize_with)] and a field #0 marked with #[serde(skip_serializing_if)] error: variant `Newtype` cannot have both #[serde(serialize_with)] and a field #0 marked with #[serde(skip_serializing_if)]
--> $DIR/skip_ser_newtype_field_if.rs:5:5 --> $DIR/tests/ui/with-variant/skip_ser_newtype_field_if.rs:5:5
| |
5 | / #[serde(serialize_with = "serialize_some_newtype_variant")] 5 | / #[serde(serialize_with = "serialize_some_newtype_variant")]
6 | | Newtype(#[serde(skip_serializing_if = "always")] String), 6 | | Newtype(#[serde(skip_serializing_if = "always")] String),

View File

@ -1,5 +1,5 @@
error: variant `Struct` cannot have both #[serde(serialize_with)] and a field `f1` marked with #[serde(skip_serializing)] error: variant `Struct` cannot have both #[serde(serialize_with)] and a field `f1` marked with #[serde(skip_serializing)]
--> $DIR/skip_ser_struct_field.rs:5:5 --> $DIR/tests/ui/with-variant/skip_ser_struct_field.rs:5:5
| |
5 | / #[serde(serialize_with = "serialize_some_other_variant")] 5 | / #[serde(serialize_with = "serialize_some_other_variant")]
6 | | Struct { 6 | | Struct {

View File

@ -1,5 +1,5 @@
error: variant `Struct` cannot have both #[serde(serialize_with)] and a field `f1` marked with #[serde(skip_serializing_if)] error: variant `Struct` cannot have both #[serde(serialize_with)] and a field `f1` marked with #[serde(skip_serializing_if)]
--> $DIR/skip_ser_struct_field_if.rs:5:5 --> $DIR/tests/ui/with-variant/skip_ser_struct_field_if.rs:5:5
| |
5 | / #[serde(serialize_with = "serialize_some_newtype_variant")] 5 | / #[serde(serialize_with = "serialize_some_newtype_variant")]
6 | | Struct { 6 | | Struct {

View File

@ -1,5 +1,5 @@
error: variant `Tuple` cannot have both #[serde(serialize_with)] and a field #0 marked with #[serde(skip_serializing)] error: variant `Tuple` cannot have both #[serde(serialize_with)] and a field #0 marked with #[serde(skip_serializing)]
--> $DIR/skip_ser_tuple_field.rs:5:5 --> $DIR/tests/ui/with-variant/skip_ser_tuple_field.rs:5:5
| |
5 | / #[serde(serialize_with = "serialize_some_other_variant")] 5 | / #[serde(serialize_with = "serialize_some_other_variant")]
6 | | Tuple(#[serde(skip_serializing)] String, u8), 6 | | Tuple(#[serde(skip_serializing)] String, u8),

View File

@ -1,5 +1,5 @@
error: variant `Tuple` cannot have both #[serde(serialize_with)] and a field #0 marked with #[serde(skip_serializing_if)] error: variant `Tuple` cannot have both #[serde(serialize_with)] and a field #0 marked with #[serde(skip_serializing_if)]
--> $DIR/skip_ser_tuple_field_if.rs:5:5 --> $DIR/tests/ui/with-variant/skip_ser_tuple_field_if.rs:5:5
| |
5 | / #[serde(serialize_with = "serialize_some_other_variant")] 5 | / #[serde(serialize_with = "serialize_some_other_variant")]
6 | | Tuple(#[serde(skip_serializing_if = "always")] String, u8), 6 | | Tuple(#[serde(skip_serializing_if = "always")] String, u8),

View File

@ -1,5 +1,5 @@
error: variant `Unit` cannot have both #[serde(serialize_with)] and #[serde(skip_serializing)] error: variant `Unit` cannot have both #[serde(serialize_with)] and #[serde(skip_serializing)]
--> $DIR/skip_ser_whole_variant.rs:5:5 --> $DIR/tests/ui/with-variant/skip_ser_whole_variant.rs:5:5
| |
5 | / #[serde(serialize_with = "serialize_some_unit_variant")] 5 | / #[serde(serialize_with = "serialize_some_unit_variant")]
6 | | #[serde(skip_serializing)] 6 | | #[serde(skip_serializing)]