Skip to content

Commit 3db57db

Browse files
committed
backend: Mark possibly unused variable with [[maybe_unused]]
The "extra" parameters in finalise_lsc and finalise_cac are only used in asserts. This may case an unused variable warning on release builds with certian compilers. Mark them with [[maybe_unused]] to avoid these warnings. Signed-off-by: Naushir Patuck <[email protected]>
1 parent 5042631 commit 3db57db

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/libpisp/backend/backend_prepare.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,8 @@ void finalise_inputs(pisp_be_config &config)
8484
}
8585
}
8686

87-
void finalise_lsc(pisp_be_lsc_config &lsc, pisp_be_lsc_extra &lsc_extra, uint16_t width, uint16_t height)
87+
void finalise_lsc(pisp_be_lsc_config &lsc, [[maybe_unused]] pisp_be_lsc_extra &lsc_extra, uint16_t width,
88+
uint16_t height)
8889
{
8990
// Just a warning that ACLS algorithms might want the grid calculations here to match the AWB/ACLS stats.
9091
static const int P = PISP_BE_LSC_STEP_PRECISION;
@@ -98,7 +99,8 @@ void finalise_lsc(pisp_be_lsc_config &lsc, pisp_be_lsc_extra &lsc_extra, uint16_
9899
PISP_ASSERT(lsc.grid_step_y * (height + lsc_extra.offset_y - 1) < (PISP_BE_LSC_GRID_SIZE << P));
99100
}
100101

101-
void finalise_cac(pisp_be_cac_config &cac, pisp_be_cac_extra &cac_extra, uint16_t width, uint16_t height)
102+
void finalise_cac(pisp_be_cac_config &cac, [[maybe_unused]] pisp_be_cac_extra &cac_extra, uint16_t width,
103+
uint16_t height)
102104
{
103105
static const int P = PISP_BE_CAC_STEP_PRECISION;
104106

0 commit comments

Comments
 (0)