]> Repositorios git - scryer-prolog.git/commitdiff
fail on parse error invoked by read/1
authorMark Thom <[email protected]>
Sat, 4 Aug 2018 20:56:38 +0000 (14:56 -0600)
committerMark Thom <[email protected]>
Sat, 4 Aug 2018 20:56:38 +0000 (14:56 -0600)
src/prolog/ast.rs

index 620a0ef7605363ad7097b5cc1d58127e255d1d5c..b4f033cd4c89b557ae2b47464cb0f6eab59727b3 100644 (file)
@@ -813,7 +813,7 @@ pub enum ClauseType {
     CallN,
     Inlined(InlinedClauseType),
     Named(ClauseName, CodeIndex),
-    Op(ClauseName, Fixity, CodeIndex),    
+    Op(ClauseName, Fixity, CodeIndex),
     System(SystemClauseType)
 }
 
@@ -862,7 +862,7 @@ impl ClauseName {
             &ClauseName::User(ref name) => name.as_ref()
         }
     }
-    
+
     pub fn defrock_brackets(self) -> Self {
         fn defrock_brackets(s: &str) -> &str {
             if s.starts_with('(') && s.ends_with(')') {
@@ -1019,7 +1019,7 @@ pub enum TermRef<'a> {
     Var(Level, &'a Cell<VarReg>, Rc<Var>)
 }
 
-impl<'a> TermRef<'a> {    
+impl<'a> TermRef<'a> {
     pub fn level(self) -> Level {
         match self {
             TermRef::AnonVar(lvl)
@@ -1600,7 +1600,10 @@ impl CodePtr {
 #[derive(Clone, PartialEq)]
 pub enum LocalCodePtr {
     DirEntry(usize, ClauseName), // offset, resident module name.
-    TopLevel(usize, usize) // chunk_num, offset.
+    TopLevel(usize, usize), // chunk_num, offset.
+    // DynamicModuleCall(ClauseName, ClauseName, usize)
+    // module name, predicate name and arity.
+    // used for internal, dynamic module calls.
 }
 
 impl LocalCodePtr {