C variable declaration style
Derek Atkins
warlord at MIT.EDU
Mon Jun 9 13:58:17 EDT 2008
They must be declared at the top of a BLOCK, but you're welcome
to scope them as necessary. The limitation is that you cannot
declare a variable in the middle of a block.
-derek
Quoting Charles Day <cedayiv at gmail.com>:
> When writing GnuCash C functions, is it preferred to declare all variables
> at the very top? Or am I free to declare them in other places to get more
> control over scope, like:
>
> if (condition)
> {
> int private_to_if;
>
> do something...
> }
>
> Cheers,
> Charles
> _______________________________________________
> gnucash-devel mailing list
> gnucash-devel at gnucash.org
> https://lists.gnucash.org/mailman/listinfo/gnucash-devel
>
--
Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
Member, MIT Student Information Processing Board (SIPB)
URL: http://web.mit.edu/warlord/ PP-ASEL-IA N1NWH
warlord at MIT.EDU PGP key available
More information about the gnucash-devel
mailing list