replace {pre,suf}fixcmp() with {starts,ends}_with()
authorChristian Couder <chriscool@tuxfamily.org>
Sat, 30 Nov 2013 20:55:40 +0000 (21:55 +0100)
committerJunio C Hamano <gitster@pobox.com>
Thu, 5 Dec 2013 22:13:21 +0000 (14:13 -0800)
commit59556548230e617b837343c2c07e357e688e2ca4
tree5e66894c3d666f0fdc39aaf79de554dfeb7d0e36
parent956623157f828b2b4fd91a9bc5e78ba8e42437d9
replace {pre,suf}fixcmp() with {starts,ends}_with()

Leaving only the function definitions and declarations so that any
new topic in flight can still make use of the old functions, replace
existing uses of the prefixcmp() and suffixcmp() with new API
functions.

The change can be recreated by mechanically applying this:

    $ git grep -l -e prefixcmp -e suffixcmp -- \*.c |
      grep -v strbuf\\.c |
      xargs perl -pi -e '
        s|!prefixcmp\(|starts_with\(|g;
        s|prefixcmp\(|!starts_with\(|g;
        s|!suffixcmp\(|ends_with\(|g;
        s|suffixcmp\(|!ends_with\(|g;
      '

on the result of preparatory changes in this series.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
88 files changed:
alias.c
attr.c
bisect.c
branch.c
builtin/apply.c
builtin/archive.c
builtin/branch.c
builtin/checkout.c
builtin/clean.c
builtin/clone.c
builtin/column.c
builtin/commit.c
builtin/describe.c
builtin/fast-export.c
builtin/fetch-pack.c
builtin/fetch.c
builtin/fmt-merge-msg.c
builtin/for-each-ref.c
builtin/fsck.c
builtin/help.c
builtin/index-pack.c
builtin/init-db.c
builtin/log.c
builtin/ls-remote.c
builtin/mailinfo.c
builtin/merge-recursive.c
builtin/merge.c
builtin/name-rev.c
builtin/notes.c
builtin/pack-objects.c
builtin/prune.c
builtin/receive-pack.c
builtin/reflog.c
builtin/remote.c
builtin/repack.c
builtin/rev-parse.c
builtin/send-pack.c
builtin/shortlog.c
builtin/show-branch.c
builtin/show-ref.c
builtin/symbolic-ref.c
builtin/tag.c
builtin/unpack-objects.c
builtin/update-ref.c
builtin/upload-archive.c
commit.c
config.c
connect.c
connected.c
convert.c
daemon.c
diff.c
environment.c
fast-import.c
fetch-pack.c
git.c
help.c
http-backend.c
http-push.c
http.c
imap-send.c
log-tree.c
merge-recursive.c
notes-utils.c
notes.c
pager.c
parse-options.c
pathspec.c
pkt-line.c
pretty.c
refs.c
remote-curl.c
remote-testsvn.c
remote.c
revision.c
send-pack.c
sequencer.c
setup.c
sha1_name.c
shell.c
submodule.c
tag.c
test-line-buffer.c
test-string-list.c
transport-helper.c
transport.c
upload-pack.c
wt-status.c