Re: RFC: multi-sourced file, multiple choice 'instanciations'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Arnaud, All,

On Wednesday 15 December 2010 06:32:46 Arnaud Lacombe wrote:
> On Tue, Dec 14, 2010 at 6:34 PM, Yann E. MORIN
> <yann.morin.1998@xxxxxxxxxxxxxxx> wrote:
> > But now, if the multi-included file has a choice in it, as in [2], then
> > mconf whines again
> >  common.in:9:warning: choice value used outside its choice group
> >  common.in:13:warning: choice value used outside its choice group
[--SNIP--]
> Looking at the conditional and the commit log which introduced the
> behavior should have given you the answer. You need to assign each 
> choice group the same name. The warning will go away and both will
> display correctly.

Yet, the commit log is not expressively stating what it is doing.
git blame gives changeset 5a1aa8a1 for the incriminated code, for
which the log is:

    kconfig: add named choice group

    As choice dependency are now fully checked, it's quite easy to add support
    for named choices. This lifts the restriction that a choice value can only
    appear once, although it still has to be within the same group,
    but multiple choices can be joined by giving them a name.
    While at it I cleaned up a little the choice type logic to simplify it a
    bit.

To me, this is a bit obscur. How do we 'name' a choice? OK, let's look at what
the diff changes:
 - Ah, it adds a 'word_opt' to 'choice' in the yacc stuff.
 - 'word_opt' is either empty, or a T_WORD.
 - T_WORD... I've already seen this somewhere. Maybe in the 'config' keyword?
 - Yes: config_entry_start: T_CONFIG T_WORD T_EOL
 - OK, so what happens if I change my 'choice' to 'choice FOO'?
 - Yes, it works! :-)

Thank you for pointing this feature! (And for having me digg my yacc fuu
back to semingly functional!)

> This is not documented.

Is that a plea for a patch? Hop, on the TODO list! ;-)

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
--
To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux&nblp;USB Development]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite Secrets]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux