diff options
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | lib.c | 4 |
2 files changed, 9 insertions, 2 deletions
@@ -1,3 +1,10 @@ +2014-01-27 Kaz Kylheku <kaz@kylheku.com> + + * lib.c (obj_print, obj_pprint): Bugfix: there may be + additional expressions forms in (sys:var <sym>) after + the sym. These were not being printed. Such syntax occurs + often in the TXR pattern language. + 2014-01-26 Kaz Kylheku <kaz@kylheku.com> * regex.c (match_regex_right): New function. @@ -5049,7 +5049,7 @@ val obj_print(val obj, val out) } else if (sym == splice_s) { put_string(lit(",*"), out); obj_print(second(obj), out); - } else if (sym == var_s && symbolp(second(obj))) { + } else if (sym == var_s && symbolp(second(obj)) && !cdr(cdr(obj))) { put_char(chr('@'), out); obj_print(second(obj), out); } else if (sym == expr_s) { @@ -5214,7 +5214,7 @@ val obj_pprint(val obj, val out) } else if (sym == splice_s) { put_string(lit(",*"), out); obj_pprint(second(obj), out); - } else if (sym == var_s && symbolp(second(obj))) { + } else if (sym == var_s && symbolp(second(obj)) && !cdr(cdr(obj))) { put_char(chr('@'), out); obj_print(second(obj), out); } else if (sym == expr_s) { |