dev builds
themes manual
device status forums
mailing lists
IRC bugs
dev guide

Rockbox mail archive

Subject: Re: Nested functions

Re: Nested functions

From: Michael Sevakis <>
Date: Mon, 26 Feb 2007 08:16:25 -0500

Guilty here! but I limit using it to small functions that are only needed by
another function (by definition really). I've found them to aid clarity when
used sparingly and they're better than macros for the same purpose since
they're scoped. Just plopping everything in globally can be worse imho. From
what I've seen I _think_ I'm the only one that has used nested functions.

As for multiple statements or use of the comma operator, same thing as far
as not going overboard and not on complicated expressions.

If either of those are ever stricty forbidden I'll of course change habits.


----- Original Message -----
From: "Daniel Stenberg" <>
To: "Rockbox development" <>
Sent: Sunday, February 25, 2007 5:09 PM
Subject: Re: Nested functions

> On Sun, 25 Feb 2007, Magnus Holmgren wrote:
> > Just curious about what the code police has to say about the use of
> > functions (and multiple statements on one line).
> Personally, I think we should avoid both for clarity and readability.
> --
> Daniel Stenberg -- --
Received on 2007-02-26

Page template was last modified "Tue Sep 7 00:00:02 2021" The Rockbox Crew -- Privacy Policy