From a8509a1d03e96f6d85c50f2a1154f3fb2962f3ea Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Fri, 1 Apr 2016 09:55:54 -0700 Subject: [PATCH] Add missing close brackets in readme --- README.md | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/README.md b/README.md index 80738372..64fa1da8 100644 --- a/README.md +++ b/README.md @@ -689,34 +689,34 @@ how types are serialized. Here are the supported annotations: Container Annotations: -| Annotation | Function | -| ---------- | -------- | -| `#[serde(rename="name")` | Serialize and deserialize this container with the given name | -| `#[serde(rename(serialize="name1"))` | Serialize this container with the given name | -| `#[serde(rename(deserialize="name1"))` | Deserialize this container with the given name | -| `#[serde(deny_unknown_fields)` | Always error during serialization when encountering unknown fields. When absent, unknown fields are ignored for self-describing formats like JSON. | +| Annotation | Function | +| ---------- | -------- | +| `#[serde(rename="name")]` | Serialize and deserialize this container with the given name | +| `#[serde(rename(serialize="name1"))]` | Serialize this container with the given name | +| `#[serde(rename(deserialize="name1"))]` | Deserialize this container with the given name | +| `#[serde(deny_unknown_fields)]` | Always error during serialization when encountering unknown fields. When absent, unknown fields are ignored for self-describing formats like JSON. | Variant Annotations: -| Annotation | Function | -| ---------- | -------- | -| `#[serde(rename="name")` | Serialize and deserialize this variant with the given name | -| `#[serde(rename(serialize="name1"))` | Serialize this variant with the given name | -| `#[serde(rename(deserialize="name1"))` | Deserialize this variant with the given name | +| Annotation | Function | +| ---------- | -------- | +| `#[serde(rename="name")]` | Serialize and deserialize this variant with the given name | +| `#[serde(rename(serialize="name1"))]` | Serialize this variant with the given name | +| `#[serde(rename(deserialize="name1"))]` | Deserialize this variant with the given name | Field Annotations: -| Annotation | Function | -| ---------- | -------- | -| `#[serde(rename="name")` | Serialize and deserialize this field with the given name | -| `#[serde(rename(serialize="name1"))` | Serialize this field with the given name | -| `#[serde(rename(deserialize="name1"))` | Deserialize this field with the given name | -| `#[serde(default)` | If the value is not specified, use the `Default::default()` | -| `#[serde(default="$path")` | Call the path to a function `fn() -> T` to build the value | -| `#[serde(skip_serializing)` | Do not serialize this value | -| `#[serde(skip_serializing_if="$path")` | Do not serialize this value if this function `fn(&T) -> bool` returns `false` | -| `#[serde(serialize_with="$path")` | Call a function `fn(&T, &mut S) -> Result<(), S::Error> where S: Serializer` to serialize this value | -| `#[serde(deserialize_with="$path")` | Call a function `fn(&mut D) -> Result where D: Deserializer` to deserialize this value | +| Annotation | Function | +| ---------- | -------- | +| `#[serde(rename="name")]` | Serialize and deserialize this field with the given name | +| `#[serde(rename(serialize="name1"))]` | Serialize this field with the given name | +| `#[serde(rename(deserialize="name1"))]` | Deserialize this field with the given name | +| `#[serde(default)]` | If the value is not specified, use the `Default::default()` | +| `#[serde(default="$path")]` | Call the path to a function `fn() -> T` to build the value | +| `#[serde(skip_serializing)]` | Do not serialize this value | +| `#[serde(skip_serializing_if="$path")]` | Do not serialize this value if this function `fn(&T) -> bool` returns `false` | +| `#[serde(serialize_with="$path")]` | Call a function `fn(&T, &mut S) -> Result<(), S::Error> where S: Serializer` to serialize this value | +| `#[serde(deserialize_with="$path")]` | Call a function `fn(&mut D) -> Result where D: Deserializer` to deserialize this value | Upgrading from Serde 0.6 ========================