+/* Find, and write to ENCLOSER, the nearest line before POS which
matches
+ ENCLOSER_PATTERN. We remember the last line scanned, and the
matched, to
+ avoid duplication of effort. */
+
+void
+hunk_consumer::find_encloser(size_t pos, string encloser)
+{
+ typedef
On Tue, Jul 11, 2006 at 02:48:22PM -0700, Zack Weinberg wrote:
On 7/11/06, Nathaniel Smith [EMAIL PROTECTED] wrote:
+/* Find, and write to ENCLOSER, the nearest line before POS which
matches
+ ENCLOSER_PATTERN. We remember the last line scanned, and the
matched, to
+ avoid duplication of
Not really pointers, just iterators and a lot of complicated
vector-index arithmetic, but see attached; maybe it's clearer?
std::vector iterators are pretty thin wrappers around pointers -- have
a lot of the same risks. The patch looks fine; I just feel more
warm-and-fuzzy when complicated