userdiff.c: remove implicit dependency on the_index

[jc: squashed in missing forward decl in userdiff.h found by Ramsay]

Helped-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Nguyễn Thái Ngọc Duy
2018-09-21 17:57:33 +02:00
committed by Junio C Hamano
parent 35843b1123
commit acd00ea049
11 changed files with 61 additions and 41 deletions

3
diff.h
View File

@@ -455,7 +455,8 @@ size_t fill_textconv(struct repository *r,
* and only if it has textconv enabled (otherwise return NULL). The result
* can be passed to fill_textconv().
*/
struct userdiff_driver *get_textconv(struct diff_filespec *one);
struct userdiff_driver *get_textconv(struct index_state *istate,
struct diff_filespec *one);
/*
* Prepare diff_filespec and convert it using diff textconv API