Skip to content

Commit 2728de4

Browse files
authored
nanovdb: undef CALL_CUBS at the end of MeshToGrid.cuh (#2284)
TopologyBuilder.cuh and PointsToGrid.cuh both undef CALL_CUBS after their last use so the macro doesn't leak into whatever gets included next in the same translation unit. MeshToGrid.cuh was missing this. Signed-off-by: Efty Sifakis <esifakis@nvidia.com>
1 parent 3f35101 commit 2728de4

2 files changed

Lines changed: 11 additions & 0 deletions

File tree

nanovdb/nanovdb/tools/cuda/MeshToGrid.cuh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1188,6 +1188,13 @@ MeshToGrid<BuildT, ResourceT>::getHandleAndUDF(const GridBufferT& buffer, const
11881188

11891189
//-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
11901190

1191+
// Undefine utility macro for cub functions
1192+
#ifdef CALL_CUBS
1193+
#undef CALL_CUBS
1194+
#endif
1195+
1196+
//-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
1197+
11911198
} // namespace tools::cuda
11921199

11931200
} // namespace nanovdb
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
NanoVDB:
2+
Bug Fixes:
3+
- Fixed tools::cuda::MeshToGrid leaving the CALL_CUBS macro defined past the end of
4+
the header, unlike its sibling CUDA tools.

0 commit comments

Comments
 (0)