On Tue, Aug 22, 2017 at 12:31 PM, Jaromil <jaromil@???> wrote:
> dear developers,
> while interacting over the contribution of a new normalization filter,
> the doubt of having found a bug emerged regarding the MIN/MAX macro
> definitions in frei0r_math.h, see
> as you can see there are trailing semicolons on those macros, which
> shouldn't be there IMHO. the bug does not raise any problem in normal
> usage of macros on standalone lines (but also in case the MIN/MAX
> macros are already defined, according to enclosing #ifdefs). Yet the
> corner-case of the bug arises in this new plugin when build on
> travis-CI (ubuntu 14) since they are used inside a conditional, see:
> and that obviously breaks the C syntax rather than ignoring an
> additional semicolon at end of line.
> I am incline to consider this a bug in frei0r (thanks to @Chungzuwalla
> on github for spotting it!) and would like to proceed fixing. Are
> there strong opinion against this fix? at a quick glance on all frei0r
> codebase I believe this doesn't affects any other filter, it all
> compiles smoothly.
Semicolons do not belong in macros, as you noted they can break syntax. We
should remove them.