[cvs] bogofilter common.h,1.13,1.14 config.c,1.28,1.29
Matthias Andree
matthias.andree at gmx.de
Mon Nov 11 19:37:57 CET 2002
relson at users.sourceforge.net writes:
> Update of /cvsroot/bogofilter/bogofilter
> In directory usw-pr-cvs1:/tmp/cvs-serv8695
>
> Modified Files:
> common.h config.c
> Log Message:
> Change variable 'algorithm' to a #define when either GRAHAM or
> ROBINSON is enabled. Keep it a variable when both are enabled.
Why go lengths if a single enum with maybe just one value or the
opposite unavailable? Does this buy us any advantage over
enum algorithm { ROBINSON=42 };
when the user requests not to compile graham code?
BTW, can we hope to abstract the whole interface to a common API?
I find we should not use a #define when we can avoid it (e. g. because a
const double, const int or enum does the job). Type checking, you know.
--
Matthias Andree
More information about the bogofilter-dev
mailing list