-
Notifications
You must be signed in to change notification settings - Fork 220
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1048 from CesiumGS/clang-tidy-cleanup
Fix clang-tidy warnings to make it actually useful
- Loading branch information
Showing
447 changed files
with
4,239 additions
and
1,594 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,14 +17,18 @@ jobs: | |
steps: | ||
- name: Check out repository code | ||
uses: actions/checkout@v4 | ||
- name: Install ninja | ||
uses: seanmiddleditch/gha-setup-ninja@master | ||
- name: Install nasm | ||
uses: ilammy/setup-nasm@v1 | ||
- name: Install latest ninja and cmake | ||
uses: lukka/get-cmake@latest | ||
- name: ccache | ||
uses: hendrikmuhs/[email protected] | ||
with: | ||
key: ccache-ubuntu-24.04-clang-clang-tidy | ||
- name: Install latest clang and clang-tidy | ||
run: | | ||
wget https://apt.llvm.org/llvm.sh | ||
chmod +x llvm.sh | ||
sudo ./llvm.sh 19 | ||
sudo apt-get install clang-tidy-19 | ||
- name: Cache vcpkg artifacts | ||
uses: actions/cache@v4 | ||
with: | ||
|
@@ -35,8 +39,8 @@ jobs: | |
vcpkg-ubuntu-24.04-clang | ||
- name: Set CC and CXX | ||
run: | | ||
echo "CC=clang-18" >> "$GITHUB_ENV" | ||
echo "CXX=clang++-18" >> "$GITHUB_ENV" | ||
echo "CC=/usr/bin/clang-19" >> "$GITHUB_ENV" | ||
echo "CXX=/usr/bin/clang++-19" >> "$GITHUB_ENV" | ||
- name: Make more swap space available | ||
run: | | ||
sudo swapoff -a | ||
|
@@ -47,8 +51,18 @@ jobs: | |
sudo swapon --show | ||
- name: Run clang-tidy | ||
run: | | ||
cmake -B build -S . -DCMAKE_BUILD_TYPE=Debug | ||
cmake --build build --target clang-tidy | ||
echo `$CC --version | head -n 1`, `cmake --version | head -n 1` | ||
cmake -B build -S . -DCMAKE_BUILD_TYPE=Debug -DCESIUM_CLANG_TIDY_USE_THREADS=4 | ||
cmake --build build --target clang-tidy > output.log | ||
- name: List clang-tidy warnings & errors | ||
if: ${{ !cancelled() }} | ||
run: | | ||
sed -n '/\(error\|warning\):/,/^$/p' output.log | ||
# On macOS, the above doesn't work because the escaped pipe is not supported. | ||
# Instead, use two commands: | ||
# sed -n '/error:/,/^$/p' output.log | ||
# sed -n '/warning:/,/^$/p' output.log | ||
Documentation: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 1 addition & 2 deletions
3
Cesium3DTilesContent/include/Cesium3DTilesContent/B3dmToGltfConverter.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 1 addition & 2 deletions
3
Cesium3DTilesContent/include/Cesium3DTilesContent/GltfConverterResult.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 1 addition & 2 deletions
3
Cesium3DTilesContent/include/Cesium3DTilesContent/GltfConverters.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 1 addition & 2 deletions
3
Cesium3DTilesContent/include/Cesium3DTilesContent/PntsToGltfConverter.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
Cesium3DTilesContent/include/Cesium3DTilesContent/registerAllTileContentTypes.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#include "Library.h" | ||
#include <Cesium3DTilesContent/Library.h> | ||
|
||
namespace Cesium3DTilesContent { | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.