Hi Werner,
On Wed, Jul 24, 2013 at 10:44:26AM -0300, Werner Almesberger wrote:
> Alexander Aring wrote:
> > So should I change it only for this or for all macros?
>
> Since the pascalism is so widespread I usually point it out when I
> see it but don't try to strip it from other people's code.
>
Alexander Aring wrote:
> So should I change it only for this or for all macros?
Since the pascalism is so widespread I usually point it out when I
see it but don't try to strip it from other people's code.
I would get rid of the other unnecessary parentheses, though. They
just make the code harde
Hi Werner,
On Wed, Jul 24, 2013 at 10:25:03AM -0300, Werner Almesberger wrote:
> Alexander Aring wrote:
> > +#define is_addr_link_local(a) (((a)->s6_addr16[0]) == htons(0xFE80) &&
> > \
> > + (((a)->s6_addr16[1]) == 0) && \
> > + (((a)->s6_addr16[2]) == 0) && \
> > +
Alexander Aring wrote:
> +#define is_addr_link_local(a) (((a)->s6_addr16[0]) == htons(0xFE80) &&
> \
> + (((a)->s6_addr16[1]) == 0) && \
> + (((a)->s6_addr16[2]) == 0) && \
> + (((a)->s6_addr16[3]) == 0))
More parenthesis paranoia: the (a) is good and
Signed-off-by: Alexander Aring
---
net/ieee802154/6lowpan.h | 7 +--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/net/ieee802154/6lowpan.h b/net/ieee802154/6lowpan.h
index 4b8f917..a4a307b 100644
--- a/net/ieee802154/6lowpan.h
+++ b/net/ieee802154/6lowpan.h
@@ -83,8 +83,11 @@