[pacman-dev] [PATCH] Remove alpm_dep_get_string usage from libalpm

Nagy Gabor ngaba at bibl.u-szeged.hu
Mon Nov 19 09:44:08 EST 2007


> 2. There is something in my mind about alpm_dep_getstring:
> It shouldn't be used for debug preformat (or in libalpm at all); but that is
> good for front-ends.
> I would prefer the following more elegant(?) solution instead of switch():
> there is a global const char *deptypestr[] = {">=", "<=", "="} in the
> correct
> order somewhere; and from now on, you can pass deptypestr[dep->mod]
> parameter
> easily to alpm_log for example (see alpm_depcmp). This is O(1) (<- switch is
> also O(1), but that floods the code imho)
> I will create a patch for this, after I can sync my git repo ;-)
> Bye


----------------------------------------------------
SZTE Egyetemi Könyvtár - http://www.bibl.u-szeged.hu
This mail sent through IMP: http://horde.org/imp/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Remove-alpm_dep_get_string-usage-from-libalpm.patch
Type: text/x-patch
Size: 5117 bytes
Desc: not available
URL: <http://archlinux.org/pipermail/pacman-dev/attachments/20071119/d915acaa/attachment.bin>


More information about the pacman-dev mailing list