Обсуждение: boolean abuse in geo_ops.c

Поиск
Список
Период
Сортировка

boolean abuse in geo_ops.c

От
Peter Eisentraut
Дата:
The function

static char *
path_encode(bool closed, int npts, Point *pt)

is actually occasionally passed -1 as its first parameter to mean
something like "neither" or "don't print any delimiters".  That doesn't
seem like good style.  Maybe this should be split off into another bool
parameter named delimited or something?  Or the argument could be made
into an integer.