diff options
author | Malte Dehling <mdehling@gmail.com> | 2024-05-27 04:14:57 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-05-27 04:14:57 -0700 |
commit | 104800ce2eadd21475b5a4897265a8a177e58d77 (patch) | |
tree | 08650929d2c0815cfc1d88211fab799b83b427d1 /src/nvim/api/vim.c | |
parent | 9a0239fdc8b380a8a32739a7c722fe90e3c2e910 (diff) | |
download | rneovim-104800ce2eadd21475b5a4897265a8a177e58d77.tar.gz rneovim-104800ce2eadd21475b5a4897265a8a177e58d77.tar.bz2 rneovim-104800ce2eadd21475b5a4897265a8a177e58d77.zip |
build: "popcount" name conflict on NetBSD #28983
Problem:
NetBSD's libc already has a function by the same name.
Solution:
Rename popcount to xpopcount and add #if defined(__NetBSD__) to
prefer NetBSD's own implementation. This fixes #28983.
Diffstat (limited to 'src/nvim/api/vim.c')
-rw-r--r-- | src/nvim/api/vim.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/api/vim.c b/src/nvim/api/vim.c index fc780e1248..52ab18cbff 100644 --- a/src/nvim/api/vim.c +++ b/src/nvim/api/vim.c @@ -2354,8 +2354,8 @@ void nvim__redraw(Dict(redraw) *opts, Error *err) } } - int count = (win != NULL) + (buf != NULL); - VALIDATE(popcount(opts->is_set__redraw_) > count, "%s", "at least one action required", { + unsigned count = (win != NULL) + (buf != NULL); + VALIDATE(xpopcount(opts->is_set__redraw_) > count, "%s", "at least one action required", { return; }); |