Path: utzoo!utgpu!news-server.csri.toronto.edu!mailrus!iuvax!ndcvb!dierks From: dierks@ndcvb.cc.nd.edu (Timothy Dierks) Newsgroups: comp.sys.mac.programmer Subject: Re: MPW 2.0 and 3.0/3.1 Message-ID: <198@ndcvb.cc.nd.edu> Date: 9 May 90 17:13:58 GMT References: <3238@rodan.acs.syr.edu> Distribution: usa Organization: OUC , University of Notre Dame Lines: 20 From article <3238@rodan.acs.syr.edu>, by dinapoli@rodan.acs.syr.edu (Ron DiNapoli): > Anybody see the problem? In MPW C 3.0 and later, the '//' symbol stands > for a comment. It also seems that the preprocessor is unable to detect > that this particular comment character is occurring within a string. > > Note how in the first occurrance of the PRINTIT macro, the text between the > /* */ comment characters does not appear. This tells me that in the 3.0/3.1 > C preprocessor, comments are "taken out" regardless of where they appear. And he quoteth from the book of Kernighan and Ritchie, Appendix A, Section A2.2: The characters /* introduce a comment, which terminates with the characters */. Comments do not nest, and they do not occur within string or character literals. Here endeth the lesson. Tim Dierks dierks@ndcvb.cc.nd.edu Go Irish! Only >11< days to those silly hats.