refactor: convert macros to all-caps (#17895)

Closes https://github.com/neovim/neovim/issues/6297
This commit is contained in:
dundargoc
2022-04-25 04:18:43 +02:00
committed by GitHub
parent 7813fa2f8c
commit 0648100fed
34 changed files with 143 additions and 147 deletions

View File

@@ -418,7 +418,7 @@ void ml_setname(buf_T *buf)
}
// if the file name is the same we don't have to do anything
if (fnamecmp(fname, mfp->mf_fname) == 0) {
if (FNAMECMP(fname, mfp->mf_fname) == 0) {
xfree(fname);
success = true;
break;
@@ -3459,7 +3459,7 @@ static char *findswapname(buf_T *buf, char **dirp, char *old_fname, bool *found_
}
// A file name equal to old_fname is OK to use.
if (old_fname != NULL && fnamecmp(fname, old_fname) == 0) {
if (old_fname != NULL && FNAMECMP(fname, old_fname) == 0) {
break;
}
@@ -3484,7 +3484,7 @@ static char *findswapname(buf_T *buf, char **dirp, char *old_fname, bool *found_
// buffer don't compare the directory names, they can
// have a different mountpoint.
if (b0.b0_flags & B0_SAME_DIR) {
if (fnamecmp(path_tail(buf->b_ffname),
if (FNAMECMP(path_tail(buf->b_ffname),
path_tail(b0.b0_fname)) != 0
|| !same_directory((char_u *)fname, buf->b_ffname)) {
// Symlinks may point to the same file even