Hello,

The Scilab code checker currently proposes a coding rule according to which each line of code should be ended with a semicolon ";":
/"Check that lines are finished with a semicolon"./

Scilab language is not C or C++. AFAIK, there is no need for this "rule" in Scilab language.
So why proposing it?

A comma ",", a semicolon ";", or a EndOfLine "\n" can be used as instructions separator. I would be interested in learning why there should be 2 consecutive instructions separators at the end of a line.

By the way, in scripts.sce, the ";" has another function (than separator) that is to cancel the display of the output of the last instruction. But the user may want to display it on purpose, and so to not use any semi-colon.

Unless there is a rationale to the benefit of users supporting it, IMO this rule should be removed from the set of defined ones, even if following it is not mandatory. Simply because it is not a rule /at all/, even for code styling. On the opposite, avoiding every useless symbol is a part of code styling, in such a way that the rule could be inverted: "/Check that in a function no semicolons are appended to lines/".

Best regards
Samuel Gougeon

_______________________________________________
dev mailing list
[email protected]
http://lists.scilab.org/mailman/listinfo/dev

Reply via email to