From 353a4be7e84fdc101318215bdcc8a7e780d737fe Mon Sep 17 00:00:00 2001 From: dundargoc Date: Sun, 12 Nov 2023 13:13:58 +0100 Subject: build: remove PVS We already have an extensive suite of static analysis tools we use, which causes a fair bit of redundancy as we get duplicate warnings. PVS is also prone to give false warnings which creates a lot of work to identify and disable. --- src/nvim/rbuffer.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/nvim/rbuffer.h') diff --git a/src/nvim/rbuffer.h b/src/nvim/rbuffer.h index 63d5119004..dddf34b095 100644 --- a/src/nvim/rbuffer.h +++ b/src/nvim/rbuffer.h @@ -38,8 +38,6 @@ struct rbuffer; // // Note that the rbuffer_{produced,consumed} calls are necessary or these macros // create infinite loops -// -// -V:RBUFFER_UNTIL_EMPTY:1044 #define RBUFFER_UNTIL_EMPTY(buf, rptr, rcnt) \ for (size_t rcnt = 0, _r = 1; _r; _r = 0) /* NOLINT(readability/braces) */ \ for (char *rptr = rbuffer_read_ptr(buf, &rcnt); /* NOLINT(readability/braces) */ \ -- cgit From 4f8941c1a5f1ef6caa410feeb52e343db22763ce Mon Sep 17 00:00:00 2001 From: dundargoc Date: Fri, 10 Nov 2023 12:23:42 +0100 Subject: refactor: replace manual header guards with #pragma once It is less error-prone than manually defining header guards. Pretty much all compilers support it even if it's not part of the C standard. --- src/nvim/rbuffer.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src/nvim/rbuffer.h') diff --git a/src/nvim/rbuffer.h b/src/nvim/rbuffer.h index dddf34b095..0a73fdf7d3 100644 --- a/src/nvim/rbuffer.h +++ b/src/nvim/rbuffer.h @@ -11,8 +11,7 @@ // stopped(automatic backpressure handling) // // Reference: http://en.wikipedia.org/wiki/Circular_buffer -#ifndef NVIM_RBUFFER_H -#define NVIM_RBUFFER_H +#pragma once #include #include @@ -86,5 +85,3 @@ struct rbuffer { #ifdef INCLUDE_GENERATED_DECLARATIONS # include "rbuffer.h.generated.h" #endif - -#endif // NVIM_RBUFFER_H -- cgit From 6361806aa28edca55ad3316a58bc3e936df9c0eb Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Sun, 26 Nov 2023 22:58:52 +0800 Subject: refactor: move garray_T to garray_defs.h (#26227) --- src/nvim/rbuffer.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/nvim/rbuffer.h') diff --git a/src/nvim/rbuffer.h b/src/nvim/rbuffer.h index 0a73fdf7d3..55e9849d3d 100644 --- a/src/nvim/rbuffer.h +++ b/src/nvim/rbuffer.h @@ -16,8 +16,6 @@ #include #include -struct rbuffer; - // Macros that simplify working with the read/write pointers directly by hiding // ring buffer wrap logic. Some examples: // -- cgit