cvs commit: src/usr.sbin/pkg_install/add main.c pkg_add.1 src/usr.sbin/pkg_install/create main.c pkg_create.1 src/usr.sbin/pkg_install/delete main.c pkg_delete.1 src/usr.sbin/pkg_install/info main.c pkg_info.1 ...

Alexey Dokuchaev danfe at FreeBSD.org
Thu Jun 5 03:17:29 UTC 2008


On Wed, Jun 04, 2008 at 10:12:51PM +0200, Remko Lodder wrote:
> Maxim Sobolev wrote:
> >
> >     For consistency, getopt(3) should be used to parse options.  Options
> >     should be sorted in the getopt(3) call and the switch statement, 
> >unless
> >     parts of the switch cascade.  Elements in a switch statement that 
> >cascade
> >     should have a FALLTHROUGH comment.  Numerical arguments should be 
> >checked
> >     for accuracy.  Code that cannot be reached should have a NOTREACHED 
> >com-
> >     ment.
> >
> >There is nothing about getopt_long(3) being acceptable 
> >replacement/addition to the getopt(3).
> >
> 
> getopt(3) is implemented, and it's expanded by getopt_long(3) in this 
> case. The requirement is fullfilled and made more readable (in my
> eyes) then before.

It breaks *consistency* across vast majority of BSD utilities.  Also,
being readable in your eyes does not automagically make them so in
others'.

./danfe


More information about the cvs-all mailing list