From mboxrd@z Thu Jan 1 00:00:00 1970 From: Fernando Nasser To: Kevin Buettner Cc: gdb-patches@sources.redhat.com Subject: Re: [RFA] More completion improvements Date: Sun, 18 Feb 2001 10:49:00 -0000 Message-id: <3A9018B2.5AB7AD63@redhat.com> References: <1010218164030.ZM21263@ocotillo.lan> <3A900C1D.BB086BEF@redhat.com> <1010218183948.ZM21394@ocotillo.lan> X-SW-Source: 2001-02/msg00341.html Kevin Buettner wrote: > > On Feb 18, 12:53pm, Fernando Nasser wrote: > > I took another look, and I don't see the style that I was objecting to > used *anywhere* with add_show_from_set(). Perhaps, I was not clear > enough in my original message. What I find (mildly) objectionable is > changing code which looks like this: > > add_show_from_set (add_set_cmd (...), &showlist); > > to: > > add_show_from_set ((c = add_set_cmd (...)), &showlist); > > Note the addition of an embedded assignment expression. Instead, if > it becomes necessary to add an assignment, it should be added as a > separate statment, thusly: > > c = add_set_cmd (...); > add_show_from_set (c, &showlist); > I see what you mean now. I thought you were referring to the 1st form. Yes, the second one has side effects and should be split. Eli, can you do that before checking it in? Thanks. -- Fernando Nasser Red Hat Canada Ltd. E-Mail: fnasser@redhat.com 2323 Yonge Street, Suite #300 Toronto, Ontario M4P 2C9