consume whitespace before reading a term in loader.pl, modify prolog_load_context at file key to better reflect loading context, use it when reporting singleton variables (#812)

This commit is contained in:
Mark Thom
2021-02-22 13:23:22 -07:00
parent 5f8bdc564b
commit 1a9f6f06df
6 changed files with 62 additions and 70 deletions

View File

@@ -306,6 +306,7 @@ pub enum SystemClauseType {
SetEnv,
UnsetEnv,
CharsBase64,
DevourWhitespace,
}
impl SystemClauseType {
@@ -594,6 +595,7 @@ impl SystemClauseType {
&SystemClauseType::UnsetEnv => clause_name!("$unsetenv"),
&SystemClauseType::CharsBase64 => clause_name!("$chars_base64"),
&SystemClauseType::LoadLibraryAsStream => clause_name!("$load_library_as_stream"),
&SystemClauseType::DevourWhitespace => clause_name!("$devour_whitespace"),
}
}
@@ -841,6 +843,9 @@ impl SystemClauseType {
("$cpp_discontiguous_property", 3) => {
Some(SystemClauseType::REPL(REPLCodePtr::DiscontiguousProperty))
}
("$devour_whitespace", 1) => {
Some(SystemClauseType::DevourWhitespace)
}
_ => None,
}
}