Skip to content

Commit 5f1fb8b

Browse files
committed
chore: only ignore c++ diagnostics for ddb headers
Signed-off-by: Alexander Droste <alexander.droste@protonmail.com>
1 parent d08c89b commit 5f1fb8b

3 files changed

Lines changed: 6 additions & 11 deletions

File tree

vortex-duckdb/build.rs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -325,14 +325,7 @@ fn c2rust(crate_dir: &Path, duckdb_include_dir: &Path) {
325325
fn cpp(duckdb_include_dir: &Path) {
326326
cc::Build::new()
327327
.std("c++20")
328-
// Duckdb sources fail -Wno-unused-parameter and -Wno-type-limits
329-
.flags([
330-
"-Wall",
331-
"-Wextra",
332-
"-Wpedantic",
333-
"-Wno-unused-parameter",
334-
"-Wno-type-limits",
335-
])
328+
.flags(["-Wall", "-Wextra", "-Wpedantic"])
336329
.cpp(true)
337330
.include(duckdb_include_dir)
338331
.include("cpp/include")

vortex-duckdb/cpp/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ if (NOT CMAKE_BUILD_TYPE)
2323
endif()
2424

2525
# Enable compiler warnings (matching build.rs flags).
26-
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wpedantic -Wno-type-limits")
26+
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wpedantic")
2727

2828
# Find DuckDB include directory via the symlink created by build.rs.
2929
# The symlink points to target/duckdb-source-vX.Y.Z which contains duckdb-X.Y.Z/

vortex-duckdb/cpp/include/duckdb_vx/duckdb_diagnostics.h

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,12 @@
1717
_Pragma("GCC diagnostic push") \
1818
_Pragma("GCC diagnostic ignored \"-Wall\"") \
1919
_Pragma("GCC diagnostic ignored \"-Wextra\"") \
20-
_Pragma("GCC diagnostic ignored \"-Wpedantic\"")
20+
_Pragma("GCC diagnostic ignored \"-Wpedantic\"") \
21+
_Pragma("GCC diagnostic ignored \"-Wunused-parameter\"") \
22+
_Pragma("GCC diagnostic ignored \"-Wtype-limits\"")
2123
#define DUCKDB_INCLUDES_END _Pragma("GCC diagnostic pop")
2224
#else
2325
#define DUCKDB_INCLUDES_BEGIN
2426
#define DUCKDB_INCLUDES_END
2527
#endif
26-
// clang-format on
28+
// clang-format on

0 commit comments

Comments
 (0)