about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--tvix/eval/src/errors.rs4
-rw-r--r--tvix/eval/src/value/attrs.rs6
2 files changed, 1 insertions, 9 deletions
diff --git a/tvix/eval/src/errors.rs b/tvix/eval/src/errors.rs
index 4b4610f1e9..e262d9def4 100644
--- a/tvix/eval/src/errors.rs
+++ b/tvix/eval/src/errors.rs
@@ -6,10 +6,6 @@ pub enum Error {
         key: String,
     },
 
-    InvalidKeyType {
-        given: &'static str,
-    },
-
     AttributeNotFound {
         name: String,
     },
diff --git a/tvix/eval/src/value/attrs.rs b/tvix/eval/src/value/attrs.rs
index 76a0fe3cf6..03c12a6617 100644
--- a/tvix/eval/src/value/attrs.rs
+++ b/tvix/eval/src/value/attrs.rs
@@ -256,11 +256,7 @@ impl NixAttrs {
                     continue;
                 }
 
-                other => {
-                    return Err(Error::InvalidKeyType {
-                        given: other.type_of(),
-                    })
-                }
+                other => panic!("unexpected attribute key type: {}", other.type_of()),
             }
         }