[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [C source] Inconsistent comments on preprocessor conditionals
From: |
Alan Mackenzie |
Subject: |
Re: [C source] Inconsistent comments on preprocessor conditionals |
Date: |
Fri, 8 Jul 2022 13:47:30 +0000 |
Hello, Akib
On Fri, Jul 08, 2022 at 18:47:33 +0600, Akib Azmain Turja wrote:
> In some parts of the C source, preprocessor conditionals are commented
> like the following:
> --8<---------------cut here---------------start------------->8---
> #ifdef FOO
> ...
> #else /* not FOO */
> ...
> #endif /* FOO */
> --8<---------------cut here---------------end--------------->8---
> I became confused at the first glance. But after seeing like the
> following in some other part:
> --8<---------------cut here---------------start------------->8---
> #ifdef FOO
> ...
> #else /* not FOO */
> ...
> #endif /* not FOO */
> --8<---------------cut here---------------end--------------->8---
> I became even more confused. Why it's inconsistent? And what should I
> do when adding new conditional blocks? Should I follow the GNU coding
> standards (the second one)?
Just as an aside, be aware (if you're not already) that you can navigate
the preprocessor commands with the key sequences C-c C-n, C-c C-p, and
C-c C-u.
> --
> Akib Azmain Turja
> This message is signed by me with my GnuPG key. It's fingerprint is:
> 7001 8CE5 819F 17A3 BBA6 66AF E74F 0EFA 922A E7F5
--
Alan Mackenzie (Nuremberg, Germany).
- Re: [C source] Inconsistent comments on preprocessor conditionals, (continued)
- Re: [C source] Inconsistent comments on preprocessor conditionals, Eli Zaretskii, 2022/07/08
- Re: [C source] Inconsistent comments on preprocessor conditionals, Phil Sainty, 2022/07/08
- Re: [C source] Inconsistent comments on preprocessor conditionals, Eli Zaretskii, 2022/07/08
- Re: [C source] Inconsistent comments on preprocessor conditionals, Akib Azmain Turja, 2022/07/08
- Re: [C source] Inconsistent comments on preprocessor conditionals, Eli Zaretskii, 2022/07/08
- Re: [C source] Inconsistent comments on preprocessor conditionals, Phil Sainty, 2022/07/08
- Re: [C source] Inconsistent comments on preprocessor conditionals, Sergey Organov, 2022/07/08
- Re: [C source] Inconsistent comments on preprocessor conditionals, Stefan Monnier, 2022/07/08
- Re: [C source] Inconsistent comments on preprocessor conditionals, Akib Azmain Turja, 2022/07/11
Re: [C source] Inconsistent comments on preprocessor conditionals, Po Lu, 2022/07/08
Re: [C source] Inconsistent comments on preprocessor conditionals,
Alan Mackenzie <=