summaryrefslogtreecommitdiff
path: root/dhall/tests/traits.rs
diff options
context:
space:
mode:
authorNadrieril2019-04-07 18:04:45 +0200
committerNadrieril2019-04-07 18:04:45 +0200
commit21b1fda39e51d157dadbfbb2aeb0f542a9506fcf (patch)
tree09012b2d9294a58455b74e8bd0e041f7cb153a23 /dhall/tests/traits.rs
parent727c5219c9af55df3e61fb372fa2fadecdd15b18 (diff)
parent4bebcd96b6e76b9b8ae7877af91d2ae571e617a9 (diff)
Merge branch 'statemachine-api'
Diffstat (limited to '')
-rw-r--r--dhall/tests/traits.rs (renamed from dhall/tests/dhall_type.rs)14
1 files changed, 7 insertions, 7 deletions
diff --git a/dhall/tests/dhall_type.rs b/dhall/tests/traits.rs
index 941e3a4..ac6b5e6 100644
--- a/dhall/tests/dhall_type.rs
+++ b/dhall/tests/traits.rs
@@ -1,5 +1,5 @@
#![feature(proc_macro_hygiene)]
-use dhall::Type;
+use dhall::StaticType;
use dhall_generator::dhall_expr;
#[test]
@@ -11,18 +11,18 @@ fn test_dhall_type() {
dhall_expr!({ _1: Bool, _2: Optional Text })
);
- #[derive(dhall::Type)]
+ #[derive(dhall::StaticType)]
#[allow(dead_code)]
struct A {
field1: bool,
field2: Option<bool>,
}
assert_eq!(
- <A as dhall::Type>::get_type(),
+ <A as dhall::StaticType>::get_type(),
dhall_expr!({ field1: Bool, field2: Optional Bool })
);
- #[derive(Type)]
+ #[derive(StaticType)]
#[allow(dead_code)]
struct B<'a, T: 'a> {
field1: &'a T,
@@ -30,12 +30,12 @@ fn test_dhall_type() {
}
assert_eq!(<B<'static, bool>>::get_type(), A::get_type());
- #[derive(Type)]
+ #[derive(StaticType)]
#[allow(dead_code)]
struct C<T>(T, Option<String>);
assert_eq!(<C<bool>>::get_type(), <(bool, Option<String>)>::get_type());
- #[derive(Type)]
+ #[derive(StaticType)]
#[allow(dead_code)]
struct D();
assert_eq!(
@@ -43,7 +43,7 @@ fn test_dhall_type() {
dhall_expr!({ _1: {}, _2: Optional Text })
);
- #[derive(Type)]
+ #[derive(StaticType)]
#[allow(dead_code)]
enum E<T> {
A(T),