summaryrefslogtreecommitdiff
path: root/dhall/src/error
diff options
context:
space:
mode:
authorNadrieril Feneanar2019-12-24 20:41:22 +0000
committerGitHub2019-12-24 20:41:22 +0000
commit057d645a90a6b57f40f72eb7e347ba2c6219777e (patch)
tree151473a0a6cb7222fd6b4eb3abf1cfacca012aad /dhall/src/error
parent06e75c919d999c310f8ca1c151c6a5ad6918ca08 (diff)
parent18dd5ba3ae94fd89dd27c0ae3891ac3e43ace350 (diff)
Merge pull request #124 from Nadrieril/catchup-spec
Catchup on standard changes
Diffstat (limited to 'dhall/src/error')
-rw-r--r--dhall/src/error/mod.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/dhall/src/error/mod.rs b/dhall/src/error/mod.rs
index 1288c12..6e7be64 100644
--- a/dhall/src/error/mod.rs
+++ b/dhall/src/error/mod.rs
@@ -67,7 +67,7 @@ pub(crate) enum TypeMessage {
BinOpTypeMismatch(BinOp, Value),
InvalidTextInterpolation(Value),
Merge1ArgMustBeRecord(Value),
- Merge2ArgMustBeUnion(Value),
+ Merge2ArgMustBeUnionOrOptional(Value),
MergeEmptyNeedsAnnotation,
MergeHandlerMissingVariant(Label),
MergeVariantMissingHandler(Label),
@@ -76,6 +76,7 @@ pub(crate) enum TypeMessage {
MergeHandlerReturnTypeMustNotBeDependent,
ProjectionMustBeRecord,
ProjectionMissingEntry,
+ ProjectionDuplicateField,
Sort,
RecordTypeDuplicateField,
RecordTypeMergeRequiresRecordType(Value),
@@ -124,7 +125,7 @@ impl std::fmt::Display for TypeError {
y
))
}
- _ => "Type error: Unhandled error".to_string(),
+ _ => format!("Type error: Unhandled error: {:?}", self.message),
};
write!(f, "{}", msg)
}