Mercurial > ~dholland > hg > tradcpp > index.cgi
comparison files.c @ 199:1d2bad7151f9
Add a -debuglog option to send an execution trace to a file.
Intended to be used when debugging imake templates and other complex
input, not for debugging tradcpp itself.
author | David A. Holland |
---|---|
date | Sun, 04 Sep 2016 17:14:42 -0400 |
parents | 8c7e508da6cc |
children | 3a25180d3a5c |
comparison
equal
deleted
inserted
replaced
198:4158b974e23f | 199:1d2bad7151f9 |
---|---|
179 bool ateof = false; | 179 bool ateof = false; |
180 char *buf; | 180 char *buf; |
181 | 181 |
182 place_setfilestart(&places.current, pf); | 182 place_setfilestart(&places.current, pf); |
183 places.nextline = places.current; | 183 places.nextline = places.current; |
184 | |
185 if (name) { | |
186 debuglog(&places.current, "Reading file %s", name); | |
187 } else { | |
188 debuglog(&places.current, "Reading standard input"); | |
189 } | |
184 | 190 |
185 bufmax = 128; | 191 bufmax = 128; |
186 bufend = 0; | 192 bufend = 0; |
187 linestart = 0; | 193 linestart = 0; |
188 lineend = 0; | 194 lineend = 0; |