summaryrefslogtreecommitdiffstats
path: root/parser.h
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2011-11-15 20:15:11 -0800
committerKaz Kylheku <kaz@kylheku.com>2011-11-15 20:15:11 -0800
commit21483995aba924e6d1f3472fc68cf8a3d0ae4959 (patch)
tree249f8fd762726c2920a3a5c3f321662ec3def7c3 /parser.h
parentb6551fda77163f74983688409aaf0c13c8186bec (diff)
downloadtxr-21483995aba924e6d1f3472fc68cf8a3d0ae4959.tar.gz
txr-21483995aba924e6d1f3472fc68cf8a3d0ae4959.tar.bz2
txr-21483995aba924e6d1f3472fc68cf8a3d0ae4959.zip
* match.c (h_var): when manipulating specline, propagate the
source locatio info. (v_skip): Don't use specline for trace messages, because it may be nil. Use the skip spec. * parser.h (rl): Declared. (rlcp): New inline function. * parser.y (rl): Static declaration removed. Function becomes extern. (clause): Propagate location info from clause to clause list backbone. (collect_clause, COLL): Bugfix: car/cdr mixup in location info. (elem): Use rlcp function to abbreviate code. (o_elems_opt, o_elems_opt2, o_elem): Set location info.
Diffstat (limited to 'parser.h')
-rw-r--r--parser.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/parser.h b/parser.h
index 754282d5..101acba7 100644
--- a/parser.h
+++ b/parser.h
@@ -41,3 +41,8 @@ void end_of_char(void);
int yylex(void);
void parse_init(void);
val source_loc(val form);
+val rl(val form, val lineno);
+INLINE val rlcp(val to, val from)
+{
+ return rl(to, source_loc(from));
+}