public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] nested defines coding style
Date: Fri, 19 Aug 2011 18:31:40 -0400	[thread overview]
Message-ID: <201108191831.40960.vapier@gentoo.org> (raw)
In-Reply-To: <4E4EDC5E.6000309@myspectrum.nl>

On Friday, August 19, 2011 17:57:50 Jeroen Hofstee wrote:
> I couldn't (easily) find a doc for coding style regarding defines in
> u-boot. I commenly don't indent preprocessor macro's, but when reading
> code from some one else code I tend to prefer single space indentation
> for these (before the #). Is there a standard for this in u-boot?

i prefer:
#if 1
# if 2
#  if 3
...
#  else
...
#  endif
# endif
#endif

but doing this without the space after the "#" is acceptable.  these two 
styles are your only options, but i dont believe there is a rule as to which 
you pick other than "if you're the maintainer of the code in question, use 
whichever you like".

also, please dont hijack threads.  start a new e-mail from scratch ... dont 
just hit "reply" to any old e-mail and erase the subject/body.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20110819/c5c4a8f7/attachment.pgp 

      reply	other threads:[~2011-08-19 22:31 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-16 17:03 [U-Boot] [PATCH] NAND: Really ignore bad blocks when scrubbing Marek Vasut
2011-08-19 20:08 ` Scott Wood
2011-08-19 21:47   ` Marek Vasut
2011-08-19 21:55     ` Scott Wood
2011-08-19 22:46       ` Marek Vasut
2011-08-19 21:57     ` [U-Boot] nested defines coding style Jeroen Hofstee
2011-08-19 22:31       ` Mike Frysinger [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201108191831.40960.vapier@gentoo.org \
    --to=vapier@gentoo.org \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox