Re: [PATCH v1] kconfig: add config and source entry details

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

 



On Wed, Apr 17, 2024 at 3:30 PM Prasad Pandit <pjp@xxxxxxxxxxxxxxxxx> wrote:
>
> Hello Masahiro,
>
> On Tuesday, 16 April, 2024 at 05:19:40 pm IST, Masahiro Yamada <masahiroy@xxxxxxxxxx> wrote:>
> >You added
> >
> >- indented by a leading tab (\t) character,
> >- Help text is further indented by two more spaces.
> >
> >These are recommended coding styles for readability,
> >not grammatical requirements.
>
>   -> https://www.kernel.org/doc/html/latest/kbuild/kconfig-language.html
>
> * I see, thank you for the clarification. Reading this language reference and seeing the config entries consistently using indentation in Kconfig files, I mistook it as language syntax.
>
> * Maybe it'll help to explicitly specify that indentation is not the Kconfig language syntax.
>
>
> >You can write Kconfig code without indentation,
> >without blank lines in-between.
> >
> >
> >config FOO
> >bool "foo"
> >depends on BAR
> >config BAR
> >bool "bar"
> >config BAZ
> >bool "baz"
> >
> >
> >It is unreadable, but it works fine.
> >
> >
> >Only the place where the indentation plays an act
> >is the end of help. It is already documented.
> >
> >  The end of the help text is determined by
> >  the indentation level, this means it ends at the first line which has
> >  a smaller indentation than the first line of the help text.
> >
>
> * Got it. In that case, to confirm: are there any input cases which are erroneous according to the Kconfig language syntax? Because even config entries ending with an 'EOF' are not flagged as an error.


Why should it be flagged as an error?


Kconfig does not require a new line at the end of file.
Same for other languages such as C, Python, etc.



>
> * Last to confirm: is 'kconfig-language.html' reference for the Kconfig langauge as implemented in kernel OR it is the general language reference that applies to all Kconfig files across all projects? Because non-kernel projects also seem to use Kconfig files.


I hoped this file explained Kconfig language as a standalone project.

Apparently, it contains a kernel-specific description.
(e.g. "Compile-testing")



>
>
> Thank you.
> ---
>   - Prasad



-- 
Best Regards
Masahiro Yamada





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

  Powered by Linux