50 lines
1.5 KiB
Diff
50 lines
1.5 KiB
Diff
|
From 46ee5ff92f94e7cf7c855aa1629325a8eb28d990 Mon Sep 17 00:00:00 2001
|
||
|
From: Igor Gnatenko <ignatenko@redhat.com>
|
||
|
Date: Mon, 1 Jan 2018 23:53:59 +0100
|
||
|
Subject: [PATCH] Bump serde_cbor to 0.8 (#167)
|
||
|
|
||
|
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
|
||
|
---
|
||
|
src/input.rs | 2 +-
|
||
|
src/language/languages.rs | 4 ++--
|
||
|
2 files changed, 3 insertions(+), 3 deletions(-)
|
||
|
|
||
|
diff --git a/src/input.rs b/src/input.rs
|
||
|
index 3ce6092..63ff3ed 100644
|
||
|
--- a/src/input.rs
|
||
|
+++ b/src/input.rs
|
||
|
@@ -65,7 +65,7 @@ mod io {
|
||
|
}
|
||
|
|
||
|
#[cfg(feature = "cbor")]
|
||
|
- pub fn from_cbor(contents: &String) -> serde_cbor::Result<LanguageMap> {
|
||
|
+ pub fn from_cbor(contents: &String) -> serde_cbor::error::Result<LanguageMap> {
|
||
|
use self::hex::FromHex;
|
||
|
use std::error::Error;
|
||
|
use std::process;
|
||
|
diff --git a/src/language/languages.rs b/src/language/languages.rs
|
||
|
index ba996db..d590140 100644
|
||
|
--- a/src/language/languages.rs
|
||
|
+++ b/src/language/languages.rs
|
||
|
@@ -191,7 +191,7 @@ impl Languages {
|
||
|
/// # }
|
||
|
/// ```
|
||
|
#[cfg(feature = "cbor")]
|
||
|
- pub fn from_cbor(cbor: &[u8]) -> serde_cbor::Result<Self> {
|
||
|
+ pub fn from_cbor(cbor: &[u8]) -> serde_cbor::error::Result<Self> {
|
||
|
Ok(Self::from_previous(serde_cbor::from_slice(cbor.into())?))
|
||
|
}
|
||
|
|
||
|
@@ -353,7 +353,7 @@ impl Languages {
|
||
|
/// # }
|
||
|
/// ```
|
||
|
#[cfg(feature = "cbor")]
|
||
|
- pub fn to_cbor(self) -> Result<Vec<u8>, serde_cbor::Error> {
|
||
|
+ pub fn to_cbor(self) -> Result<Vec<u8>, serde_cbor::error::Error> {
|
||
|
serde_cbor::to_vec(&self.remove_empty())
|
||
|
}
|
||
|
|
||
|
--
|
||
|
2.15.1
|
||
|
|