mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-06-14 08:11:02 +00:00
update benchmarks
This commit is contained in:
@@ -15,6 +15,7 @@ use serde::de::{self, Deserialize, Deserializer};
|
|||||||
use serde::json::ser::escape_str;
|
use serde::json::ser::escape_str;
|
||||||
use serde::json;
|
use serde::json;
|
||||||
use serde::ser::{self, Serialize, Serializer};
|
use serde::ser::{self, Serialize, Serializer};
|
||||||
|
use std::str::FromStr;
|
||||||
|
|
||||||
use rustc_serialize::Encodable;
|
use rustc_serialize::Encodable;
|
||||||
|
|
||||||
@@ -53,6 +54,11 @@ impl rustc_serialize::Decodable for HttpProtocol {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl FromStr for HttpProtocol {
|
||||||
|
type Err = ();
|
||||||
|
fn from_str(s: &str) -> Result<HttpProtocol, ()> { unimplemented!() }
|
||||||
|
}
|
||||||
|
|
||||||
impl FromPrimitive for HttpProtocol {
|
impl FromPrimitive for HttpProtocol {
|
||||||
fn from_i64(i: i64) -> Option<HttpProtocol> {
|
fn from_i64(i: i64) -> Option<HttpProtocol> {
|
||||||
FromPrimitive::from_u64(i as u64)
|
FromPrimitive::from_u64(i as u64)
|
||||||
@@ -101,6 +107,11 @@ enum HttpMethod {
|
|||||||
PATCH,
|
PATCH,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl FromStr for HttpMethod {
|
||||||
|
type Err = ();
|
||||||
|
fn from_str(s: &str) -> Result<HttpMethod, ()> { unimplemented!() }
|
||||||
|
}
|
||||||
|
|
||||||
impl FromPrimitive for HttpMethod {
|
impl FromPrimitive for HttpMethod {
|
||||||
fn from_i64(i: i64) -> Option<HttpMethod> {
|
fn from_i64(i: i64) -> Option<HttpMethod> {
|
||||||
FromPrimitive::from_u64(i as u64)
|
FromPrimitive::from_u64(i as u64)
|
||||||
@@ -165,6 +176,11 @@ enum CacheStatus {
|
|||||||
Hit,
|
Hit,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl FromStr for CacheStatus {
|
||||||
|
type Err = ();
|
||||||
|
fn from_str(s: &str) -> Result<CacheStatus, ()> { unimplemented!() }
|
||||||
|
}
|
||||||
|
|
||||||
impl FromPrimitive for CacheStatus {
|
impl FromPrimitive for CacheStatus {
|
||||||
fn from_i64(i: i64) -> Option<CacheStatus> {
|
fn from_i64(i: i64) -> Option<CacheStatus> {
|
||||||
FromPrimitive::from_u64(i as u64)
|
FromPrimitive::from_u64(i as u64)
|
||||||
@@ -229,6 +245,11 @@ enum OriginProtocol {
|
|||||||
HTTPS,
|
HTTPS,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl FromStr for OriginProtocol {
|
||||||
|
type Err = ();
|
||||||
|
fn from_str(s: &str) -> Result<OriginProtocol, ()> { unimplemented!() }
|
||||||
|
}
|
||||||
|
|
||||||
impl FromPrimitive for OriginProtocol {
|
impl FromPrimitive for OriginProtocol {
|
||||||
fn from_i64(i: i64) -> Option<OriginProtocol> {
|
fn from_i64(i: i64) -> Option<OriginProtocol> {
|
||||||
FromPrimitive::from_u64(i as u64)
|
FromPrimitive::from_u64(i as u64)
|
||||||
@@ -286,6 +307,11 @@ enum ZonePlan {
|
|||||||
ENT,
|
ENT,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl FromStr for ZonePlan {
|
||||||
|
type Err = ();
|
||||||
|
fn from_str(s: &str) -> Result<ZonePlan, ()> { unimplemented!() }
|
||||||
|
}
|
||||||
|
|
||||||
impl FromPrimitive for ZonePlan {
|
impl FromPrimitive for ZonePlan {
|
||||||
fn from_i64(i: i64) -> Option<ZonePlan> {
|
fn from_i64(i: i64) -> Option<ZonePlan> {
|
||||||
FromPrimitive::from_u64(i as u64)
|
FromPrimitive::from_u64(i as u64)
|
||||||
@@ -596,6 +622,11 @@ enum Country {
|
|||||||
ZW,
|
ZW,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl FromStr for Country {
|
||||||
|
type Err = ();
|
||||||
|
fn from_str(s: &str) -> Result<Country, ()> { unimplemented!() }
|
||||||
|
}
|
||||||
|
|
||||||
impl FromPrimitive for Country {
|
impl FromPrimitive for Country {
|
||||||
fn from_i64(i: i64) -> Option<Country> {
|
fn from_i64(i: i64) -> Option<Country> {
|
||||||
FromPrimitive::from_u64(i as u64)
|
FromPrimitive::from_u64(i as u64)
|
||||||
|
|||||||
Reference in New Issue
Block a user