Merge branch 'bw/diff-opt-impl-to-bitfields'

A single-word "unsigned flags" in the diff options is being split
into a structure with many bitfields.

* bw/diff-opt-impl-to-bitfields:
  diff: make struct diff_flags members lowercase
  diff: remove DIFF_OPT_CLR macro
  diff: remove DIFF_OPT_SET macro
  diff: remove DIFF_OPT_TST macro
  diff: remove touched flags
  diff: add flag to indicate textconv was set via cmdline
  diff: convert flags to be stored in bitfields
  add, reset: use DIFF_OPT_SET macro to set a diff flag
This commit is contained in:
Junio C Hamano
2017-11-09 14:31:27 +09:00
27 changed files with 259 additions and 245 deletions

View File

@ -959,7 +959,8 @@ static int do_pick_commit(enum todo_command command, struct commit *commit,
unborn = get_oid("HEAD", &head);
if (unborn)
oidcpy(&head, &empty_tree_oid);
if (index_differs_from(unborn ? EMPTY_TREE_SHA1_HEX : "HEAD", 0, 0))
if (index_differs_from(unborn ? EMPTY_TREE_SHA1_HEX : "HEAD",
NULL, 0))
return error_dirty_index(opts);
}
discard_cache();
@ -2283,7 +2284,7 @@ int sequencer_continue(struct replay_opts *opts)
if (res)
goto release_todo_list;
}
if (index_differs_from("HEAD", 0, 0)) {
if (index_differs_from("HEAD", NULL, 0)) {
res = error_dirty_index(opts);
goto release_todo_list;
}