summaryrefslogtreecommitdiff
path: root/serde_dhall
diff options
context:
space:
mode:
authorNadrieril2020-04-05 17:37:15 +0100
committerNadrieril2020-04-05 17:43:38 +0100
commit820214615547101f8f2b5de209b5189968bddfee (patch)
treead4249609707fd8720a44469152105c2f6a67c79 /serde_dhall
parentc4d9e73126131d31e707822b0fd8b0710363c863 (diff)
Fix clippy warnings
Diffstat (limited to 'serde_dhall')
-rw-r--r--serde_dhall/src/static_type.rs6
-rw-r--r--serde_dhall/src/value.rs4
2 files changed, 4 insertions, 6 deletions
diff --git a/serde_dhall/src/static_type.rs b/serde_dhall/src/static_type.rs
index f7b72b5..26c70cd 100644
--- a/serde_dhall/src/static_type.rs
+++ b/serde_dhall/src/static_type.rs
@@ -117,7 +117,6 @@ where
.into_iter()
.collect(),
)
- .into()
}
}
@@ -135,7 +134,6 @@ where
.into_iter()
.collect(),
)
- .into()
}
}
@@ -144,7 +142,7 @@ where
T: StaticType,
{
fn static_type() -> SimpleType {
- SimpleType::Optional(Box::new(T::static_type())).into()
+ SimpleType::Optional(Box::new(T::static_type()))
}
}
@@ -153,7 +151,7 @@ where
T: StaticType,
{
fn static_type() -> SimpleType {
- SimpleType::List(Box::new(T::static_type())).into()
+ SimpleType::List(Box::new(T::static_type()))
}
}
diff --git a/serde_dhall/src/value.rs b/serde_dhall/src/value.rs
index 7baeee9..d6631da 100644
--- a/serde_dhall/src/value.rs
+++ b/serde_dhall/src/value.rs
@@ -226,12 +226,12 @@ impl SimpleType {
ExprKind::App(hir(ExprKind::Builtin(Builtin::List)), t.to_hir())
}
SimpleType::Record(kts) => ExprKind::RecordType(
- kts.into_iter()
+ kts.iter()
.map(|(k, t)| (k.as_str().into(), t.to_hir()))
.collect(),
),
SimpleType::Union(kts) => ExprKind::UnionType(
- kts.into_iter()
+ kts.iter()
.map(|(k, t)| {
(k.as_str().into(), t.as_ref().map(|t| t.to_hir()))
})