[mapguide-internals] Coding Standards
Kenneth Skovhede, GEOGRAF A/S
ks at geograf.dk
Mon Jul 14 16:08:58 EDT 2008
What are the motivations for avoiding variable declaration inside the
for loop construction?
I personally find it much cleaner to put it in there, because the
variable is not accesible outside
the loop scope, which is usually not desireable.
The "i" variable is usually very local, and it makes sense to re-declare
it for a loop following
another loop, rather than re-use it for another purpose.
(Hoping not to start a holy war on coding standards :)
The "finally" is actually not "always" executed, if there is an
exception thrown in the exception handler.
(Its not a "how-to-program" guide, so that may not matter.)
Other than that, it looks good to me.
Regards, Kenneth Skovhede, GEOGRAF A/S
Jason Birch skrev:
> Hi all,
>
> I've just finished converting a document Bruce provided which lays out
> the standards to be used when working on MapGuide core code.
>
> http://trac.osgeo.org/mapguide/wiki/MapGuideCodingStandards
>
> Comments / corrections welcome.
>
> Jason
> _______________________________________________
> mapguide-internals mailing list
> mapguide-internals at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapguide-internals
>
More information about the mapguide-internals
mailing list