On 13/05/11 12:17, Konstantin Andreev wrote:
I see a lot of aspects in the NSS code, which would greatly benefit
(readability, maintainability, etc) from a trivial refactoring.

Here are a few trivial examples (NSS):

-- 123 occurrences of code like
| sizeof(longUnreadableName)/sizeof(*longUnreadableName)
Much more readable:
| PR_ARRAY_SIZE( longUnreadableName )

I don't think that everybody would agree: a canonical language
construct is to me much better than proliferation of constructs
defined in some local (project, programme, source book...)
scope. Ability to read the programming language is of universal
applicability, knowledge of local definitions is worthless when
the local work-scope is left. This might be why those that work
only with a given body of code prefer local, and those that move
between projects prefer a more universal constructs.

(and spaces on the insides of brackets are certainly a matter
of style and taste. Any large body of code simply *must* have
'style guidelines').


Mark R.

--
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto

Reply via email to