> They aren't "cannibalized", they are still there, where the source > ref says they are.
I was thinking along the lines of using parse() to unambiguously associate a comment block with a code object; sure, srcref() retains them: but that's no different than parsing a text file. If I can't associate comment with code in parse(), I don't see how I can avoid reimplementing the R parser; at least far enough to identify top-level objects (but why stop there?). By "cannibalizing", I'm referring to the following; take trivial.R: # Comment relevant to foo foo <- "bar" attributes(parse("trivial.R"))$srcref[[1]] returns: foo <- "bar" which is consistent with SkipComment. ______________________________________________ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel