[Libguestfs] [libnbd PATCH 3/6] state_machine_generator: wrap state comments in lib/states.{h, c}

Eric Blake eblake at redhat.com
Wed May 10 15:14:09 UTC 2023


On Wed, May 10, 2023 at 01:48:11PM +0200, Laszlo Ersek wrote:
> Wrap those comments in "lib/states.h" and "lib/states.c" that describe the
> automaton's states.
> 
> Example changes from "lib/states.h":
> 
> >    /* CONNECT_TCP.CONNECT: Initial call to connect(2) on a TCP socket */
> >    STATE_CONNECT_TCP_CONNECT,
> >
> > -  /* CONNECT_TCP.CONNECTING: Connecting to the remote server over a TCP socket */
> > +  /* CONNECT_TCP.CONNECTING: Connecting to the remote server over a TCP socket
> > +   */

This one looks a bit unusual; I didn't find any instances of this
style in existing hand-written comments (
  git grep -B1 '^[:space:]*\*/$' | grep '/\*'
).  But I saw the code you had in the previous patch that produced it,
and don't see any way to force the wrap one word earlier in this
particular instance without adding even more complexity.  So I'm okay
with how it ended up.

Reviewed-by: Eric Blake <eblake at redhat.com>

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org


More information about the Libguestfs mailing list