]> Repositorios git - scryer-prolog.git/commitdiff
Leave residual goals for later
authorbakaq <[email protected]>
Thu, 12 Dec 2024 08:43:23 +0000 (05:43 -0300)
committerbakaq <[email protected]>
Thu, 12 Dec 2024 08:47:01 +0000 (05:47 -0300)
src/machine/lib_machine/mod.rs

index 62352919aa1fcc2fd61ed47230cb2eaeddd777bf..170fa2c92eb13f3c3f2af2dc70b22ff77c3d9dcc 100644 (file)
@@ -31,16 +31,12 @@ pub enum LeafAnswer {
     False,
     /// An exception leaf answer.
     Exception(Term),
-    /// A leaf answer with bindings and residual goals.
+    /// A leaf answer with bindings.
+    #[non_exhaustive]
     LeafAnswer {
         /// The bindings of variables in the query.
-        ///
-        /// Can be empty.
         bindings: BTreeMap<String, Term>,
-        /// Residual goals.
-        ///
-        /// Can be empty.
-        residual_goals: Vec<Term>,
+        //residual_goals: Vec<Term>,
     },
 }
 
@@ -49,7 +45,6 @@ impl LeafAnswer {
     pub fn from_bindings<S: Into<String>>(bindings: impl IntoIterator<Item = (S, Term)>) -> Self {
         LeafAnswer::LeafAnswer {
             bindings: bindings.into_iter().map(|(k, v)| (k.into(), v)).collect(),
-            residual_goals: Vec::new(),
         }
     }
 }