config.txt: third-party tools may and do use their own variables
[gitweb.git] / line-log.h
index 9acd12361ad79186d1ce0bf2502e50f926cf4499..a9212d84e492304b4e57da1e0327189b3b6434ed 100644 (file)
@@ -25,11 +25,27 @@ struct diff_ranges {
        struct range_set target;
 };
 
+extern void range_set_init(struct range_set *, size_t prealloc);
+extern void range_set_release(struct range_set *);
+/* Range includes start; excludes end */
+extern void range_set_append_unsafe(struct range_set *, long start, long end);
+/* New range must begin at or after end of last added range */
+extern void range_set_append(struct range_set *, long start, long end);
+/*
+ * In-place pass of sorting and merging the ranges in the range set,
+ * to sort and make the ranges disjoint.
+ */
+extern void sort_and_merge_range_set(struct range_set *);
+
 /* Linked list of interesting files and their associated ranges.  The
- * list must be kept sorted by spec->path */
+ * list must be kept sorted by path.
+ *
+ * For simplicity, even though this is highly redundant, each
+ * line_log_data owns its 'path'.
+ */
 struct line_log_data {
        struct line_log_data *next;
-       struct diff_filespec *spec;
+       char *path;
        char status;
        struct range_set ranges;
        int arg_alloc, arg_nr;