Hi Ralph, > I can't spot anything to avoid \n($. counting \} from browsing the 7th > Ed. source.
Maybe this is because the parser should separate the terminal symbols belonging to a conditional block from statements inside the block. So when the macro call is parsed the \} should not be there anymore (and .$ does not need to account for it). > Note, 7th Ed. has been ported to x86 and can be run as a VM > if you want to test it. http://www.nordier.com/v7x86/ I did not get it to run in short-term, but I'll keep at it, thank you! > BTW, as well as \n(.$ including \} in its count, it naturally follows > that \$3, for example, is \}. It would be consistent but not desirable. And fortunately it is not the case. More often then .$ I use ".if ^G\\$3^G^G ..." and this works in this case (\$3 is empty). > Agreed. But documented to avoid surprises. I checked CSTR 54 and > couldn't find anything covering this. Yes, Werner had suggested this also and I reported the issue (that this behavior should be documented). I had expected that it is not mentioned in CSTR54. If this issue had been there already, J. Ossanna or B. Kernighan had not been aware of it--else they had fixed it (I am quite sure that it's a bug and not intentional.) Cheers, Carsten