yade-users team mailing list archive
-
yade-users team
-
Mailing list archive
-
Message #01521
Re: svn commit
But I think it would be good to have exact rules on style. Code
must be in order. Maybe, it is good to create some rules for new
added code?
Vaclav is right. The questions, which concern only the personal taste
and do not affect the accuracy or clarity of the code, have no place
in a standard programming. There is no difference in readability
between:
void myFunction() { // ... }
and
void myFunction()
{
// ...
}
Nevertheless, this task (indentation, position of brackets...) can be
done automatically (for example with bcpp). So it is not important.
I think that the critical point is the naming convention. This
convention, without being too prescriptive, should exist (in fact
there are several in Yade!). In practice, each programmer is
responsible for his choice. For example: _if (face[i].belongBoundary)
_ and _if (bound[i] == 1)_ are quite similar but the second needs
explanation while the first is self-documented. Finally, the most
important is the design...
Vincent
References