summaryrefslogtreecommitdiff
path: root/src/compute/scope.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/compute/scope.rs')
-rw-r--r--src/compute/scope.rs9
1 files changed, 1 insertions, 8 deletions
diff --git a/src/compute/scope.rs b/src/compute/scope.rs
index 1c297fde..3ab56561 100644
--- a/src/compute/scope.rs
+++ b/src/compute/scope.rs
@@ -8,16 +8,14 @@ use super::value::FuncValue;
/// A map from identifiers to functions.
pub struct Scope {
functions: HashMap<String, FuncValue>,
- fallback: FuncValue,
}
impl Scope {
// Create a new empty scope with a fallback function that is invoked when no
// match is found.
- pub fn new(fallback: FuncValue) -> Self {
+ pub fn new() -> Self {
Self {
functions: HashMap::new(),
- fallback,
}
}
@@ -30,11 +28,6 @@ impl Scope {
pub fn func(&self, name: &str) -> Option<&FuncValue> {
self.functions.get(name)
}
-
- /// Return the fallback function.
- pub fn fallback(&self) -> &FuncValue {
- &self.fallback
- }
}
impl Debug for Scope {