Skip to content

Conversation

@eramongodb
Copy link
Contributor

Verified by this patch.

Addresses 583 Clang warnings (157 unique) and 198 (7 unique) MSVC warnings relating to those emitted by examples (as part of CXX-2827). If a given warning was present in examples, this PR addresses it across all code for consistency.

404 Clang warnings and 191 MSVC warnings are addressed simply by reducing redundant recompilation of the new client_helpers and spec_test_common object library components by various mongocxx test executables. None of these warnings were unique: they were just noisy repetition of the same warning. This refactor should reduce both the warning count and the overall compilation time for mongocxx test executables.

Warnings pertaining to __cdecl are deferred to CXX-3092.

Warnings related to _CRT_SECURE_NO_WARNINGS with MSVC (getenv and gmtime) are left as-is. Feedback on how to approach these warnings (disable? #if blocks? a platform-dependent BSONCXX_PRIVATE_GETENV macro?) is welcome.

@eramongodb eramongodb requested a review from kevinAlbs August 29, 2024 18:51
@eramongodb eramongodb self-assigned this Aug 29, 2024
@kevinAlbs kevinAlbs requested a review from joshbsiegel August 29, 2024 18:59
Copy link
Contributor

@joshbsiegel joshbsiegel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Collaborator

@kevinAlbs kevinAlbs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The warning fixes are much appreciated.

@eramongodb eramongodb requested a review from kevinAlbs September 3, 2024 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants