quote dot when quoted(true) (#349)

This commit is contained in:
Mark Thom
2020-04-15 00:54:32 -06:00
parent a9a5e79e85
commit 8d95eb57fa
3 changed files with 6 additions and 3 deletions

View File

@@ -442,7 +442,7 @@ fn non_quoted_token<Iter: Iterator<Item = char>>(mut iter: Iter) -> bool {
if let Some(c) = iter.next() {
if small_letter_char!(c) {
iter.all(|c| alpha_numeric_char!(c))
} else if graphic_token_char!(c) {
} else if c != '.' && graphic_token_char!(c) {
non_quoted_graphic_token(iter, c)
} else if semicolon_char!(c) {
iter.next().is_none()
@@ -1116,7 +1116,7 @@ impl<'a, Outputter: HCValueOutputter> HCPrinter<'a, Outputter> {
let mut char_count = 0;
for c in buf_iter {
self.push_char('.');
self.append_str("'.'");
self.push_char('(');
char_printer(self, c);

View File

@@ -123,6 +123,7 @@
atom(Value),
atom_chars(Value, ValueChars),
'$list_last_item'(ValueChars, Char),
Char \== '.',
'$graphic_token_char'(Char).
'$write_eqs_and_read_input'(B, VarList) :-