Mercurial > ~dholland > hg > tradcpp > index.cgi
comparison main.c @ 185:16b4451e34b8
Add the ability to output line numbers, sort of.
It is enabled with the intentionally undocumented -p option (similar
to -P but reversed sense) and it might be vaguely useful but only
prints the line number when the file changes and may not get the line
numbers right.
author | David A. Holland |
---|---|
date | Fri, 12 Jun 2015 03:59:36 -0400 |
parents | 4c3375895c6e |
children | 079304130850 |
comparison
equal
deleted
inserted
replaced
184:d359d9b86327 | 185:16b4451e34b8 |
---|---|
53 .do_stdinc = true, | 53 .do_stdinc = true, |
54 .do_stddef = true, | 54 .do_stddef = true, |
55 | 55 |
56 .do_output = true, | 56 .do_output = true, |
57 .output_linenumbers = true, | 57 .output_linenumbers = true, |
58 .output_cheaplinenumbers = false, | |
58 .output_retain_comments = false, | 59 .output_retain_comments = false, |
59 .output_file = NULL, | 60 .output_file = NULL, |
60 | 61 |
61 .do_depend = false, | 62 .do_depend = false, |
62 .depend_report_system = false, | 63 .depend_report_system = false, |
779 { "C", &mode.output_retain_comments, true }, | 780 { "C", &mode.output_retain_comments, true }, |
780 { "CC", &mode.output_retain_comments, true }, | 781 { "CC", &mode.output_retain_comments, true }, |
781 { "MG", &mode.depend_assume_generated, true }, | 782 { "MG", &mode.depend_assume_generated, true }, |
782 { "MP", &mode.depend_issue_fakerules, true }, | 783 { "MP", &mode.depend_issue_fakerules, true }, |
783 { "P", &mode.output_linenumbers, false }, | 784 { "P", &mode.output_linenumbers, false }, |
785 { "p", &mode.output_cheaplinenumbers, true }, | |
784 { "Wcomment", &warns.nestcomment, true }, | 786 { "Wcomment", &warns.nestcomment, true }, |
785 { "Wendif-labels", &warns.endiflabels, true }, | 787 { "Wendif-labels", &warns.endiflabels, true }, |
786 { "Werror", &mode.werror, true }, | 788 { "Werror", &mode.werror, true }, |
787 { "Wno-comment", &warns.nestcomment, false }, | 789 { "Wno-comment", &warns.nestcomment, false }, |
788 { "Wno-endif-labels", &warns.endiflabels, false }, | 790 { "Wno-endif-labels", &warns.endiflabels, false }, |