User loginNavigation |
What to do about comments?This question has been bugging me for a while: whats the standard practice of handling comments during parsing? Ignore them or annotate the parsetree? My first thought is to simply let the lexer discard comments. But if the goal is to reproduce the source of the program via a pretty printer or some such, the comments need to come a long for the ride? What leads me to this line of inquiry is: If I'm a client purchasing a parser should I expect my $20,000 C++ parser (for example, I've read C++ parsers are expensive) to preserve comments? By markt at 2008-07-21 22:53 | LtU Forum | previous forum topic | next forum topic | other blogs | 12432 reads
|
Browse archives
Active forum topics
|
Recent comments
9 weeks 5 days ago
14 weeks 3 hours ago
15 weeks 4 days ago
15 weeks 4 days ago
18 weeks 2 days ago
22 weeks 6 days ago
22 weeks 6 days ago
23 weeks 2 days ago
23 weeks 2 days ago
26 weeks 1 day ago