Commit Graph

7 Commits

Author SHA1 Message Date
ClausKlein
461ae86e6f GenerateExportHeader: Suppress clang-tidy warning
Add `NOLINT` for `unconditional-preprocessor-if` in generated files.
2024-04-10 16:43:48 -04:00
Corentin Damman
1e19936320 GenerateExportHeader: Fix Clang support on Windows
When using Clang with Visual Studio, the GenerateExportHeader function
generates the DEPRECATED definition "__attribute__ ((__deprecated__))",
because Clang can compile such instruction. However, if a user wants to compile
the library with this generated header with MSVC, the declaration is not valid.

We suggest to always use the DEPRECATED definition "__declspec(deprecated)" on
Windows, which is valid for both Clang and MSVC.
2023-02-23 09:19:06 +01:00
Brad King
48639aa8fc clang-format.bash: Use generic clang-format attribute
Specify the clang-format version in the attribute value instead of its
name.

Issue: #24315
2023-01-18 11:48:49 -05:00
Brad King
523c443d13 clang-format.bash: update to clang-format-6.0
Update `.clang-format` with configuration to make the 6.0 format as
close as possible to what 3.8 produced before.  Then revise the style:

* Indent preprocessor directives (a feature new since 3.8)
* Add a newline and indentation before inheritance `:` and `,`

Rename the Git attribute identifying the format to include the
clang-format version number: `format.clang-format-6.0`.  This will aid
external infrastructure in knowing what version of the tool to run.
2018-06-01 09:52:02 -04:00
Kyle Edwards
b1ae9aaf79 GenerateExportHeader: add release notes, tests for include guard changes 2018-01-23 10:43:40 -05:00
Brad King
d5f39a56a4 clang-format.bash: Use Git attributes to mark files for formatting 2017-02-22 16:59:26 -05:00
Brad King
fc3dab0ea9 Tests: Port GenerateExportHeader test to RunCMake infrastructure
This will allow build failure cases to be added later.
2016-09-05 09:45:42 -04:00