Debian Codegraph @

debian/patches/fix-serde-json-feature.patch

raw
1 Index: cc-traits/src/impls/serde_json.rs
2 ===================================================================
3 --- cc-traits.orig/src/impls/serde_json.rs
4 +++ cc-traits/src/impls/serde_json.rs
5 @@ -3,7 +3,10 @@ use crate::{
6 Len, MapInsert, MapIter, MapIterMut, Remove, SimpleCollectionMut, SimpleCollectionRef,
7 SimpleKeyedRef,
8 };
9 -use std::{borrow::Borrow, cmp::Ord, hash::Hash};
10 +use core::{borrow::Borrow, cmp::Ord, hash::Hash};
11 +
12 +#[cfg(not(feature = "std"))]
13 +use alloc::string::String;
14
15 impl Collection for serde_json::Map<String, serde_json::Value> {
16 type Item = serde_json::Value;
17 Index: cc-traits/Cargo.toml
18 ===================================================================
19 --- cc-traits.orig/Cargo.toml
20 +++ cc-traits/Cargo.toml
21 @@ -54,3 +54,7 @@ default = [
22 "std",
23 ]
24 std = []
25 +serde_json = [
26 + "dep:serde_json",
27 + "alloc"
28 +]